changeset 5050:55641677e55b draft

(svn r7100) Evaluate the necessary flags for SDL once per make run, not every time the CFLAGS/LIBS variables are used
author tron <tron@openttd.org>
date Tue, 07 Nov 2006 15:53:20 +0000
parents edc6777e516a
children e5d5f9f7ecea
files Makefile
diffstat 1 files changed, 5 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/Makefile
+++ b/Makefile
@@ -441,12 +441,14 @@
 # SDL config
 ifdef WITH_SDL
 CDEFS += -DWITH_SDL
-CFLAGS += $(shell $(SDL_CONFIG) --cflags)
+CCFLAGS_SDL := $(shell $(SDL_CONFIG) --cflags)
+CFLAGS += $(CCFLAGS_SDL)
 ifdef STATIC
-LIBS += $(shell $(SDL_CONFIG) --static-libs)
+LDFLAGS_SDL := $(shell $(SDL_CONFIG) --static-libs)
 else
-LIBS += $(shell $(SDL_CONFIG) --libs)
+LDFLAGS_SDL := $(shell $(SDL_CONFIG) --libs)
 endif
+LIBS += $(LDFLAGS_SDL)
 endif
 
 # zlib config