|
就是这一段:
tar -jxf ../mpfr-2.3.2.tar.bz2
mv mpfr-2.3.2 mpfr
tar -jxf ../gmp-4.2.4.tar.bz2
mv gmp-4.2.4 gmp
The GCC documentation recommends building GCC outside of the source directory in a dedicated build directory:
mkdir -v ../gcc-build
cd ../gcc-build
Prepare GCC for compilation:
前面都弄好了编译下面命令时出错:
CC="gcc -B/usr/bin/" ../gcc-4.3.2/configure \
--prefix=/tools --with-local-prefix=/tools --disable-nls \
--disable-shared --disable-libssp --enable-languages=c
我的文件摆放路径如下:
lfs:/mnt/lfs$ ls
gcc-4.3.2 gcc-build gmp lost+found mpfr sources tools
切换到 gcc-build 目录下编译gcc报错:
lfs:/mnt/lfs/gcc-build$ CC="gcc -B/usr/bin/" ../gcc-4.3.2/configure --prefix=/tools --with-local-prefix=/tools --disable-nls --disable-shared --disable-libssp --enable-languages=c
中间是正确的………………
checking for correct version of gmp.h... yes
checking for correct version of mpfr.h... no
configure: error: Building GCC requires GMP 4.1+ and MPFR 2.3.0+.
Try the --with-gmp and/or --with-mpfr options to specify their locations.
Copies of these libraries' source code can be found at their respective
hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/.
See also http://gcc.gnu.org/install/prerequisites.html for additional info.
If you obtained GMP and/or MPFR from a vendor distribution package, make
sure that you have installed both the libraries and the header files.
They may be located in separate packages.
说明书上说需要gmp和mpfr两个包,我两个包都解压改名字放做同一级目录下,结果gmp.h能找到,mpfr.h找不到,麻烦大侠帮忙看下。
再发一下我的目录,我的母系统是fedora10
lfs:/mnt/lfs$ ls
gcc-4.3.2 gcc-build gmp lost+found mpfr sources tools |
|