Commit 15566391 authored by Alexandre Julliard's avatar Alexandre Julliard

Proper support for CPPFLAGS and LDFLAGS (suggested by Todd Vierling).

parent 26f51af6
......@@ -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
......
......@@ -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)
......
......@@ -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
......
......@@ -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)
......
......@@ -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) $@
......
......@@ -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 %)
......
......@@ -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 \
......
......@@ -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)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment