我正在尝试安装PARI/GP,在配置步骤中我得到:
$ ./Configure
[...]
Looking for the compilers ...
...cc is /usr/bin/cc
...gcc is /usr/local/bin/gcc
GNU compiler version 4.8.0 20120705 (experimental) (GCC)
###
### C compiler does not work. PARI/GP requires an ANSI C compiler! Aborting.
###
### Compiler was: /usr/local/bin/gcc
$ gcc --version
gcc (GCC) 4.8.0 20120705 (experimental)这很奇怪,因为文档中说:
"Only ANSI C and C++ compilers are supported. Choosing the GNU compiler
gcc/g++ enables the inlining of kernel routines (about 20% speedup; if you
use g++, it is a good idea to include the -fpermissive flag). If you choose
not to use gcc, the C++ version of Pari will be a little faster because of
general inlining, but can be used in library mode only with C++ programs.
We strongly recommand using gcc all the way through."我也尝试过g++,也得到了同样的结果。
我正在尝试在linux x86_64上编译。
有什么想法吗?提前谢谢你,
M;
发布于 2013-04-05 23:34:44
PARI顶层中的config/get_cc脚本试图编译测试程序,但失败了。
寻找这条线
$CC $CFLAGS $extraflag -o $exe ansi.c 2>/dev/null && $RUNTEST $exe并删除2>/dev/null。Configure现在应该打印出来自编译器的显式错误消息。它们应该提供一个提示。
发布于 2015-03-11 21:08:31
我也有同样的问题。以下是针对Linux Mint 17.1 64位的解决方案:
sudo apt-get install gcc libc6-dev libgmp-dev此命令还安装GMP库(建议用于PARI/GP)。
感谢K.B.关于如何看待问题的提示。
https://stackoverflow.com/questions/11648087
复制相似问题