[MacPorts] #69067: libgcc* ports apparently do not need +stdlib_flag variants, it does nothing
MacPorts
noreply at macports.org
Sun Jan 7 12:50:37 UTC 2024
#69067: libgcc* ports apparently do not need +stdlib_flag variants, it does nothing
-------------------------+-------------------------------------------------
Reporter: | Owner: (none)
barracuda156 |
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.8.1
Keywords: | Port: libgcc10, libgcc11, libgcc12,
| libgcc13
-------------------------+-------------------------------------------------
While gcc* use `+stdlib_flag` to be able to use `libc++` headers, for
libgcc* it is apparently redundant and does nothing.
If that is indeed the case, the following chunk is wrong:
{{{
if { ${subport} ne ${libcxxname} } {
variant stdlib_flag description {Enable stdlib command line flag to
select c++ runtime} {
# Enables support for specifying the c++ runtime via `-stdlib=` in
a similar
# way to clang. For more details see the later comments in
# https://www.mail-archive.com/gcc-
patches at gcc.gnu.org/msg257385.html
# Note : This 'bakes' the libc++ include directory into gcc,
# which is then used as the default search location when
`-stdlib=libc++`
# is given. Therefore to have consistency across various OS
versions, and to enable
# modern c++ standards, use a recent macports clang port to
provide this.
if {${subport} eq ${name}} {
depends_run-append port:${libcxxname}
}
configure.args-append --with-gxx-libcxx-include-
dir="${libcxx_incpath}"
}
# libcxx may not be fully functional on PowerPC yet.
if {${build_arch} ni [list ppc ppc64]} {
default_variants-append +stdlib_flag
}
}
}}}
And the condition for it should rather be `if { ${subport} eq ${name} }`,
not `if { ${subport} ne ${libcxxname} }`.
--
Ticket URL: <https://trac.macports.org/ticket/69067>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list