build/unix/test/Makefile.in

branch
TOR_BUG_9701
changeset 10
ac0c01689b40
equal deleted inserted replaced
-1:000000000000 0:72cb52580347
1 # -*- makefile -*-
2 #
3 # This Source Code Form is subject to the terms of the Mozilla Public
4 # License, v. 2.0. If a copy of the MPL was not distributed with this
5 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
7 include $(topsrcdir)/config/rules.mk
8
9 ##################################################
10 ## Gather a list of tests, generate timestamp deps
11 ##################################################
12 TS=.ts
13 ifneq (,$(findstring check,$(MAKECMDGOALS)))
14 allsrc = $(wildcard $(srcdir)/*)
15 tests2run = $(notdir $(filter %.tpl,$(allsrc)))
16 check_targets += $(addprefix $(TS)/,$(tests2run))
17 endif
18
19 check:: $(TS) $(check_targets)
20
21 #############################################
22 # Only invoke tests when sources have changed
23 #############################################
24 $(TS)/%: $(srcdir)/%
25 $(PERL) $(srcdir)/runtest $<
26 @touch $@
27
28 #####################################################
29 ## Extra dep needed to synchronize parallel execution
30 #####################################################
31 $(TS): $(TS)/.done
32 $(TS)/.done:
33 $(MKDIR) -p $(dir $@)
34 touch $@
35
36 GARBAGE_DIRS += $(TS)
37
38 # EOF

mercurial