commit:     fca841ad33dbb0e5c6cd29950331b30ab2364d8d
Author:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Sat Apr 29 09:02:52 2023 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Sat Apr 29 09:42:39 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fca841ad

app-emulation/dxvk: update flags filters

* -fstack-clash-protection (bug #758914): ICE was fixed, if still
  run into this then updating gcc to a newer _p* snapshot should
  sort it (alternatively, use released >=gcc-13.1.0)
* -fstack-protector* (bug #870136): mingw64-runtime-11.0.0 adds
  its own (partial) ssp support, allowing -D_FORTIFY_SOURCE=3 and
  -fstack-protector-strong without libssp. Using these to build
  Wine currently still leads to failure, but we can allow it here.

Bug: https://bugs.gentoo.org/758914
Bug: https://bugs.gentoo.org/870136
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 app-emulation/dxvk/dxvk-1.10.3.ebuild        | 8 ++++++--
 app-emulation/dxvk/dxvk-2.0.ebuild           | 8 ++++++--
 app-emulation/dxvk/dxvk-2.1.ebuild           | 8 ++++++--
 app-emulation/dxvk/dxvk-2.1_p20230207.ebuild | 8 ++++++--
 app-emulation/dxvk/dxvk-9999.ebuild          | 8 ++++++--
 5 files changed, 30 insertions(+), 10 deletions(-)

diff --git a/app-emulation/dxvk/dxvk-1.10.3.ebuild 
b/app-emulation/dxvk/dxvk-1.10.3.ebuild
index 3995d9ee33e0..e9f3f4344b63 100644
--- a/app-emulation/dxvk/dxvk-1.10.3.ebuild
+++ b/app-emulation/dxvk/dxvk-1.10.3.ebuild
@@ -73,10 +73,14 @@ src_configure() {
        if [[ ${CHOST} != *-mingw* ]]; then
                if [[ ! -v MINGW_BYPASS ]]; then
                        unset AR CC CXX RC STRIP
-                       filter-flags '-fstack-clash-protection' #758914
-                       filter-flags '-fstack-protector*' #870136
                        filter-flags '-fuse-ld=*'
                        filter-flags '-mfunction-return=thunk*' #878849
+                       if has_version '<dev-util/mingw64-toolchain-11' ||
+                               { use crossdev-mingw &&
+                                       has_version "<cross-$(usex x86 i686 
x86_64)-w64-mingw32/mingw64-runtime-11"; }
+                       then
+                               filter-flags '-fstack-protector*' #870136
+                       fi
                fi
 
                CHOST_amd64=x86_64-w64-mingw32

diff --git a/app-emulation/dxvk/dxvk-2.0.ebuild 
b/app-emulation/dxvk/dxvk-2.0.ebuild
index 48c2560d3808..f2b240b7f42a 100644
--- a/app-emulation/dxvk/dxvk-2.0.ebuild
+++ b/app-emulation/dxvk/dxvk-2.0.ebuild
@@ -89,10 +89,14 @@ src_configure() {
        if [[ ${CHOST} != *-mingw* ]]; then
                if [[ ! -v MINGW_BYPASS ]]; then
                        unset AR CC CXX RC STRIP
-                       filter-flags '-fstack-clash-protection' #758914
-                       filter-flags '-fstack-protector*' #870136
                        filter-flags '-fuse-ld=*'
                        filter-flags '-mfunction-return=thunk*' #878849
+                       if has_version '<dev-util/mingw64-toolchain-11' ||
+                               { use crossdev-mingw &&
+                                       has_version "<cross-$(usex x86 i686 
x86_64)-w64-mingw32/mingw64-runtime-11"; }
+                       then
+                               filter-flags '-fstack-protector*' #870136
+                       fi
                fi
 
                CHOST_amd64=x86_64-w64-mingw32

diff --git a/app-emulation/dxvk/dxvk-2.1.ebuild 
b/app-emulation/dxvk/dxvk-2.1.ebuild
index d58b78a8f0ef..1e497fc5a838 100644
--- a/app-emulation/dxvk/dxvk-2.1.ebuild
+++ b/app-emulation/dxvk/dxvk-2.1.ebuild
@@ -98,10 +98,14 @@ src_configure() {
        if [[ ${CHOST} != *-mingw* ]]; then
                if [[ ! -v MINGW_BYPASS ]]; then
                        unset AR CC CXX RC STRIP
-                       filter-flags '-fstack-clash-protection' #758914
-                       filter-flags '-fstack-protector*' #870136
                        filter-flags '-fuse-ld=*'
                        filter-flags '-mfunction-return=thunk*' #878849
+                       if has_version '<dev-util/mingw64-toolchain-11' ||
+                               { use crossdev-mingw &&
+                                       has_version "<cross-$(usex x86 i686 
x86_64)-w64-mingw32/mingw64-runtime-11"; }
+                       then
+                               filter-flags '-fstack-protector*' #870136
+                       fi
                fi
 
                CHOST_amd64=x86_64-w64-mingw32

diff --git a/app-emulation/dxvk/dxvk-2.1_p20230207.ebuild 
b/app-emulation/dxvk/dxvk-2.1_p20230207.ebuild
index 24b2a3ad1e50..c3830098d829 100644
--- a/app-emulation/dxvk/dxvk-2.1_p20230207.ebuild
+++ b/app-emulation/dxvk/dxvk-2.1_p20230207.ebuild
@@ -100,10 +100,14 @@ src_configure() {
        if [[ ${CHOST} != *-mingw* ]]; then
                if [[ ! -v MINGW_BYPASS ]]; then
                        unset AR CC CXX RC STRIP
-                       filter-flags '-fstack-clash-protection' #758914
-                       filter-flags '-fstack-protector*' #870136
                        filter-flags '-fuse-ld=*'
                        filter-flags '-mfunction-return=thunk*' #878849
+                       if has_version '<dev-util/mingw64-toolchain-11' ||
+                               { use crossdev-mingw &&
+                                       has_version "<cross-$(usex x86 i686 
x86_64)-w64-mingw32/mingw64-runtime-11"; }
+                       then
+                               filter-flags '-fstack-protector*' #870136
+                       fi
                fi
 
                CHOST_amd64=x86_64-w64-mingw32

diff --git a/app-emulation/dxvk/dxvk-9999.ebuild 
b/app-emulation/dxvk/dxvk-9999.ebuild
index 7b1ccff1d6f4..313a58896371 100644
--- a/app-emulation/dxvk/dxvk-9999.ebuild
+++ b/app-emulation/dxvk/dxvk-9999.ebuild
@@ -94,10 +94,14 @@ src_configure() {
        if [[ ${CHOST} != *-mingw* ]]; then
                if [[ ! -v MINGW_BYPASS ]]; then
                        unset AR CC CXX RC STRIP
-                       filter-flags '-fstack-clash-protection' #758914
-                       filter-flags '-fstack-protector*' #870136
                        filter-flags '-fuse-ld=*'
                        filter-flags '-mfunction-return=thunk*' #878849
+                       if has_version '<dev-util/mingw64-toolchain-11' ||
+                               { use crossdev-mingw &&
+                                       has_version "<cross-$(usex x86 i686 
x86_64)-w64-mingw32/mingw64-runtime-11"; }
+                       then
+                               filter-flags '-fstack-protector*' #870136
+                       fi
                fi
 
                CHOST_amd64=x86_64-w64-mingw32

Reply via email to