Opened 4 years ago
Closed 3 years ago
#26954 closed defect (fixed)
Upgrade to gcc 7.4.0 and build gcc and gfortran without isl
Reported by: | vbraun | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | sage-8.9 |
Component: | build | Keywords: | upgrade, gcc, gfortran, isl |
Cc: | slelievre | Merged in: | |
Authors: | Konrad K. Dabrowski | Reviewers: | Volker Braun |
Report Upstream: | N/A | Work issues: | |
Branch: | efc63b8 (Commits, GitHub, GitLab) | Commit: | efc63b8a5e5252c41c648815541bf6fca48f15c9 |
Dependencies: | Stopgaps: |
Description (last modified by )
This ticket upgrades to gcc 7.4.0 and builds gcc and gfortran without isl.
Tarball: ftp://ftp.mirrorservice.org/sites/sourceware.org/pub/gcc/releases/gcc-7.4.0/gcc-7.4.0.tar.xz
The upgrade fixes the issue that gcc 7.2.0 does not build on newer systems that have glibc 2.28:
This issue looks like https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85835
[gcc-7.2.0] libtool: compile: /mnt/disk/home/buildslave-sage/slave/binary_pkg/build/source/SageMath/jc4b6yulaujayb9sr94ia88eourzeq/local/var/tmp/sage/build/gcc-7.2.0/gcc-build/./gcc/xgcc -B/mnt/disk/home/buildslave-sage/slave/binary_pkg/build/source/SageMath/jc4b6yulaujayb9sr94ia88eourzeq/local/var/tmp/sage/build/gcc-7.2.0/gcc-build/./gcc/ -B/mnt/disk/home/buildslave-sage/slave/binary_pkg/build/source/SageMath/jc4b6yulaujayb9sr94ia88eourzeq/local/x86_64-pc-linux-gnu/bin/ -B/mnt/disk/home/buildslave-sage/slave/binary_pkg/build/source/SageMath/jc4b6yulaujayb9sr94ia88eourzeq/local/x86_64-pc-linux-gnu/lib/ -isystem /mnt/disk/home/buildslave-sage/slave/binary_pkg/build/source/SageMath/jc4b6yulaujayb9sr94ia88eourzeq/local/x86_64-pc-linux-gnu/include -isystem /mnt/disk/home/buildslave-sage/slave/binary_pkg/build/source/SageMath/jc4b6yulaujayb9sr94ia88eourzeq/local/x86_64-pc-linux-gnu/sys-include -DHAVE_CONFIG_H -I../../../src/libatomic/config/x86 -I../../../src/libatomic/config/posix -I../../../src/libatomic -I. -Wall -Werror -pthread -g -O2 -MT cas_16_1_.lo -MD -MP -MF .deps/cas_16_1_.lo.Ppo -DN=16 -DIFUNC_ALT=1 -mcx16 -c ../../../src/libatomic/cas_n.c -o cas_16_1_.o >/dev/null 2>&1 [gcc-7.2.0] ../../../../src/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc:157:10: fatal error: sys/ustat.h: No such file or directory [gcc-7.2.0] #include <sys/ustat.h> [gcc-7.2.0] ^~~~~~~~~~~~~ [gcc-7.2.0] compilation terminated. [gcc-7.2.0] make[10]: *** [Makefile:523: sanitizer_platform_limits_posix.lo] Error 1
The reason for building without isl is that sage now includes isl as an optional package, so we should build gcc without it for the sake of consistency (see discussion in #26735).
Change History (18)
comment:1 Changed 4 years ago by
- Branch set to u/Konrad127123/the_gcc_package_doesn_t_build_with_new_gcc
comment:2 Changed 4 years ago by
- Commit set to 299a61a467c05ab4da70bb11fb85684f042d774a
- Description modified (diff)
- Status changed from new to needs_review
comment:3 Changed 3 years ago by
Update: with the attached changes, gcc
now builds again on my computer (and #26735 does not come back).
(Later in the build process (but only if I build gcc
), I get the following error when trying to build givaro
:
----------------------------------------------- checking gmp.h usability... yes checking gmp.h presence... yes checking for gmp.h... yes checking for GMP library... yes checking gmpxx.h usability... no checking gmpxx.h presence... yes configure: WARNING: gmpxx.h: present but cannot be compiled configure: WARNING: gmpxx.h: check for missing prerequisite headers? configure: WARNING: gmpxx.h: see the Autoconf documentation configure: WARNING: gmpxx.h: section "Present But Cannot Be Compiled" configure: WARNING: gmpxx.h: proceeding with the compiler's result configure: WARNING: ## --------------------------------------------------- ## configure: WARNING: ## Report this to http://github.com/linbox-team/givaro ## configure: WARNING: ## --------------------------------------------------- ## checking for gmpxx.h... no your GMP does not have c++ support. Compile GMP with --enable-cxx ********************************************************************************
My suspicion is that this failure is unrelated, and should be a separate issue.)
comment:4 Changed 3 years ago by
Update: I tried bulding sage again with the attached patch. It worked, and all tests passed with make testlong
. The givaro
issue above was most likely a case of running out of diskspace.
comment:5 follow-up: ↓ 6 Changed 3 years ago by
- Milestone changed from sage-8.6 to sage-8.7
Retarging tickets optimistically to the next milestone. If you are responsible for this ticket (either its reporter or owner) and don't believe you are likely to complete this ticket before the next release (8.7) please retarget this ticket's milestone to sage-pending or sage-wishlist.
comment:6 in reply to: ↑ 5 Changed 3 years ago by
Retarging tickets optimistically to the next milestone. If you are responsible for this ticket (either its reporter or owner) and don't believe you are likely to complete this ticket before the next release (8.7) please retarget this ticket's milestone to sage-pending or sage-wishlist.
This patch is ready to go. It just needs someone to review it :).
comment:7 follow-up: ↓ 8 Changed 3 years ago by
It looks like #27016 will likely conflict with this. Perhaps I could combine the two (especially if my ticket is reviewed)?
comment:8 in reply to: ↑ 7 Changed 3 years ago by
- Status changed from needs_review to needs_work
Replying to embray:
It looks like #27016 will likely conflict with this. Perhaps I could combine the two (especially if my ticket is reviewed)?
I don't have enough knowledge of the build system to feel comfortable reviewing #27016. I have no objection to you combining the two: cherry-pick 6f07d2f and 62d8e3b, then add --without-isl to the configure options for both gcc and gfortran (I just noticed gfortran is built from the same source as gcc, so it should also get the --without-isl option for the same reason; my patch currently omits this.)
comment:9 Changed 3 years ago by
- Commit changed from 299a61a467c05ab4da70bb11fb85684f042d774a to 2436a0e87776da0e881b1a5edebad26dfa9aef26
Branch pushed to git repo; I updated commit sha1. New commits:
2436a0e | Disable isl when building gfortran to avoid inconsistently building gfortran with sage's optional isl package.
|
comment:10 Changed 3 years ago by
- Status changed from needs_work to needs_review
I've now also added --without-isl to the configure script for gfortran. I've not tested the gfortran part. I've not merged with #27016.
comment:11 Changed 3 years ago by
- Cc slelievre added
- Description modified (diff)
- Keywords upgrade gcc gfortran isl added
- Summary changed from The gcc package doesn't build with new gcc to Upgrade to gcc 7.4.0 and build gcc and gfortran without isl
Changing the ticket summary from "The gcc package doesn't build with new gcc" to "Upgrade to gcc 7.4.0 and build gcc and gfortran without isl".
comment:12 Changed 3 years ago by
- Commit changed from 2436a0e87776da0e881b1a5edebad26dfa9aef26 to efc63b8a5e5252c41c648815541bf6fca48f15c9
comment:13 Changed 3 years ago by
- Description modified (diff)
comment:14 Changed 3 years ago by
Patch now rebased on top of #27016.
comment:15 Changed 3 years ago by
- Milestone changed from sage-8.7 to sage-8.8
Ticket retargeted after milestone closed (if you don't believe this ticket is appropriate for the Sage 8.8 release please retarget manually)
comment:16 Changed 3 years ago by
- Reviewers set to Volker Braun
- Status changed from needs_review to positive_review
comment:17 Changed 3 years ago by
- Milestone changed from sage-8.8 to sage-8.9
comment:18 Changed 3 years ago by
- Branch changed from u/Konrad127123/the_gcc_package_doesn_t_build_with_new_gcc to efc63b8a5e5252c41c648815541bf6fca48f15c9
- Resolution set to fixed
- Status changed from positive_review to closed
The attached commits upgrade
gcc
to 7.4, which should fix this and make that the fix for #26735 redundant.I've also disabled building
gcc
withisl
, since that is now an optional package in sage (see also discussion in #26735). Ifisl
ever becomes a standard package,gcc
should be made to depend on it, the--disable-isl
line can be removed and the hacks forgmp
and friends when buildinggcc
should also be added forisl
.I have not tested this set of changes yet.
New commits:
Update gcc to 7.4
isl patch is in gcc 7.4
Disable isl when building gcc to avoid inconsistently building gcc with sage's optional isl package. See also #26735.