diff options
author | Ionen Wolkens <ionen@gentoo.org> | 2024-03-24 14:30:37 -0400 |
---|---|---|
committer | Ionen Wolkens <ionen@gentoo.org> | 2024-03-24 14:37:35 -0400 |
commit | 5d08c93d5ec41658468afe23cc0cb816ad682fd1 (patch) | |
tree | d7ea0b7fb0e3cf824287609b4faf5cf890ed8635 /app-emulation | |
parent | app-emulation/wine-vanilla: filter -Wl,-z,* ... for CFLAGS (diff) | |
download | gentoo-5d08c93d5ec41658468afe23cc0cb816ad682fd1.tar.gz gentoo-5d08c93d5ec41658468afe23cc0cb816ad682fd1.tar.bz2 gentoo-5d08c93d5ec41658468afe23cc0cb816ad682fd1.zip |
app-emulation/wine-staging: filter -Wl,-z,* ... for CFLAGS
test-flags-CC was not meant to test LDFLAGS and -Wl,* are no-ops
at compile-time and thus don't get stripped even if they don't work
(same happens when using strip-unsupported-flags) and then if a
package compiles and links anything at same time it fails.
This used not to be a big problem but now that 23.0 profiles
do -Wl,-z,pack-relative-relocs (mingw ld has no -z) this is
hitting bashrc-mv users that tend to do CFLAGS="${LDFLAGS}"
by default. Tempting to ignore it because of how wrong it is,
but well.
An alternate route could be to eventually have strip-flags
and/or strip-unsupported-flags remove -Wl,* from non-LDFLAGS
given this could affect more than mingw (e.g. switching to
bfd when there is a lld-only option).
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'app-emulation')
5 files changed, 30 insertions, 0 deletions
diff --git a/app-emulation/wine-staging/wine-staging-9.0.ebuild b/app-emulation/wine-staging/wine-staging-9.0.ebuild index 690bb4e4dc33..7a0bdfdd539c 100644 --- a/app-emulation/wine-staging/wine-staging-9.0.ebuild +++ b/app-emulation/wine-staging/wine-staging-9.0.ebuild @@ -353,6 +353,12 @@ src_configure() { CROSSCFLAGS="${CROSSCFLAGS:-$( filter-flags '-fstack-protector*' #870136 filter-flags '-mfunction-return=thunk*' #878849 + + # some bashrc-mv users tend to do CFLAGS="${LDFLAGS}" and then + # strip-unsupported-flags miss these during compile-only tests + # (primarily done for 23.0 profiles' -z, not full coverage) + filter-flags '-Wl,-z,*' + CC=${mingwcc} test-flags-CC ${CFLAGS:--O2} )}" diff --git a/app-emulation/wine-staging/wine-staging-9.3.ebuild b/app-emulation/wine-staging/wine-staging-9.3.ebuild index d47f91ceb1aa..ff73fe1caa6e 100644 --- a/app-emulation/wine-staging/wine-staging-9.3.ebuild +++ b/app-emulation/wine-staging/wine-staging-9.3.ebuild @@ -353,6 +353,12 @@ src_configure() { CROSSCFLAGS="${CROSSCFLAGS:-$( filter-flags '-fstack-protector*' #870136 filter-flags '-mfunction-return=thunk*' #878849 + + # some bashrc-mv users tend to do CFLAGS="${LDFLAGS}" and then + # strip-unsupported-flags miss these during compile-only tests + # (primarily done for 23.0 profiles' -z, not full coverage) + filter-flags '-Wl,-z,*' + CC=${mingwcc} test-flags-CC ${CFLAGS:--O2} )}" diff --git a/app-emulation/wine-staging/wine-staging-9.4.1.ebuild b/app-emulation/wine-staging/wine-staging-9.4.1.ebuild index d9575ddd837a..a8e8379b00b3 100644 --- a/app-emulation/wine-staging/wine-staging-9.4.1.ebuild +++ b/app-emulation/wine-staging/wine-staging-9.4.1.ebuild @@ -354,6 +354,12 @@ src_configure() { CROSSCFLAGS="${CROSSCFLAGS:-$( filter-flags '-fstack-protector*' #870136 filter-flags '-mfunction-return=thunk*' #878849 + + # some bashrc-mv users tend to do CFLAGS="${LDFLAGS}" and then + # strip-unsupported-flags miss these during compile-only tests + # (primarily done for 23.0 profiles' -z, not full coverage) + filter-flags '-Wl,-z,*' + CC=${mingwcc} test-flags-CC ${CFLAGS:--O2} )}" diff --git a/app-emulation/wine-staging/wine-staging-9.5.ebuild b/app-emulation/wine-staging/wine-staging-9.5.ebuild index d47f91ceb1aa..ff73fe1caa6e 100644 --- a/app-emulation/wine-staging/wine-staging-9.5.ebuild +++ b/app-emulation/wine-staging/wine-staging-9.5.ebuild @@ -353,6 +353,12 @@ src_configure() { CROSSCFLAGS="${CROSSCFLAGS:-$( filter-flags '-fstack-protector*' #870136 filter-flags '-mfunction-return=thunk*' #878849 + + # some bashrc-mv users tend to do CFLAGS="${LDFLAGS}" and then + # strip-unsupported-flags miss these during compile-only tests + # (primarily done for 23.0 profiles' -z, not full coverage) + filter-flags '-Wl,-z,*' + CC=${mingwcc} test-flags-CC ${CFLAGS:--O2} )}" diff --git a/app-emulation/wine-staging/wine-staging-9999.ebuild b/app-emulation/wine-staging/wine-staging-9999.ebuild index d47f91ceb1aa..ff73fe1caa6e 100644 --- a/app-emulation/wine-staging/wine-staging-9999.ebuild +++ b/app-emulation/wine-staging/wine-staging-9999.ebuild @@ -353,6 +353,12 @@ src_configure() { CROSSCFLAGS="${CROSSCFLAGS:-$( filter-flags '-fstack-protector*' #870136 filter-flags '-mfunction-return=thunk*' #878849 + + # some bashrc-mv users tend to do CFLAGS="${LDFLAGS}" and then + # strip-unsupported-flags miss these during compile-only tests + # (primarily done for 23.0 profiles' -z, not full coverage) + filter-flags '-Wl,-z,*' + CC=${mingwcc} test-flags-CC ${CFLAGS:--O2} )}" |