Always pass CFLAGS when compiling or linking demos
[mesa.git] / progs / fp / Makefile
index 09f22d1a7b560bb7d3a119a909efcf5c862d2f91..3e5247477700e852021faf84d56190a8e14cbddc 100644 (file)
@@ -72,7 +72,7 @@ UTIL_FILES = readtex.h readtex.c
 .SUFFIXES: .c
 
 .c:
-       $(CC) $(INCLUDES) $(CFLAGS) $< $(LIBS) -o $@
+       $(CC) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $< $(LIBS) -o $@
 
 .c.o:
        $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
@@ -99,13 +99,13 @@ getproclist.h: $(TOP)/src/mesa/glapi/gl_API.xml getprocaddress.c getprocaddress.
 
 
 texrect: texrect.o readtex.o
-       $(CC) texrect.o readtex.o $(LIBS) -o $@
+       $(CC) $(CFLAGS) $(LDFLAGS) texrect.o readtex.o $(LIBS) -o $@
 
 texrect.o: texrect.c readtex.h
        $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
 
 invert: invert.o readtex.o
-       $(CC) invert.o readtex.o $(LIBS) -o $@
+       $(CC) $(CFLAGS) $(LDFLAGS) invert.o readtex.o $(LIBS) -o $@
 
 invert.o: invert.c readtex.h
        $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@