【发布时间】:2012-09-17 09:24:57
【问题描述】:
我正在尝试在 CentOS 上构建最新的(在撰写本文时)GCC 版本。 我下载并构建了 GMP、MPFR 和 MPC。这些库位于 /usr/local 下(即,用于库的 usr/local/lib 和用于包含的 /usr/local/include)。现在我正在尝试配置 GCC 以使用以下命令进行构建:
./configure --with-gmp=/usr/local --with-mpfr=/usr/local --with-mpc=/usr/local
我收到以下错误消息:
checking for the correct version of gmp.h... yes
checking for the correct version of mpfr.h... yes
checking for the correct version of mpc.h... yes
checking for the correct version of the gmp/mpfr/mpc libraries... no
configure: error: Building GCC requires GMP 4.2+, MPFR 2.3.1+ and MPC 0.8.0+.
Try the --with-gmp, --with-mpfr and/or --with-mpc options to specify their locations.
可能是什么原因?库是构建的,位置正确,头文件被识别,但库本身不是。我也试过这个:
./configure --with-gmp-lib=/usr/local/lib \
--with-mpfr-lib=/usr/local/lib --with-mpc-lib=/usr/local/lib
但结果是一样的。
【问题讨论】:
标签: c++ linux gcc centos centos6