Opened 2 years ago

Closed 2 years ago

#23898 closed defect (fixed)

Upgrade to gcc 7.2.0 (gcc 5.4.0 does not build with Xcode 9.0)

Reported by: jhpalmieri Owned by:
Priority: blocker Milestone: sage-8.1
Component: build Keywords:
Cc: fbissey Merged in:
Authors: John Palmieri Reviewers: Ralf Stephan
Report Upstream: N/A Work issues:
Branch: 714f6f0 (Commits) Commit: 714f6f07b72634aed00fd9208e4c1073b9b85e4b
Dependencies: #18236, #24011, #24012 Stopgaps:

Description (last modified by jdemeyer)

Sage's gcc does not build with Xcode 9.0 (released 19 Sept 2017?). See the log file.

This is the actual error:

g++ -c   -g  -DIN_GCC    -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wno-format -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -fno-common  -DHAVE_CONFIG_H -I. -I. -I../../src/gcc -I../../src/gcc/. -I../../src/gcc/../include -I../../src/gcc/../libcpp/include -I/Users/palmieri/Desktop/Sage_stuff/sage_builds/VANILLA/sage-8.1.beta5/local/include -I/Users/palmieri/Desktop/Sage_stuff/sage_builds/VANILLA/sage-8.1.beta5/local/include -I/Users/palmieri/Desktop/Sage_stuff/sage_builds/VANILLA/sage-8.1.beta5/local/include  -I../../src/gcc/../libdecnumber -I../../src/gcc/../libdecnumber/dpd -I../libdecnumber -I../../src/gcc/../libbacktrace   -o auto-profile.o -MT auto-profile.o -MMD -MP -MF ./.deps/auto-profile.TPo ../../src/gcc/auto-profile.c
clang: warning: treating 'c' input as 'c++' when in C++ mode, this behavior is deprecated [-Wdeprecated]
In file included from ../../src/gcc/auto-profile.c:25:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/map:446:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1398:2: error: no member named 'fancy_abort' in namespace 'std::__1'; did you mean simply 'fancy_abort'?
        _VSTD::abort();
        ^~~~~~~
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__config:392:15: note: expanded from macro '_VSTD'
#define _VSTD std::_LIBCPP_NAMESPACE
              ^
../../src/gcc/system.h:700:13: note: 'fancy_abort' declared here
extern void fancy_abort (const char *, int, const char *) ATTRIBUTE_NORETURN;
            ^

A fix: upgrade GCC to 7.2.0.

Tarball: ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-7.2.0/gcc-7.2.0.tar.xz

Attachments (1)

install.log (16.3 KB) - added by rws 2 years ago.
install.log

Download all attachments as: .zip

Change History (65)

comment:1 Changed 2 years ago by jdemeyer

  • Summary changed from gcc vs. Xcode 9.0 to gcc does not build with Xcode 9.0

comment:2 Changed 2 years ago by jdemeyer

  • Description modified (diff)

comment:3 Changed 2 years ago by fbissey

  • Cc fbissey added

comment:4 Changed 2 years ago by jhpalmieri

I just upgraded Sage's gcc to 6.4.0 and it built successfully with Xcode 9.0. Is there a reason not to upgrade to this version? Or to 7.2.0 (which I haven't tried yet)?

comment:5 Changed 2 years ago by jhpalmieri

