4
我試圖在Solaris sun4u sparc上從http://ftp.gnu.org/gnu/binutils構建binutils 2.21.1a SunOS 5.10。我正在使用gcc版本4.0.2。當我建這個錯誤:在Solaris上構建binutils 2.21.1a時發生錯誤
cc1: warnings being treated as errors
compress.c: In function 'bfd_compress_section_contents':
compress.c:100: warning: implicit declaration of function 'compressBound'
make[2]: *** [compress.lo] Error 1
make[2]: Leaving directory `/nfs/netapp0/user/home/hart/downloads/binutils-2.21.1/bfd'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/nfs/netapp0/user/home/hart/downloads/binutils-2.21.1/bfd'
*** Error code 2
make: Fatal error: Command failed for target `all'
我加入了--disable-werror
在configure行,試圖繞過它,並希望繼續建立。不幸的是這並沒有工作,要麼和我在鏈接時得到這個新的,相關的,錯誤:
Undefined first referenced
symbol in file
compressBound ../bfd/.libs/libbfd.a(compress.o)
ld: fatal: Symbol referencing errors. No output written to size
collect2: ld returned 1 exit status
...我已經尋找現有的問題,但我沒有發現任何有關。有任何想法嗎?我更喜歡使用這個版本的binutils,但是如果你知道在這個平臺上用gcc 4.0.2建立好的版本,請讓我知道。
什麼說'grep compressBound/usr/include/zlib.h'? – jlliagre
@jilliagre,我已經找到答案,請參閱下面的答案。但是,是的,系統上的zlib版本太舊,以至於binutils所需的版本太舊,並且自動配置腳本中存在一個錯誤,它沒有對其進行適當的檢查。 – James