[PATCH] libwine: Only link libi386 with the libraries that need it.

Francois Gouget fgouget at codeweavers.com
Sun Sep 1 21:16:28 CDT 2019


In particular it does not make sense to link executables and dlls built
with MinGW with it.

From: Naveen Narayanan <zerous at nocebo.space>
Signed-off-by: Francois Gouget <fgouget at icodeweavers.com>
---
 configure.ac          | 2 +-
 libs/wine/Makefile.in | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/configure.ac b/configure.ac
index d0af7ef4a1a..581189b2156 100644
--- a/configure.ac
+++ b/configure.ac
@@ -409,7 +409,7 @@ WINE_WARNING_WITH(gettext,[test "$MSGFMT" = false],
 dnl **** Check for some libraries ****
 
 dnl Check for -li386 for NetBSD and OpenBSD
-AC_CHECK_LIB(i386,i386_set_ldt)
+AC_CHECK_LIB(i386,i386_set_ldt,[AC_SUBST(I386_LIBS, "-li386")])
 
 AC_SUBST(OPENGL_LIBS,"")
 
diff --git a/libs/wine/Makefile.in b/libs/wine/Makefile.in
index 789d09a2185..f7dd34b058d 100644
--- a/libs/wine/Makefile.in
+++ b/libs/wine/Makefile.in
@@ -1,4 +1,5 @@
-EXTRALIBS = $(DL_LIBS) $(COREFOUNDATION_LIBS) $(CORESERVICES_LIBS)
+EXTRALIBS = $(DL_LIBS) $(COREFOUNDATION_LIBS) $(CORESERVICES_LIBS) $(I386_LIBS)
+
 
 C_SRCS = \
 	config.c \
-- 
2.20.1



More information about the wine-devel mailing list