Discussion:
[MacPorts] #56511: gcc49 @4.9.4_2: rev-upgrade rebuild fails on macOS 10.12.6 XCode 9.2
MacPorts
2018-05-19 22:03:02 UTC
Permalink
#56511: gcc49 @4.9.4_2: rev-upgrade rebuild fails on macOS 10.12.6 XCode 9.2
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by kencu):

I suppose the following test in the gcc <5 Portfiles should be an Xcode
test rather than an os.major test:
{{{
if {${os.platform} eq "darwin" && ${os.major} > 16} {
depends_lib
depends_run
archive_sites
pre-fetch {
ui_error "${name} is not supported on macOS High Sierra and newer"
return -code error {unsupported platform}
}
}
}}}
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:2>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-05-19 20:38:51 UTC
Permalink
#56511: gcc49 @4.9.4_2: rev-upgrade rebuild fails on macOS 10.12.6 XCode 9.2
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by kencu):

The following bug report looks relevant.

<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81037>

The patches do not appear to have been backported before gcc5.

Try gcc5, gcc6, or gcc7 instead? Otherwise if gcc49 is mandatory, you
might need to try to backport the fixes into the gcc49 codebase.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:1>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-05-19 19:04:44 UTC
Permalink
#56511: gcc49 @4.9.4_2: rev-upgrade rebuild fails on macOS 10.12.6 XCode 9.2
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------
Changes (by mopihopi):

* Attachment "gcc49-main.log" added.
--
Ticket URL: <https://trac.macports.org/ticket/56511>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-06-06 06:42:46 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:7>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-06-05 23:29:19 UTC
Permalink
#56511: gcc49 @4.9.4_2: rev-upgrade rebuild fails on macOS 10.12.6 XCode 9.2
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------
Changes (by jmroot):

* cc: larryv@
 (removed)
* cc: larryv, Schamschula (added)


Comment:

Still, this should have been rev bumped after mpfr was updated. Seems like
[1f683a75f9aa2423dfb6485f44062b2a97483264/macports-ports] missed quite a
few dependents because they are not compatible with High Sierra and clear
their deps.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:4>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-06-06 00:16:37 UTC
Permalink
#56511: gcc49 @4.9.4_2: rev-upgrade rebuild fails on macOS 10.12.6 XCode 9.2
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by jmroot):

Done in [39189ac1570a4be27f82bdf61821671be8b65ba7/macports-ports].
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:5>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-06-06 06:36:01 UTC
Permalink
#56511: gcc49 @4.9.4_2: rev-upgrade rebuild fails on macOS 10.12.6 XCode 9.2
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by jmroot):

Interestingly, this seems to affect gcc49 only, i.e. gcc48 and older built
OK (and of course gcc5 and later are also fine).
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:6>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-14 19:07:09 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by aberezin):

Is there a fix for this? I had to uninstall gcc49 for now.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:8>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-19 20:49:08 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by kencu):

I tried to see if I might build `gcc49` using a different compiler, like
`gcc6`, but in the end it failed as well on `darwin 17`. It still pulls in
some of the current macOS SDK even with these other compilers, which is
the basis of the build issue.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:10>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-19 13:12:39 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------
Post by MacPorts
Is there a fix for this? I had to uninstall gcc49 for now.
gcc49 is very old; I would recommend using a newer gcc anyway.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:9>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-08-30 11:17:37 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by jmroot):

For reference, the error in the log, which matched one of those mentioned
in the upstream report, is:
{{{
:info:build In file included from
/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_lang_gcc49/gcc49/work/gcc-4.9.4/gcc/c/c
-objc-common.c:33:
:info:build In file included from
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/new:89:
:info:build
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/exception:173:5:
error: no member named 'fancy_abort' in namespace 'std::__1'; did you mean
simply 'fancy_abort'?
:info:build _VSTD::abort();
:info:build ^~~~~~~
:info:build
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__config:392:15:
note: expanded from macro '_VSTD'
:info:build #define _VSTD std::_LIBCPP_NAMESPACE
:info:build ^
:info:build
/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_lang_gcc49/gcc49/work/gcc-4.9.4/gcc/system.h:685:13:
note: 'fancy_abort' declared here
:info:build extern void fancy_abort (const char *, int, const char *)
ATTRIBUTE_NORETURN;
:info:build ^
}}}
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:11>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-09-01 00:21:31 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by kencu):

