Why does source compile fail on archlinux at gcc?

asked 2016-07-21 13:01:46 +0200

Alasdair gravatar image

updated 2018-10-08 00:30:50 +0200

tmonteil gravatar image

I am attempting to compile the most recent sage source code on my Archlinux system. I have all the required packages and tools, and so I would have expected that make would simply do its bit.

But it fails on the compile of gcc. I've included below the last few lines of my gcc log file. What is going wrong here, and how do I fix it?

Makefile:1058: recipe for target 'cp/except.o' failed
make[6]: *** [cp/except.o] Error 1
make[6]: Leaving directory '/opt/sage-7.2/local/var/tmp/sage/build/gcc-4.9.3.p1/gcc-build/gcc'
Makefile:4222: recipe for target 'all-stage1-gcc' failed
make[5]: *** [all-stage1-gcc] Error 2
make[5]: Leaving directory '/opt/sage-7.2/local/var/tmp/sage/build/gcc-4.9.3.p1/gcc-build'
Makefile:18866: recipe for target 'stage1-bubble' failed
make[4]: *** [stage1-bubble] Error 2
make[4]: Leaving directory '/opt/sage-7.2/local/var/tmp/sage/build/gcc-4.9.3.p1/gcc-build'
Makefile:889: recipe for target 'all' failed
make[3]: *** [all] Error 2
make[3]: Leaving directory '/opt/sage-7.2/local/var/tmp/sage/build/gcc-4.9.3.p1/gcc-build'

real    5m46.259s
user    4m57.797s
sys     0m23.407s
Error installing package gcc-4.9.3.p1
Please email sage-devel (http://groups.google.com/group/sage-devel)
explaining the problem and including the relevant part of the log file
Describe your computer, operating system, etc.
If you want to try to fix the problem yourself, *don't* just cd to
/opt/sage-7.2/local/var/tmp/sage/build/gcc-4.9.3.p1 and type 'make' or whatever is appropriate.
Instead, the following commands setup all environment variables
correctly and load a subshell for you to debug the error:
  (cd '/opt/sage-7.2/local/var/tmp/sage/build/gcc-4.9.3.p1' && '/opt/sage-7.2/sage' --sh)
When you are done debugging, you can type "exit" to leave the subshell.
edit retag flag offensive close merge delete


You should provide more information, in particuler

  • could you provide the whole /opt/sage-7.2/logs/pkgs/gcc-4.9.3.p1.log file ?
  • did you run make as root ?
  • do you have enough space on your disk (what is the result of the df -h /opt/sage-7.2 command) ?
tmonteil gravatar imagetmonteil ( 2016-07-21 13:48:04 +0200 )edit

No - I ran make as myself, and I have 72Gb of free space. I also tried to use an earlier gcc, by downloading a version 5, and setting export CC=/usr/bin/gcc-5 before running make again. Still failed at the same spot.

I'm not going to give the entire gcc log file, as in its current form it seems to be over 5Mb in size, and consists of nearly 50000 lines.

Second try: I did a make distclean and started from scratch. Failed again, but the gcc log file is now only 11876 lines.

Alasdair gravatar imageAlasdair ( 2016-07-21 15:07:20 +0200 )edit

If you aren't going to give the log file here, you could use sage-devel and post a link to the log file there - people often do that.

kcrisman gravatar imagekcrisman ( 2016-07-21 15:59:44 +0200 )edit

I have encountered similar problem building Sage on ArchLinux, see this topic and was unable to resolve it, now I am using binary version of sage.

Eugene gravatar imageEugene ( 2016-07-22 12:00:21 +0200 )edit