From 15566391e22e82280937ff14e05eab1d15927c3e Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Fri, 13 Jun 2003 23:26:01 +0000 Subject: [PATCH] Proper support for CPPFLAGS and LDFLAGS (suggested by Todd Vierling). --- Make.rules.in | 3 ++- dlls/Makedll.rules.in | 2 +- dlls/Maketest.rules.in | 2 +- dlls/x11drv/Makefile.in | 2 +- libs/Makelib.rules.in | 2 +- programs/Makeprog.rules.in | 2 +- programs/avitools/Makefile.in | 2 +- server/Makefile.in | 2 +- 8 files changed, 9 insertions(+), 8 deletions(-) diff --git a/Make.rules.in b/Make.rules.in index 55d982d0ab9..8661f7e8b6a 100644 --- a/Make.rules.in +++ b/Make.rules.in @@ -24,6 +24,7 @@ SHELL = /bin/sh CC = @CC@ CPP = @CPP@ CFLAGS = @CFLAGS@ +CPPFLAGS = @CPPFLAGS@ LIBS = @LIBS@ YACC = @YACC@ LEX = @LEX@ @@ -54,7 +55,7 @@ LINT = @LINT@ LINTFLAGS = @LINTFLAGS@ INCLUDES = -I$(SRCDIR) -I. -I$(TOPSRCDIR)/include -I$(TOPOBJDIR)/include $(EXTRAINCL) EXTRACFLAGS = @EXTRACFLAGS@ -ALLCFLAGS = $(INCLUDES) $(DEFS) $(EXTRACFLAGS) $(CFLAGS) +ALLCFLAGS = $(INCLUDES) $(DEFS) $(EXTRACFLAGS) $(CPPFLAGS) $(CFLAGS) ALLLINTFLAGS = $(INCLUDES) $(DEFS) $(LINTFLAGS) MKINSTALLDIRS= $(TOPSRCDIR)/tools/mkinstalldirs -m 755 WINAPI_CHECK = $(TOPSRCDIR)/tools/winapi_check/winapi_check diff --git a/dlls/Makedll.rules.in b/dlls/Makedll.rules.in index 23ce76480aa..765b907b41b 100644 --- a/dlls/Makedll.rules.in +++ b/dlls/Makedll.rules.in @@ -15,7 +15,7 @@ MAINSPEC = $(MODULE:%.dll=%).spec SPEC_DEF = $(MAINSPEC).def WIN16_FILES = $(SPEC_SRCS16:.spec=.spec.o) $(C_SRCS16:.c=.o) $(EXTRA_OBJS16) ALL_OBJS = @WIN16_FILES@ $(OBJS) $(MODULE).dbg.o -ALL_LIBS = $(LIBWINE) $(EXTRALIBS) $(LIBPORT) $(LIBS) +ALL_LIBS = $(LIBWINE) $(EXTRALIBS) $(LIBPORT) $(LDFLAGS) $(LIBS) IMPORTLIBS = $(DELAYIMPORTS:%=$(DLLDIR)/lib%.$(IMPLIBEXT)) $(IMPORTS:%=$(DLLDIR)/lib%.$(IMPLIBEXT)) all: $(MODULE)$(DLLEXT) $(SUBDIRS) diff --git a/dlls/Maketest.rules.in b/dlls/Maketest.rules.in index 0735822b17b..ecff582bfc4 100644 --- a/dlls/Maketest.rules.in +++ b/dlls/Maketest.rules.in @@ -21,7 +21,7 @@ RUNTESTFLAGS = -q -P wine -M $(TESTDLL) -T $(TOPOBJDIR) -p $(TESTPROGRAM) C_SRCS = $(CTESTS) EXTRA_SRCS = $(TESTLIST) EXTRA_OBJS = $(TESTLIST:.c=.o) -ALL_LIBS = $(LIBWINE) $(EXTRALIBS) $(LIBPORT) $(LIBS) +ALL_LIBS = $(LIBWINE) $(EXTRALIBS) $(LIBPORT) $(LDFLAGS) $(LIBS) IMPORTLIBS = $(IMPORTS:%=$(DLLDIR)/lib%.$(IMPLIBEXT)) CROSSTEST = $(TESTDLL:%.dll=%)_crosstest.exe diff --git a/dlls/x11drv/Makefile.in b/dlls/x11drv/Makefile.in index 44c68afbd97..094cf14ff27 100644 --- a/dlls/x11drv/Makefile.in +++ b/dlls/x11drv/Makefile.in @@ -50,7 +50,7 @@ EXTRASUBDIRS = \ all: $(PROGRAMS) wineclipsrv: wineclipsrv.c - $(CC) $(ALLCFLAGS) -o wineclipsrv $(SRCDIR)/wineclipsrv.c $(EXTRALIBS) $(LIBS) + $(CC) $(ALLCFLAGS) -o wineclipsrv $(SRCDIR)/wineclipsrv.c $(EXTRALIBS) $(LDFLAGS) $(LIBS) install:: $(PROGRAMS) $(MKINSTALLDIRS) $(bindir) diff --git a/libs/Makelib.rules.in b/libs/Makelib.rules.in index 08b32c8b2fa..712af0d9546 100644 --- a/libs/Makelib.rules.in +++ b/libs/Makelib.rules.in @@ -19,7 +19,7 @@ all: $(MODULE) $(MODULE:.dll=.a) @MAKE_RULES@ $(LIBNAME).so.$(SOVERSION): $(OBJS) Makefile.in - $(LDSHARED) $(OBJS) $(EXTRALIBS) $(LIBS) -o $@ + $(LDSHARED) $(OBJS) $(EXTRALIBS) $(LDFLAGS) $(LIBS) -o $@ $(LIBNAME).so: $(LIBNAME).so.$(SOVERSION) $(RM) $@ && $(LN_S) $(LIBNAME).so.$(SOVERSION) $@ diff --git a/programs/Makeprog.rules.in b/programs/Makeprog.rules.in index dc2a5aa8489..47441834a61 100644 --- a/programs/Makeprog.rules.in +++ b/programs/Makeprog.rules.in @@ -12,7 +12,7 @@ DEFS = @DLLFLAGS@ $(EXTRADEFS) LDDLLFLAGS = @LDDLLFLAGS@ ALL_OBJS = $(OBJS) $(MODULE).dbg.o -ALL_LIBS = $(LIBWINE) $(EXTRALIBS) $(LIBPORT) $(LIBS) +ALL_LIBS = $(LIBWINE) $(EXTRALIBS) $(LIBPORT) $(LDFLAGS) $(LIBS) BASEMODULE = $(MODULE:.exe=) TESTIMPORTS = $(DELAYIMPORTS) $(IMPORTS) RUNTESTFLAGS= -q -P wine -T $(TOPOBJDIR) $(PLTESTPROGRAM:%=-p %) diff --git a/programs/avitools/Makefile.in b/programs/avitools/Makefile.in index df1c1a7d2d0..82d6ce2ec71 100644 --- a/programs/avitools/Makefile.in +++ b/programs/avitools/Makefile.in @@ -6,7 +6,7 @@ SRCDIR = @srcdir@ VPATH = @srcdir@ MODULE = none PROGRAMS = aviinfo.exe aviplay.exe icinfo.exe -ALL_LIBS = $(LIBWINE) $(LIBPORT) $(LIBS) +ALL_LIBS = $(LIBWINE) $(LIBPORT) $(LDFLAGS) $(LIBS) C_SRCS = \ aviinfo.c \ diff --git a/server/Makefile.in b/server/Makefile.in index 9859f8ff44b..1d6211c04ba 100644 --- a/server/Makefile.in +++ b/server/Makefile.in @@ -50,7 +50,7 @@ all: $(PROGRAMS) @MAKE_RULES@ wineserver: $(OBJS) - $(CC) -o $(PROGRAMS) $(OBJS) $(LIBWINE) $(LIBUNICODE) $(LIBPORT) $(LIBS) $(LDFLAGS) + $(CC) -o $(PROGRAMS) $(OBJS) $(LIBWINE) $(LIBUNICODE) $(LIBPORT) $(LDFLAGS) $(LIBS) install:: $(PROGRAMS) $(MKINSTALLDIRS) $(bindir)