FIX BUILD
[ghc.git] / testsuite / timeout / Makefile
1 TOP = ..
2 include $(TOP)/mk/boilerplate.mk
3
4 HC = $(GHC_INPLACE)
5 BOOTSTRAPPING_PACKAGE_CONF_HC_OPTS=
6
7 MKDEPENDHS = $(GHC_INPLACE)
8 SRC_HC_OPTS += -threaded
9 EXCLUDED_SRCS += TimeMe.hs
10
11 ifeq "$(Windows)" "YES"
12 SRC_HC_OPTS += -package Win32
13 else
14 SRC_HC_OPTS += -package unix
15 endif
16
17 all :: calibrate.out
18
19 ifeq "$(findstring thr,$(GhcRTSWays))" "thr"
20 HS_PROG = timeout
21 else
22 all :: python-timeout
23 CLEAN_FILES += timeout
24 endif
25
26 boot :: all
27
28 calibrate.out:
29 rm -f TimeMe.o TimeMe.hi TimeMe
30 $(PYTHON) calibrate "$(HC)" > $@
31
32 CLEAN_FILES += calibrate.out
33
34 python-timeout:
35 cp timeout.py timeout
36 chmod +x timeout
37
38 include $(TOP)/mk/target.mk