Alexandre Julliard : makefiles: Automatically add dll flags where necessary .

Alexandre Julliard julliard at winehq.org
Thu Jan 2 13:13:47 CST 2014


Module: wine
Branch: master
Commit: e9afeb2a5066d18867e9f37fb9611b772cd5a7f5
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=e9afeb2a5066d18867e9f37fb9611b772cd5a7f5

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Wed Jan  1 21:33:06 2014 +0100

makefiles: Automatically add dll flags where necessary.

---

 Make.rules.in         |    2 +-
 Make.vars.in          |    1 +
 configure             |   12 +++---------
 configure.ac          |   12 +++---------
 libs/port/Makefile.in |    1 -
 libs/wine/Makefile.in |    1 -
 libs/wpp/Makefile.in  |    1 -
 tools/makedep.c       |    2 ++
 8 files changed, 10 insertions(+), 22 deletions(-)

diff --git a/Make.rules.in b/Make.rules.in
index 8d2c0cf..f400109 100644
--- a/Make.rules.in
+++ b/Make.rules.in
@@ -12,7 +12,7 @@
 # First some useful definitions
 
 DEFS         = -D__WINESRC__ $(EXTRADEFS)
-ALLCFLAGS    = $(DEFS) $(DLLFLAGS) $(EXTRACFLAGS) $(CPPFLAGS) $(CFLAGS) $(MODCFLAGS)
+ALLCFLAGS    = $(DEFS) $(EXTRACFLAGS) $(CPPFLAGS) $(CFLAGS) $(MODCFLAGS)
 IDLFLAGS     = $(DEFS) $(EXTRAIDLFLAGS)
 RCFLAGS      = --nostdinc $(PORCFLAGS) $(TARGETFLAGS) $(DEFS) $(EXTRARCFLAGS)
 
diff --git a/Make.vars.in b/Make.vars.in
index bc19456..d4b346a 100644
--- a/Make.vars.in
+++ b/Make.vars.in
@@ -39,6 +39,7 @@ LN_S            = @LN_S@
 MKDIR_P         = @MKDIR_P@
 TOOLSDIR        = @TOOLSDIR@
 LDFLAGS         = @LDFLAGS@
+DLLFLAGS        = @DLLFLAGS@
 PRELINK         = @PRELINK@
 FONTFORGE       = @FONTFORGE@
 RSVG            = @RSVG@
diff --git a/configure b/configure
index c0eff26..ad6a0dc 100755
--- a/configure
+++ b/configure
@@ -16530,24 +16530,18 @@ ac_config_commands="$ac_config_commands include/stamp-h"
 $as_echo_n "creating Makefile rules..." >&6
 
 
-MAKE_IMPLIB_RULES="DLLFLAGS = $DLLFLAGS
-"
+MAKE_IMPLIB_RULES=""
 
 
 
-MAKE_DLL_RULES="
-DLLFLAGS    = $DLLFLAGS
-"
+MAKE_DLL_RULES=""
 
 
-MAKE_PROG_RULES="
-DLLFLAGS    = $DLLFLAGS
-"
+MAKE_PROG_RULES=""
 
 
 
 MAKE_TEST_RULES="
-DLLFLAGS     = $DLLFLAGS
 RUNTESTFLAGS = -q -P wine
 "
 
diff --git a/configure.ac b/configure.ac
index 801527d..89c50c8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2593,23 +2593,17 @@ AS_ECHO_N("creating Makefile rules...") >&AS_MESSAGE_FD
 
 dnl Import library rules
 
-AC_SUBST(MAKE_IMPLIB_RULES,"DLLFLAGS = $DLLFLAGS
-")
+AC_SUBST(MAKE_IMPLIB_RULES,"")
 
 dnl Dll and program rules
 
-AC_SUBST(MAKE_DLL_RULES,"
-DLLFLAGS    = $DLLFLAGS
-")
+AC_SUBST(MAKE_DLL_RULES,"")
 
-AC_SUBST(MAKE_PROG_RULES,"
-DLLFLAGS    = $DLLFLAGS
-")
+AC_SUBST(MAKE_PROG_RULES,"")
 
 dnl Test rules
 
 AC_SUBST(MAKE_TEST_RULES,"
-DLLFLAGS     = $DLLFLAGS
 RUNTESTFLAGS = -q -P wine
 ")
 
diff --git a/libs/port/Makefile.in b/libs/port/Makefile.in
index f59862c..31d6773 100644
--- a/libs/port/Makefile.in
+++ b/libs/port/Makefile.in
@@ -1,4 +1,3 @@
-DLLFLAGS  = @DLLFLAGS@
 STATICLIB = libwine_port.a
 
 C_SRCS = \
diff --git a/libs/wine/Makefile.in b/libs/wine/Makefile.in
index d087bc7..5286e85 100644
--- a/libs/wine/Makefile.in
+++ b/libs/wine/Makefile.in
@@ -1,4 +1,3 @@
-DLLFLAGS  = @DLLFLAGS@
 EXTRALIBS = $(LIBPORT) @LIBDL@ @COREFOUNDATIONLIB@ @CORESERVICESLIB@
 EXTRADEFS = -DWINE_UNICODE_API="" \
 	-DBINDIR='"$(bindir)"' \
diff --git a/libs/wpp/Makefile.in b/libs/wpp/Makefile.in
index 668c137..4855d98 100644
--- a/libs/wpp/Makefile.in
+++ b/libs/wpp/Makefile.in
@@ -1,4 +1,3 @@
-DLLFLAGS  = @DLLFLAGS@
 STATICLIB = libwpp.a
 
 C_SRCS = \
diff --git a/tools/makedep.c b/tools/makedep.c
index c84cc59..3b6b84a 100644
--- a/tools/makedep.c
+++ b/tools/makedep.c
@@ -1376,6 +1376,7 @@ static struct strarray output_sources(void)
     struct strarray includes = empty_strarray;
     struct strarray subdirs = empty_strarray;
     struct strarray phony_targets = empty_strarray;
+    struct strarray dllflags = get_expanded_make_var_array( "DLLFLAGS" );
     struct strarray imports = get_expanded_make_var_array( "IMPORTS" );
     struct strarray all_targets = get_expanded_make_var_array( "PROGRAMS" );
     struct strarray delayimports = get_expanded_make_var_array( "DELAYIMPORTS" );
@@ -1578,6 +1579,7 @@ static struct strarray output_sources(void)
             output( "%s.o: %s\n", obj, sourcedep );
             output( "\t$(CC) -c -o $@ %s", source->filename );
             output_filenames( includes );
+            if (module || staticlib || testdll) output_filenames( dllflags );
             output_filename( "$(ALLCFLAGS)" );
             output( "\n" );
             if (crosstarget && need_cross)




More information about the wine-cvs mailing list