0

安装 GCC4.7 时出现一些问题。请帮我解决这个错误。 http://solarianprogrammer.com/2012/04/13/building-gcc-4-7-on-ubuntu-12-04/ 我试图按照上述站点中的这些命令安装 GCC4.7。gcc 的先决条件已正确安装,当我在安装 Gcc 期间尝试调用“make”时,出现以下错误。

checking for C compiler default output file name... a.out
checking whether the C compiler works... configure: error: in `/home/priya/OS_HW1/gcc-4.7/build/x86_64-linux-gnu/libgomp':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details.
make[2]: *** [configure-stage1-target-libgomp] Error 1
make[2]: Leaving directory `/home/priya/OS_HW1/gcc-4.7/build'
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory `/home/priya/OS_HW1/gcc-4.7/build'
make: *** [all] Error 2
4

1 回答 1

0

安装似乎坏了。尝试

 sudo apt-get install libgomp1 
 sudo apt-get install gcc-4.7-base
于 2013-01-12T21:48:13.677 回答