blob: bc4209c5dc212f167a685635c77a48ed57a33ce8 [file] [log] [blame]
Gabor Greif021e9702008-03-15 07:26:41 +00001LEVEL = ../../..
2include $(LEVEL)/Makefile.common
3
Gabor Greif021e9702008-03-15 07:26:41 +00004TESTDIRS = CodeGen Lexer Preprocessor Parser Sema Analysis Serialization
5
6# Only run rewriter tests on darwin.
7ifeq ($(OS),Darwin)
8TESTDIRS += Rewriter
9endif
10
Gabor Greife1d26472008-03-17 15:58:58 +000011TESTS = $(addprefix Output/, $(addsuffix .testresults, $(shell find $(TESTDIRS) \( -name '*.c' -or -name '*.cpp' -or -name '*.m' \))))
Gabor Greif021e9702008-03-15 07:26:41 +000012
Gabor Greife1d26472008-03-17 15:58:58 +000013Output/%.testresults: %
Gabor Greif53c55672008-03-17 15:37:09 +000014 @ printf '.'
15 @ PATH=$$PATH:$(ToolDir):$(LLVM_SRC_ROOT)/test/Scripts ./TestRunner.sh $< > $@ || (echo; echo '----' $< 'failed ----')
Gabor Greif021e9702008-03-15 07:26:41 +000016
Gabor Greif53c55672008-03-17 15:37:09 +000017all::
Gabor Greife1d26472008-03-17 15:58:58 +000018 @ rm -f $(TESTS)
Gabor Greif5ca1b5a2008-03-17 12:35:00 +000019 @ echo '--- Running clang tests ---'
Gabor Greif53c55672008-03-17 15:37:09 +000020 @ $(MAKE) -f Makefile.parallel $(TESTS)
21 @ echo
22 @ $(MAKE) -f Makefile.parallel report
Gabor Greif021e9702008-03-15 07:26:41 +000023
Gabor Greif53c55672008-03-17 15:37:09 +000024report: $(TESTS)
25 @ cat $^
Gabor Greif021e9702008-03-15 07:26:41 +000026
Gabor Greife1d26472008-03-17 15:58:58 +000027.PHONY: all report