makefile.unix: variable cosmetics

use CPPFLAGS to hold include paths, makes overriding CC a bit more
intuitive.

Change-Id: I6ecfc1957cae423dd150ebf37b878f1da6bbcef3
This commit is contained in:
James Zern 2012-01-24 17:54:49 -08:00
parent 974aaff360
commit c274dc9679

View File

@ -51,7 +51,8 @@ EXTRA_FLAGS += -Wdeclaration-after-statement
AR = ar AR = ar
ARFLAGS = r ARFLAGS = r
CC = gcc -Isrc/ -Iexamples/ -Wall CC = gcc
CPPFLAGS = -Isrc/ -Iexamples/ -Wall
CFLAGS = -O3 -DNDEBUG $(EXTRA_FLAGS) CFLAGS = -O3 -DNDEBUG $(EXTRA_FLAGS)
INSTALL = install INSTALL = install
GROFF = /usr/bin/groff GROFF = /usr/bin/groff
@ -92,7 +93,7 @@ OUTPUT = $(OUT_LIBS) $(OUT_EXAMPLES)
all: ex all: ex
%.o: %.c $(HDRS) %.o: %.c $(HDRS)
$(CC) $(CFLAGS) -c $< -o $@ $(CC) $(CFLAGS) $(CPPFLAGS) -c $< -o $@
src/libwebp.a: $(OBJS) src/libwebp.a: $(OBJS)
$(AR) $(ARFLAGS) $@ $^ $(AR) $(ARFLAGS) $@ $^
@ -126,14 +127,14 @@ dist: all
done done
clean: clean:
$(RM) ${OUTPUT} *~ \ $(RM) $(OUTPUT) *~ \
src/enc/*.o src/enc/*~ \ examples/*.o examples/*~ \
src/dec/*.o src/dec/*~ \ src/dec/*.o src/dec/*~ \
src/dsp/*.o src/dsp/*~ \ src/dsp/*.o src/dsp/*~ \
src/utils/*.o src/utils/*~ \ src/enc/*.o src/enc/*~ \
src/mux/*.o src/mux/*~ \ src/mux/*.o src/mux/*~ \
src/utils/*.o src/utils/*~ \
src/webp/*~ man/*~ doc/*~ swig/*~ \ src/webp/*~ man/*~ doc/*~ swig/*~ \
examples/*.o examples/*~
superclean: clean superclean: clean
$(RM) -r .git *.log *.cache *~ $(RM) -r .git *.log *.cache *~