配置gmp时出错
希望这只是一个非常简单的问题。好的,这就是我所做的:我想在我的 Linux Ubuntu 11.10 下安装 gmp。我的系统上同时有 g++ 和 gcc。因此,我从 gmp 官方网站(gmp 5.0.2)下载了最新版本,将其解压,然后,由于我需要 c++ gmp 接口,我只需运行:
./configure --enable-cxx
但它会持续工作一段时间,然后打印出:
checking for suitable m4... configure: error: No usable m4 in $PATH or /usr/5bin (see config.log for reasons).
Did I do有事吗?非常感谢!
马泰奥
hope this is just a very simple question. Ok, here's what I've done: I wanted to install gmp under my Linux Ubuntu 11.10. I have both g++ and gcc on my system. So I downloaded the latest release from the gmp official site (gmp 5.0.2), extracted it and then, since I need the c++ gmp interface, I simply run:
./configure --enable-cxx
But it keeps working for a while and then prints out:
checking for suitable m4... configure: error: No usable m4 in $PATH or /usr/5bin (see config.log for reasons).
Did I do something wrong? Thank you very much!
Matteo
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
尝试 sudo apt-get install m4 并重新运行 ./configure
try
sudo apt-get install m4
and rerun the./configure
我知道这是 7 年前的事情,但我现在正在考虑在旧系统上从源代码安装 gmp5.1.3。我注意到“有趣的输出”
检查合适的 m4...配置:错误:$PATH 或 /usr/5bin 中没有可用的 m4
5bin 嗯?我以为这是一个拼写错误,而且很可能是这样。在配置脚本的第 27285 行,有ac_dummy="$PATH:/usr/5bin"
这是一个 shell 变量,脚本会查找该变量,但没有找到。在 *nix 默认 FHS 中,
/usr/5bin
不存在。ac_dummy="$PATH:/usr/5bin"
的问题是接下来的几行是一个 for 循环,在 $PATH 变量 + /usr/5bin 中搜索 m4。在我的系统上,/usr/sbin 是 m4 文件所在的位置,并且不是默认 $PATH 变量的一部分。
修复:
您可以修改 $PATH 变量以包含 /usr/sbin。
你可以修改配置脚本为 ac_dummy="$PATH:/usr/sbin"
你可以等待 7 年才有人提交错误报告。
根据操作系统的年龄和支持,
sudo apt-get install m4
也可以工作。I know this was from 7 years ago, but Im looking at installing gmp5.1.3 from source on an older system right now. I noted the "funny output"
checking for suitable m4... configure: error: No usable m4 in $PATH or /usr/5bin
5bin hunh? I though it was a typo, and it probably is. On line 27285 of configure script, there isac_dummy="$PATH:/usr/5bin"
that is a shell variable that the script then looks for and doesn't find. in the *nix default FHS,
/usr/5bin
doesn't exist.the problem with
ac_dummy="$PATH:/usr/5bin"
is that the next few lines are a for loop searching the $PATH variable + /usr/5bin for m4.on my system, /usr/sbin is where the m4 files are located, and is not part of the default $PATH variable.
Fixes:
you could modify your $PATH variable to include /usr/sbin.
you could modify the configure script to say ac_dummy="$PATH:/usr/sbin"
you could wait 7 years for someone to file a bug report.
depending on age and support of your OS,
sudo apt-get install m4
could also work.我也有同样的错误,
sudo apt-get install m4
解决了这个问题。I have the same error,
sudo apt-get install m4
solve this problem.