diff options
author | David Gibson <dgibson@mulberryst.seuss> | 2007-06-14 15:05:55 +1000 |
---|---|---|
committer | David Gibson <dgibson@mulberryst.seuss> | 2007-06-14 15:05:55 +1000 |
commit | 12578976fe9cef82f0c08db3f9a4f550f5085ba4 (patch) | |
tree | cba2b4ddb05edb66e92e171076d0ea476e153e61 /Makefile | |
parent | 400bd98a3a4177c8c399fd1270bf58cba43d1f35 (diff) | |
download | dtc-12578976fe9cef82f0c08db3f9a4f550f5085ba4.tar.gz |
Merge libfdt into dtc.
Having pulled the libfdt repository into dtc, merge the makefiles and
testsuites so that they build together usefully.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 36 |
1 files changed, 31 insertions, 5 deletions
@@ -9,7 +9,9 @@ DTC_OBJS = dtc.o flattree.o fstree.o data.o livetree.o \ DEPFILES = $(DTC_OBJS:.o=.d) -all: $(TARGETS) +.PHONY: libfdt tests + +all: $(TARGETS) tests libfdt dtc: $(DTC_OBJS) $(LINK.c) -o $@ $^ @@ -17,6 +19,9 @@ dtc: $(DTC_OBJS) ftdump: ftdump.o $(LINK.c) -o $@ $^ +libfdt: + cd libfdt && $(MAKE) all + dtc-parser.tab.c dtc-parser.tab.h dtc-parser.output: dtc-parser.y $(BISON) -d $< @@ -25,17 +30,38 @@ lex.yy.c: dtc-lexer.l lex.yy.o: lex.yy.c dtc-parser.tab.h -check: all - cd tests && $(MAKE) check +tests: tests/all + +tests/%: libfdt + $(MAKE) -C tests $* + +check: all + cd tests; ./run_tests.sh + +checkv: all + cd tests; ./run_tests.sh -v + +func: all + cd tests; ./run_tests.sh -t func + +funcv: all + cd tests; ./run_tests.sh -t func -v + +stress: all + cd tests; ./run_tests.sh -t stress + +stressv: all + cd tests; ./run_tests.sh -t stress -v clean: rm -f *~ *.o a.out core $(TARGETS) rm -f *.tab.[ch] lex.yy.c rm -f *.i *.output vgcore.* rm -f *.d - cd tests && $(MAKE) clean + $(MAKE) -C libfdt clean + $(MAKE) -C tests clean %.d: %.c - $(CC) -MM -MG -MT "$*.o $@" $< > $@ + $(CC) $(CPPFLAGS) -MM -MG -MT "$*.o $@" $< > $@ -include $(DEPFILES) |