summaryrefslogtreecommitdiff
path: root/x11-libs/wxGTK/files/wxGTK-3.2.2.1-dont-break-flags.patch
blob: db351b29d6487ab68ee0251a87ebb5ec6541a6b3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
From f092f50b794b487e552e930b11d165a736fc8edb Mon Sep 17 00:00:00 2001
From: Arsen Arsenović <arsen@gentoo.org>
Date: Sun, 2 Apr 2023 13:25:11 +0200
Subject: [PATCH] configure: Remove flag deduplication logic

Parsing compiler flags is a complex task that this function screws up.

Bug: https://bugs.gentoo.org/903668
---
 configure    | 5 ++---
 configure.in | 5 ++---
 2 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/configure b/configure
index a476a3c..a9b815b 100755
--- a/configure
+++ b/configure
@@ -45550,9 +45550,8 @@ esac
 
 dedup_flags()
 {
-    printf "%s " "$@" |
-        awk 'BEGIN { RS=" "; ORS=" " }
-            { if ($0=="-arch" || $0=="-framework" || !seen[$0]++) print }'
+	# Gentoo: Don't hack out flags, parsing them is complex.
+	printf '%s ' "$@"
 }
 
 WX_CPPFLAGS=`dedup_flags "$CPPFLAGS"`
diff --git a/configure.in b/configure.in
index a4c4178..9cf9c30 100644
--- a/configure.in
+++ b/configure.in
@@ -8570,9 +8570,8 @@ dnl flags which are explicitly allowed to occur multiple times, as all their
 dnl occurrences must be preserved).
 dedup_flags()
 {
-    printf "%s " "$@" |
-        awk 'BEGIN { RS=" "; ORS=" " }
-            { if ($0=="-arch" || $0=="-framework" || !seen[[$0]]++) print }'
+	# Gentoo: Don't hack out flags, parsing them is complex.
+	printf '%s ' "$@"
 }
 
 WX_CPPFLAGS=`dedup_flags "$CPPFLAGS"`
-- 
2.40.0