fedora 16 編譯 gcc 4.4.6

因爲編譯內核的原因(2.6.33),需要一個低版本的gcc(f16自帶是4.6.3-2),考慮到曾經在centos6上,使用gcc 4.4.6編譯kernel成功過,所以決定用4.4.6


下載gcc源碼不必說


Problem1:

configure的時候報configure: error: Building GCC requires GMP 4.1+ and MPFR 2.3.2+.

Solve1: yum install gmp_devel

yum install mpfr_devel


configure--prefix=/usr/local/gcc-4.4.6 --enable-threads=posix --disable-checking--enable--long-long --with-system-zlib--enable-languages=c,c++,java


make

Problem2:

/usr/include/gnu/stubs.h:7:27: error: gnu/stubs-32.h: No such file or directory

Solve2: yum install glibc-devel.i686


之後make install,按照【參考3】的方法即可搞定


參考

1. http://hi.baidu.com/shen____yan/item/5f6118addab1f7a128ce9d29

2. http://stackoverflow.com/questions/7412548/gnu-stubs-32-h-no-such-file-or-directory

3. http://hi.baidu.com/shi_yang_zi/item/76198110dc0a638b89a95630

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章