aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2009-04-27 21:17:18 -0700
committerH. Peter Anvin <hpa@zytor.com>2009-04-27 21:17:18 -0700
commit593236b4086e21f9552bb0281f6093b7cce875e9 (patch)
tree0c83b2ee2380f638ee03472c2e88ebeae8ac0b42
parentfe9385228a7845e98485c925031ee5a46f5dfd3b (diff)
downloadlwip-593236b4086e21f9552bb0281f6093b7cce875e9.tar.gz
lwip-593236b4086e21f9552bb0281f6093b7cce875e9.tar.xz
lwip-593236b4086e21f9552bb0281f6093b7cce875e9.zip
Unify dependency generation: com32/lib, com32/cmenu
Add the unified dependency generation to com32/lib and com32/cmenu. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
-rw-r--r--com32/cmenu/Makefile8
-rw-r--r--com32/lib/MCONFIG25
-rw-r--r--com32/lib/Makefile4
3 files changed, 19 insertions, 18 deletions
diff --git a/com32/cmenu/Makefile b/com32/cmenu/Makefile
index db896e52..0ede58dc 100644
--- a/com32/cmenu/Makefile
+++ b/com32/cmenu/Makefile
@@ -41,11 +41,11 @@ MENUS = $(CMENUS) $(IMENUS)
.PRECIOUS: %.o
%.o: %.S
- $(CC) $(SFLAGS) -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(SFLAGS) -c -o $@ $<
.PRECIOUS: %.o
%.o: %.c %.h
- $(CC) $(CFLAGS) -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -c -o $@ $<
.PRECIOUS: %.elf
%.elf: %.o libmenu/libmenu.a $(LIBS)
@@ -62,7 +62,7 @@ libmenu/libmenu.a: $(LIBMENU)
$(RANLIB) $@
tidy dist:
- rm -f *.o *.lo *.a *.lst *.elf
+ rm -f *.o *.lo *.a *.lst *.elf .*.d */.*.d
libclean:
rm -f libmenu/*.o libmenu/*.a
@@ -79,3 +79,5 @@ spotless: clean libclean menuclean
menus: $(MENUS)
install: # Don't install samples
+
+-include .*.d */.*.d
diff --git a/com32/lib/MCONFIG b/com32/lib/MCONFIG
index aea0ed74..1eb18db1 100644
--- a/com32/lib/MCONFIG
+++ b/com32/lib/MCONFIG
@@ -26,8 +26,7 @@ OPTFLAGS = -Os -march=i386 -falign-functions=0 -falign-jumps=0 \
-falign-labels=0 -ffast-math -fomit-frame-pointer
WARNFLAGS = -W -Wall -Wpointer-arith -Wwrite-strings -Wstrict-prototypes -Winline
-CFLAGS = -Wp,-MT,$@,-MD,$(dir $@).$(notdir $@).d $(OPTFLAGS) \
- $(REQFLAGS) $(WARNFLAGS) $(LIBFLAGS)
+CFLAGS = $(OPTFLAGS) $(REQFLAGS) $(WARNFLAGS) $(LIBFLAGS)
LDFLAGS = -m elf32_i386
.SUFFIXES: .c .o .a .so .lo .i .S .s .ls .ss .lss
@@ -37,34 +36,34 @@ LDFLAGS = -m elf32_i386
% : %.S
.c.o:
- $(CC) $(CFLAGS) -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -c -o $@ $<
.c.i:
- $(CC) $(CFLAGS) -E -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -E -o $@ $<
.c.s:
- $(CC) $(CFLAGS) -S -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -S -o $@ $<
.S.o:
- $(CC) $(CFLAGS) -D__ASSEMBLY__ -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -D__ASSEMBLY__ -c -o $@ $<
.S.s:
- $(CC) $(CFLAGS) -D__ASSEMBLY__ -E -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -D__ASSEMBLY__ -E -o $@ $<
.S.lo:
- $(CC) $(CFLAGS) $(SOFLAGS) -D__ASSEMBLY__ -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) $(SOFLAGS) -D__ASSEMBLY__ -c -o $@ $<
.S.ls:
- $(CC) $(CFLAGS) $(SOFLAGS) -D__ASSEMBLY__ -E -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) $(SOFLAGS) -D__ASSEMBLY__ -E -o $@ $<
.s.o:
- $(CC) $(CFLAGS) -x assembler -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -x assembler -c -o $@ $<
.ls.lo:
- $(CC) $(CFLAGS) $(SOFLAGS) -x assembler -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) $(SOFLAGS) -x assembler -c -o $@ $<
.c.lo:
- $(CC) $(CFLAGS) $(SOFLAGS) -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) $(SOFLAGS) -c -o $@ $<
.c.ls:
- $(CC) $(CFLAGS) $(SOFLAGS) -S -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) $(SOFLAGS) -S -o $@ $<
diff --git a/com32/lib/Makefile b/com32/lib/Makefile
index 984c6dff..5e0e15ae 100644
--- a/com32/lib/Makefile
+++ b/com32/lib/Makefile
@@ -136,12 +136,12 @@ install: all
# These files are performance critical, and doesn't compile well with -Os
sys/vesa/drawtxt.o: sys/vesa/drawtxt.c
- $(CC) $(CFLAGS) -O3 -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -O3 -c -o $@ $<
sys/vesa/alphatbl.c: sys/vesa/alphatbl.pl
$(PERL) $< > $@
jpeg/jidctflt.o: jpeg/jidctflt.c
- $(CC) $(CFLAGS) -O3 -c -o $@ $<
+ $(CC) $(MAKEDEPS) $(CFLAGS) -O3 -c -o $@ $<
-include .*.d */.*.d */*/.*.d