can we agree that the fail test in gcc43-gcc49 should be:
{{{
if {${os.platform} eq "darwin" && ([vercmp $xcodeversion 9.0] > 0)} {
depends_lib
depends_run
archive_sites
pre-fetch {
ui_error "building ${name} is not supported with Xcode 9 or
greater"
return -code error {unsupported platform}
}
}
}}}

If so, I have a commit ready to do that.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:12>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-09-01 01:03:45 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by cjones051073):

LGTM. I see no reason to keep these ancient gcc versions going on the
newer macOS versions.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:13>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-10-31 14:50:49 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------
Changes (by mf2k):

* cc: rekeeley (added)


Comment:

Has duplicate #57476.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:14>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-12-07 15:44:19 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by lancon):

I am *NOT* a guru, so please be patient and kindly provide answers "for
dummies". And let me know if I should use another means of communication
than this.

I have a similar problem to this one (maybe the same, maybe not). gcc49
will not build (on OS 10.12.16). I did a "port clean gcc49" and tried
again (twice). Same failure. I then tried port install gcc5, and also port
install gcc7... both fail because "The following ports will be rebuilt:
gcc49 @4.9.4". Apparently, more recent versions need gcc49 ? The
disturbing thing is I have been able to build gcc49 in the past (more
specifically, a "port install atlas +gcc49" worked on Nov. 11, 2017 - I
must have broken something with other installs or cleans after that but
have no idea what. NB: I have installed only the command line tools of
Xcode, but that has not been a problem for anything until now (I don't
know if that is relevant now); in particular it has not stopped the atlas
install with gcc49 last year.

The log of the "port install gcc49" is a very long file. Should I really
paste it here? I imagine one can attach files, but I don't know how.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:15>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-12-07 15:45:36 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by lancon):

Typo. I'm on 10.12.6 (not 10.12.16)
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:16>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-12-07 16:58:07 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by kencu):

I backported fixes to build gcc49 and gcc48 with Xcode 9, but there were a
significantly increased number of errors particularly in the c++ test
suite that would have possibly been an issue. Some of that work is in this
ticket [ticket:56996].

As there really seems to be no reason to use any gcc before gcc5 any more,
especially on these newer OS versions, nobody had any enthusiasm for
digging in on these test suite build failures, and I don't think anyone
ever will.

Don't paste up your huge log -- we've seen it before.

I think you should try to get gcc49 out of your system. The issue seems to
be your atlas installation, that was configured with a gcc49 variant at
some point in the past. I have mine built against clang37, but by default
it builds against gcc5. gcc5 builds OK on newer systems:
{{{
$ port -v installed atlas
The following ports are currently installed:
atlas @3.10.2_2+mpclang37-gcc5 (active) platform='darwin 10'
archs='x86_64' date='2016-09-29T06:14:45-0700'

}}}

So... you would do something like
{{{
sudo port uninstall gcc49
sudo port uninstall atlas
}}}
and when it tells you things will break, just say OK. Then once that is
done, you should just be able to install the default atlas to get the gcc5
version:
{{{
$ port variants atlas
atlas has the variants:
gcc49: build using macports-gcc-4.9
* conflicts with gcc5 mpclang37 perf
[+]gcc5: build using macports-gcc-5
* conflicts with gcc49 mpclang37 perf
mpclang37: use mp-clang-3.7 and gfortran
* conflicts with gcc49 gcc5 perf
nofortran: Forgo use of fortran compiler
universal: Build for multiple architectures
}}}
{{{
sudo port -v install atlas
}}}

please let me know if that doesn't work out for you.
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:17>
MacPorts <https://www.macports.org/>
Ports system for macOS
MacPorts
2018-12-09 15:51:53 UTC
Permalink
#56511: gcc49 @4.9.4_2: build fails with Xcode 9 on macOS 10.12
-----------------------+--------------------
Reporter: mopihopi | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version:
Resolution: | Keywords:
Port: gcc49 |
-----------------------+--------------------

Comment (by lancon):

Thank you. I will look into this as soon as I can (travelling for work the
coming week).
--
Ticket URL: <https://trac.macports.org/ticket/56511#comment:18>
MacPorts <https://www.macports.org/>
Ports system for macOS
Loading...