commit: 5d08c93d5ec41658468afe23cc0cb816ad682fd1
Author: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 24 18:30:37 2024 +0000
Commit: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Sun Mar 24 18:37:35 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5d08c93d
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 <AT> gentoo.org>
app-emulation/wine-staging/wine-staging-9.0.ebuild | 6 ++++++
app-emulation/wine-staging/wine-staging-9.3.ebuild | 6 ++++++
app-emulation/wine-staging/wine-staging-9.4.1.ebuild | 6 ++++++
app-emulation/wine-staging/wine-staging-9.5.ebuild | 6 ++++++
app-emulation/wine-staging/wine-staging-9999.ebuild | 6 ++++++
5 files changed, 30 insertions(+)
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}
)}"