I did make ptestlong with gcc 6.4.0 and all tests passed. I did not have to make any changes to eclib (see #23922 – that problem must be specific to clang).

comment:6 Changed 2 years ago by jhpalmieri

Same with gcc 7.2.0.

comment:7 Changed 2 years ago by jhpalmieri

  • Branch set to u/jhpalmieri/gcc7.2

comment:8 Changed 2 years ago by jhpalmieri

  • Authors set to John Palmieri
  • Commit set to f5bef64e2d1db57aef352597c1d039b27cd1e2a1
  • Description modified (diff)
  • Status changed from new to needs_review

Okay, let's upgrade GCC to version 7.2.0.


New commits:

f5bef64trac 23898: upgrade GCC to version 7.2.0

comment:9 Changed 2 years ago by jhpalmieri

I have only tested this on OS X with Xcode 8 and Xcode 9. It needs testing on many other platforms.

comment:10 Changed 2 years ago by jdemeyer

I might test this on various platforms, but not very soon.

comment:11 Changed 2 years ago by dimpase

Checking on Linux Fedora 26 now.

comment:12 follow-up: Changed 2 years ago by slelievre

  • Summary changed from gcc does not build with Xcode 9.0 to Upgrade to gcc 7.2.0 (gcc 5.4.0 does not build with Xcode 9.0)

Making the ticket summary more explicit.

comment:13 Changed 2 years ago by rws

Is this known? I have SAGE_INSTALL_GCC=yes, check out develop, check out this branch, then make start will NOT build gcc.

comment:14 in reply to: ↑ 12 ; follow-up: Changed 2 years ago by aschilling

How did you get this to work? With this branch and downloading gcc-7.2.0.tar.gz, I still get an error when installing sage:

[ntl-10.3.0] libtool: install: cp -p .libs/libntl.33.dylib /Applications/sage/local/lib/libntl.33.dylib
[ntl-10.3.0] libtool: install: (cd /Applications/sage/local/lib && { ln -s -f libntl.33.dylib libntl.dylib || { rm -f libntl.dylib && ln -s libntl.33.dylib libntl.dylib; }; })
[ntl-10.3.0] libtool: install: cp -p .libs/libntl.lai /Applications/sage/local/lib/libntl.la
[ntl-10.3.0] libtool: install: cp -p .libs/libntl.a /Applications/sage/local/lib/libntl.a
[ntl-10.3.0] libtool: install: chmod 644 /Applications/sage/local/lib/libntl.a
[ntl-10.3.0] libtool: install: ranlib /Applications/sage/local/lib/libntl.a
[ntl-10.3.0] 
[ntl-10.3.0] real	4m38.570s
[ntl-10.3.0] user	7m31.224s
[ntl-10.3.0] sys	0m15.756s
[ntl-10.3.0] Successfully installed ntl-10.3.0
[ntl-10.3.0] Deleting temporary build directory
[ntl-10.3.0] /Applications/sage/local/var/tmp/sage/build/ntl-10.3.0
[ntl-10.3.0] Finished installing ntl-10.3.0.spkg
make[1]: *** [all] Error 2

real	4m39.614s
user	8m55.690s
sys	0m42.746s
***************************************************************
Error building Sage.

The following package(s) may have failed to build (not necessarily
during this run of 'make all'):

* package: gcc-7.2.0
  log file: /Applications/sage/logs/pkgs/gcc-7.2.0.log
  build directory: /Applications/sage/local/var/tmp/sage/build/gcc-7.2.0

* package: givaro-4.0.2.p0
  log file: /Applications/sage/logs/pkgs/givaro-4.0.2.p0.log
  build directory: /Applications/sage/local/var/tmp/sage/build/givaro-4.0.2.p0

The build directory may contain configuration files and other potentially
helpful information. WARNING: if you now run 'make' again, the build
directory will, by default, be deleted. Set the environment variable
SAGE_KEEP_BUILT_SPKGS to 'yes' to prevent this.

make: *** [all] Error 1

comment:15 in reply to: ↑ 14 ; follow-up: Changed 2 years ago by fbissey

Replying to aschilling:

How did you get this to work? With this branch and downloading gcc-7.2.0.tar.gz, I still get an error when installing sage:

More info from /Applications/sage/logs/pkgs/gcc-7.2.0.log please.

comment:16 in reply to: ↑ 15 Changed 2 years ago by aschilling

Replying to fbissey:

Replying to aschilling:

How did you get this to work? With this branch and downloading gcc-7.2.0.tar.gz, I still get an error when installing sage:

More info from /Applications/sage/logs/pkgs/gcc-7.2.0.log please.

Where in the tree should I put gcc-7.2.0.tar.gz?

comment:17 follow-up: Changed 2 years ago by fbissey

in upstream/.

comment:18 in reply to: ↑ 17 ; follow-up: Changed 2 years ago by aschilling

Replying to fbissey:

in upstream/.

That is where I put it. But somehow it tries to download it from mirrors

Found local metadata for gcc-7.2.0
Attempting to download package gcc-7.2.0.tar.gz from mirrors
http://mirrors.xmission.com/sage/spkg/upstream/gcc/gcc-7.2.0.tar.gz
[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
ERROR [transfer|run:135]: [Errno 404] Not Found: '//mirrors.xmission.com/sage/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
http://mirrors-usa.go-parts.com/sage/sagemath/spkg/upstream/gcc/gcc-7.2.0.tar.gz
[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
ERROR [transfer|run:135]: [Errno 404] Not Found: '//mirrors-usa.go-parts.com/sage/sagemath/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
http://files.sagemath.org/spkg/upstream/gcc/gcc-7.2.0.tar.gz
....
ERROR [transfer|run:135]: [Errno 404] Not Found: '//sagepad.org/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
Traceback (most recent call last):
  File "/Applications/sage/build/bin/sage-download-file", line 28, in <module>
    run_safe()
  File "/Applications/sage/build/bin/../sage_bootstrap/download/cmdline.py", line 118, in run_safe
    run()
  File "/Applications/sage/build/bin/../sage_bootstrap/download/cmdline.py", line 100, in run
    app.download_tarball(args.url_or_tarball, args.destination)
  File "/Applications/sage/build/bin/../sage_bootstrap/download/app.py", line 43, in download_tarball
    tarball.download()
  File "/Applications/sage/build/bin/../sage_bootstrap/tarball.py", line 161, in download
    raise FileNotMirroredError('tarball does not exist on mirror network')
sage_bootstrap.tarball.FileNotMirroredError: tarball does not exist on mirror network
************************************************************************
Error downloading gcc-7.2.0.tar.gz
************************************************************************
Please email sage-devel (http://groups.google.com/group/sage-devel)
explaining the problem and including the log file
  /Applications/sage/logs/pkgs/gcc-7.2.0.log
Describe your computer, operating system, etc.
************************************************************************
Found local metadata for gcc-7.2.0
Attempting to download package gcc-7.2.0.tar.gz from mirrors
http://mirrors.xmission.com/sage/spkg/upstream/gcc/gcc-7.2.0.tar.gz
[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
ERROR [transfer|run:135]: [Errno 404] Not Found: '//mirrors.xmission.com/sage/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
http://mirrors-usa.go-parts.com/sage/sagemath/spkg/upstream/gcc/gcc-7.2.0.tar.gz
[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
ERROR [transfer|run:135]: [Errno 404] Not Found: '//mirrors-usa.go-parts.com/sage/sagemath/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
http://files.sagemath.org/spkg/upstream/gcc/gcc-7.2.0.tar.gz
...
ERROR [transfer|run:135]: [Errno 404] Not Found: '//sagepad.org/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
Traceback (most recent call last):
  File "/Applications/sage/build/bin/sage-download-file", line 28, in <module>
    run_safe()
  File "/Applications/sage/build/bin/../sage_bootstrap/download/cmdline.py", line 118, in run_safe
    run()
  File "/Applications/sage/build/bin/../sage_bootstrap/download/cmdline.py", line 100, in run
    app.download_tarball(args.url_or_tarball, args.destination)
  File "/Applications/sage/build/bin/../sage_bootstrap/download/app.py", line 43, in download_tarball
    tarball.download()
  File "/Applications/sage/build/bin/../sage_bootstrap/tarball.py", line 161, in download
    raise FileNotMirroredError('tarball does not exist on mirror network')
sage_bootstrap.tarball.FileNotMirroredError: tarball does not exist on mirror network
************************************************************************
Error downloading gcc-7.2.0.tar.gz
************************************************************************
Please email sage-devel (http://groups.google.com/group/sage-devel)
explaining the problem and including the log file
  /Applications/sage/logs/pkgs/gcc-7.2.0.log
Describe your computer, operating system, etc.
************************************************************************
Found local metadata for gcc-7.2.0
Attempting to download package gcc-7.2.0.tar.gz from mirrors
http://mirrors.xmission.com/sage/spkg/upstream/gcc/gcc-7.2.0.tar.gz
[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
ERROR [transfer|run:135]: [Errno 404] Not Found: '//mirrors.xmission.com/sage/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
http://mirrors-usa.go-parts.com/sage/sagemath/spkg/upstream/gcc/gcc-7.2.0.tar.gz
[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
ERROR [transfer|run:135]: [Errno 404] Not Found: '//mirrors-usa.go-parts.com/sage/sagemath/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
http://files.sagemath.org/spkg/upstream/gcc/gcc-7.2.0.tar.gz
...
[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx]
ERROR [transfer|run:135]: [Errno 404] Not Found: '//sagepad.org/spkg/upstream/gcc/gcc-7.2.0.tar.gz'
Traceback (most recent call last):
  File "/Applications/sage/build/bin/sage-download-file", line 28, in <module>
    run_safe()
  File "/Applications/sage/build/bin/../sage_bootstrap/download/cmdline.py", line 118, in run_safe
    run()
  File "/Applications/sage/build/bin/../sage_bootstrap/download/cmdline.py", line 100, in run
    app.download_tarball(args.url_or_tarball, args.destination)
  File "/Applications/sage/build/bin/../sage_bootstrap/download/app.py", line 43, in download_tarball
    tarball.download()
  File "/Applications/sage/build/bin/../sage_bootstrap/tarball.py", line 161, in download
    raise FileNotMirroredError('tarball does not exist on mirror network')
sage_bootstrap.tarball.FileNotMirroredError: tarball does not exist on mirror network
************************************************************************
Error downloading gcc-7.2.0.tar.gz
************************************************************************
Please email sage-devel (http://groups.google.com/group/sage-devel)
explaining the problem and including the log file
  /Applications/sage/logs/pkgs/gcc-7.2.0.log
Describe your computer, operating system, etc.
************************************************************************

comment:19 Changed 2 years ago by dimpase

Works well on Fedora 26, all tests pass. I did the following:

  • get the tarfile in upstream/
  • get the branch via git
  • $ make distclean
  • $ SAGE_INSTALL_GCC=yes ./configure
  • $ SAGE_INSTALL_GCC=yes make ptestlong

comment:20 Changed 2 years ago by fbissey

Not all gcc mirror seem to carry the same tarball. When I did experiments last week, one mirror was carrying a >100MB tarball (with several other stuff included like go) compared to the one on the main mirror. So get the one linked here rather than the one on a closer mirror. Someone messed up big time upstream.

comment:21 Changed 2 years ago by rws

For Europeans the fu-berlin tarball seems fine.

comment:22 in reply to: ↑ 18 ; follow-up: Changed 2 years ago by dimpase

Replying to aschilling:

Replying to fbissey:

in upstream/.

That is where I put it. But somehow it tries to download it from mirrors

This might indicate that the tarball you got didn't match - then it is silently deleted and an attempt to download one is made.

The tarball linked is huge, in fact, over 100Mb.

comment:23 Changed 2 years ago by fbissey

Checking my numbers. The tarball I got is 107MB, the one I first downloaded was actually several hundreds MB.

comment:24 in reply to: ↑ 22 Changed 2 years ago by dimpase

Replying to dimpase:

Replying to aschilling:

Replying to fbissey:

in upstream/.

That is where I put it. But somehow it tries to download it from mirrors

This might indicate that the tarball you got didn't match - then it is silently deleted and an attempt to download one is made.

I have opened #23972 to rectify the silent tarball deletion.

comment:25 Changed 2 years ago by jhpalmieri

Note that we can use a smaller tarball (maybe 60MB?) if we use a .xz file instead. No other Sage packages use .xz files, so I was reluctant to try here.

comment:26 follow-ups: Changed 2 years ago by jdemeyer

Sage comes with an xz standard package. So this would just be a matter of adding .xz support to the Sage build system. I think it would be good anyway to do that, but please create a new ticket for that.

comment:27 Changed 2 years ago by aschilling

Thanks for your comments! I downloaded gcc-7.2.0.tar.gz again and followed Dima's instructions. Now Sage compiles!

comment:28 in reply to: ↑ 26 ; follow-up: Changed 2 years ago by jhpalmieri

Replying to jdemeyer:

Sage comes with an xz standard package. So this would just be a matter of adding .xz support to the Sage build system. I think it would be good anyway to do that, but please create a new ticket for that.

Since we rely on the system's pre-existing Python for package decompression and since lzma support is only available in Python 3, this won't be as simple as what we currently do for tar files. In particular, tarfile.is_tarfile('gcc-7.2.0.tar.xz') returns True in Python 3 but False in Python 2.

comment:29 in reply to: ↑ 26 Changed 2 years ago by rws

Replying to jdemeyer:

Sage comes with an xz standard package. So this would just be a matter of adding .xz support to the Sage build system. I think it would be good anyway to do that, but please create a new ticket for that.

See #18236.

comment:30 in reply to: ↑ 28 ; follow-up: Changed 2 years ago by jdemeyer

Replying to jhpalmieri:

Since we rely on the system's pre-existing Python for package decompression and since lzma support is only available in Python 3, this won't be as simple as what we currently do for tar files. In particular, tarfile.is_tarfile('gcc-7.2.0.tar.xz') returns True in Python 3 but False in Python 2.

Right. I forgot that we use Python these days to uncompress tarballs. For a long time, this was done by a shell script. Still, it doesn't mean that it won't work with Python, we can manually call the xz program.

comment:31 follow-up: Changed 2 years ago by fbissey

It appears there is a "backport": https://pypi.python.org/pypi/backports.lzma/

comment:32 in reply to: ↑ 31 Changed 2 years ago by jdemeyer

Replying to fbissey:

It appears there is a "backport": https://pypi.python.org/pypi/backports.lzma/

That is not relevant for Sage because we use the system Python to uncompress tarballs.

comment:33 Changed 2 years ago by jdemeyer

Anyway, the discussion about .xz tarballs should be continued on #18236.

Changed 2 years ago by rws

install.log

comment:34 Changed 2 years ago by rws

On OpenSuSE 42.2 lcalc does not build, see above for log.

comment:36 follow-up: Changed 2 years ago by rws

Indeed both the OpenSuSE gcc-5.3.1 and the installed gcc-7.2.0 fail the test case given in that link, the system glibc is 2.22-4.9.1 which is older than the glibc in the above bug report.

comment:37 Changed 2 years ago by rws

The test case passes if I remove -ffast-math from the compile options. How do I remove it when compiling lcalc?

comment:38 Changed 2 years ago by rws

  • Status changed from needs_review to needs_work

In our lcalc-1.23 the line lcalc-1.23/src/Makefile:MACHINE_SPECIFIC_FLAGS = -ffast-math -fPIC is no longer in the newer version at https://github.com/dimpase/lcalc which is enhanced from the last official version at https://code.google.com/archive/p/l-calc/, see https://trac.sagemath.org/ticket/23341#comment:35

So, in order to enable building on systems with glibc < 2.23 at least the lcalc Makefile should be patched. Even better would be the upgrade to the version at https://github.com/dimpase/lcalc. I propose to hijack #23341 for this and make it a dependency of this ticket.

comment:39 Changed 2 years ago by rws

If you don't want the dependency, the patch that makes lcalc compile and install here:

--- a/src/Makefile.old	2017-10-07 16:51:18.112467539 +0200
+++ a/src/Makefile	2017-10-07 16:51:51.901214940 +0200
@@ -41,7 +41,7 @@
 
 
 #MACHINE_SPECIFIC_FLAGS = -Wno-long-double
-MACHINE_SPECIFIC_FLAGS = -ffast-math -fPIC
+MACHINE_SPECIFIC_FLAGS = -fPIC
 
 #G4 = FALSE
 #ifeq ($(G4),TRUE)

comment:40 in reply to: ↑ 36 ; follow-up: Changed 2 years ago by jdemeyer

Replying to rws:

Indeed both the OpenSuSE gcc-5.3.1 and the installed gcc-7.2.0 fail the test case given in that link, the system glibc is 2.22-4.9.1 which is older than the glibc in the above bug report.

So it seems that the lcalc issue has nothing to do with this ticket.

comment:41 in reply to: ↑ 40 Changed 2 years ago by rws

Replying to jdemeyer:

Replying to rws:

Indeed both the OpenSuSE gcc-5.3.1 and the installed gcc-7.2.0 fail the test case given in that link, the system glibc is 2.22-4.9.1 which is older than the glibc in the above bug report.

So it seems that the lcalc issue has nothing to do with this ticket.

There is the possibility the OpenSuSE gcc-5.3.1 has something our gcc-5.4.0 does not have. I'm compiling 5.4.0 right now.

comment:42 Changed 2 years ago by rws

The test file (EDITED: and lcalc) compiles with 5.4.0. That's why I didn't notice the problem earlier: because of #21811 I had the Sage-internal gcc installed. So, it all is relevant for this ticket.

Last edited 2 years ago by rws (previous) (diff)

comment:43 in reply to: ↑ 30 ; follow-up: Changed 2 years ago by jhpalmieri

Replying to jdemeyer:

Right. I forgot that we use Python these days to uncompress tarballs.

Does this mean that bzip2 should just be a regular package, not part of the base Makefile target?

comment:44 in reply to: ↑ 43 Changed 2 years ago by jdemeyer

Replying to jhpalmieri:

Does this mean that bzip2 should just be a regular package, not part of the base Makefile target?

See #24005

comment:45 Changed 2 years ago by jdemeyer

  • Dependencies set to #18236
  • Description modified (diff)

comment:46 Changed 2 years ago by jdemeyer

  • Branch changed from u/jhpalmieri/gcc7.2 to u/jdemeyer/gcc7.2

comment:47 Changed 2 years ago by jdemeyer

  • Commit changed from f5bef64e2d1db57aef352597c1d039b27cd1e2a1 to 714f6f07b72634aed00fd9208e4c1073b9b85e4b

New commits:

13d60a1Support xz compressed tarballs
714f6f0Upgrade GCC to version 7.2.0

comment:48 follow-up: Changed 2 years ago by jdemeyer

This breaks the optional package pysingular:

[pysingular-0.9.1]     gcc -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wno-unused -fPIC -DPYTHON_VERSION_OLDER_THREE_FIVE=1 -I/home/jdemeyer/sage/local/include/singular -I/home/jdemeyer/sage/local/include/python2.7 -c SingularModule.cpp -o build/temp.linux-x86_64-2.7/SingularModule.o
[pysingular-0.9.1]     SingularModule.cpp: In function 'PyObject* GetSingularCompletion(PyObject*, PyObject*)':
[pysingular-0.9.1]     SingularModule.cpp:140:47: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
[pysingular-0.9.1]          while( singular_complete_return[ pos ] != '\0' ){
[pysingular-0.9.1]                                                    ^~~~
[pysingular-0.9.1]     error: command 'gcc' failed with exit status 1
[pysingular-0.9.1]     Running setup.py install for PySingular: finished with status 'error'

comment:49 in reply to: ↑ 48 Changed 2 years ago by dimpase

Replying to jdemeyer:

This breaks the optional package pysingular:

[pysingular-0.9.1]     gcc -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wno-unused -fPIC -DPYTHON_VERSION_OLDER_THREE_FIVE=1 -I/home/jdemeyer/sage/local/include/singular -I/home/jdemeyer/sage/local/include/python2.7 -c SingularModule.cpp -o build/temp.linux-x86_64-2.7/SingularModule.o
[pysingular-0.9.1]     SingularModule.cpp: In function 'PyObject* GetSingularCompletion(PyObject*, PyObject*)':
[pysingular-0.9.1]     SingularModule.cpp:140:47: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]

That is, it's a bug there in pysingular.

comment:50 Changed 2 years ago by jdemeyer

comment:51 Changed 2 years ago by jdemeyer

All other optional packages build.

comment:52 Changed 2 years ago by jdemeyer

  • Dependencies changed from #18236 to #18236, #24011, #24012

comment:53 Changed 2 years ago by jdemeyer

...and all doctests pass.

comment:54 follow-ups: Changed 2 years ago by jdemeyer

So the only remaining issue now is that lcalc doesn't build with GCC-7.2.0 with old glibc versions...

comment:55 in reply to: ↑ 54 Changed 2 years ago by jhpalmieri

Replying to jdemeyer:

So the only remaining issue now is that lcalc doesn't build with GCC-7.2.0 with old glibc versions...

I don't really have any suggestions for how to deal with that. Patch the makefile as in comment:39?

comment:56 in reply to: ↑ 54 Changed 2 years ago by dimpase

Replying to jdemeyer:

So the only remaining issue now is that lcalc doesn't build with GCC-7.2.0 with old glibc versions...

did you try one of these lcalc patches mentioned in #23919 ?

comment:57 follow-up: Changed 2 years ago by jhpalmieri

We need someone with an old glibc who can test out different patches. Would it be worth trying (on another ticket) upgrading to GCC 6.4.0? We need to get something into Sage so it will build with the most recent version of OS X and Xcode.

comment:58 in reply to: ↑ 57 ; follow-up: Changed 2 years ago by rws

Replying to jhpalmieri:

We need someone with an old glibc who can test out different patches.

I upgraded recently and now have glibc-2.22-8.4.

comment:59 in reply to: ↑ 58 ; follow-up: Changed 2 years ago by jhpalmieri

Replying to rws:

Replying to jhpalmieri:

We need someone with an old glibc who can test out different patches.

I upgraded recently and now have glibc-2.22-8.4.

Does this now build for you?

comment:60 in reply to: ↑ 59 Changed 2 years ago by rws

Replying to jhpalmieri:

I upgraded recently and now have glibc-2.22-8.4.

Does this now build for you?

This branch merged with 8.1.beta9 builds from distclean, after two failures to build brial (pkg_resources.DistributionNotFound: The 'pip' distribution was not found). Just restarting the make succeeded. This was after upgrading OpenSuSE from 42.2 to 42.3.

I'd suggest requiring the 42.3 upgrade as it is no pain and very easy to do.

comment:61 Changed 2 years ago by jhpalmieri

I'm upgrading this to a blocker because we need to upgrade gcc to build on the most recent OS X. I am happy with Jeroen's changes (to use .xz instead of .gz).

comment:62 Changed 2 years ago by jhpalmieri

  • Priority changed from critical to blocker
  • Status changed from needs_work to needs_review

comment:63 Changed 2 years ago by rws

  • Reviewers set to Ralf Stephan
  • Status changed from needs_review to positive_review

So, the patch is trivially looking good, and it's tested on Xcode 8/9, Linux Fedora 26, and OpenSuSE Leap 42.3.

comment:64 Changed 2 years ago by vbraun

  • Branch changed from u/jdemeyer/gcc7.2 to 714f6f07b72634aed00fd9208e4c1073b9b85e4b
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.