From: Zebediah Figura zfigura@codeweavers.com
--- tools/winegcc/winegcc.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/tools/winegcc/winegcc.c b/tools/winegcc/winegcc.c index ab26adb07e8..e9ce0621929 100644 --- a/tools/winegcc/winegcc.c +++ b/tools/winegcc/winegcc.c @@ -1498,6 +1498,9 @@ static int is_linker_arg(const char* arg) case 'f': if (strncmp("-fuse-ld=", arg, 9) == 0) return 1; break; + case 'm': + if (strcmp("-mimpure-text", arg) == 0) return 1; + break; case 'r': if (strncmp("-rtlib=", arg, 7) == 0) return 1; break;
From: Zebediah Figura zfigura@codeweavers.com
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53392 --- configure.ac | 1 + 1 file changed, 1 insertion(+)
diff --git a/configure.ac b/configure.ac index dd4abd39e32..0ad1756ed29 100644 --- a/configure.ac +++ b/configure.ac @@ -813,6 +813,7 @@ case $host_os in DLLFLAGS="$DLLFLAGS -fno-PIC" LDDLLFLAGS="-fno-PIC" WINE_TRY_CFLAGS([-fno-PIC -Wl,-z,notext],[LDDLLFLAGS="$LDDLLFLAGS -Wl,-z,notext"]) + WINE_TRY_CFLAGS([-fno-PIC -mimpure-text],[LDDLLFLAGS="$LDDLLFLAGS -mimpure-text"]) ;; *) DLLFLAGS="$DLLFLAGS -fPIC"
We could probably get rid of -fno-PIC at this point, this is solved in a better way by doing a Mingw build.
On 7/27/22 02:11, Alexandre Julliard (@julliard) wrote:
We could probably get rid of -fno-PIC at this point, this is solved in a better way by doing a Mingw build.
Returning to this... I don't really understand this assertion. MinGW gcc forces PIC, and it also solves other unrelated problems, but I don't see how it does PIC in a better way?
It's not clear to me to what extent we want to keep non-MinGW builds functional at this point, but if we do at all, why introduce a regression? Especially when a *lot* of applications are known to depend on non-PIC code.
This merge request was closed by Zebediah Figura.
Closing, on the grounds that it's better for Solaris to just support mingw-w64, and also that this change isn't going to be enough anyway.