Improved Makefiles.
[qshowdiff.git] / tests / Makefile
blobf9ebb860d2a5b1c04b0297a3e7c5fc78361f0064
1 CXXFLAGS += $(QT_CFLAGS)
2 LDFLAGS += $(QT_LIBS) -lcppu
4 TEST_SUITES = text.cpp snippet.cpp hunk.cpp diff.cpp levenshtein.cpp
5 OBJS_LIST = snippet.o settings.o text.o hunk.o diff.o file.o levenshtein.o
6 OBJS = $(foreach file, $(OBJS_LIST), ../src/objs/$(file))
8 all: run_tests
9 run_tests: test
10 -cppu-aggregate ./test
11 @echo
12 @echo -ne "Press key to start valgrind "
13 @read key
14 -valgrind --leak-check=full --show-reachable=yes ./test
16 test: main.cpp $(TEST_SUITES)
17 pwd && $(CC) $(CXXFLAGS) -o $@ $< $(OBJS) $(LDFLAGS)
19 clean:
20 rm -f test
21 rm -f *.o
23 .PHONY: all run_tests