test.mk 1.14 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
# -----------------------------------------------------------------------------
# Examples of use:
#
# 	make		-- run all the tests in the current directory
# 	make verbose	-- as make test, but up the verbosity
# 	make accept	-- run the tests, accepting the current output
#
# The following variables may be set on the make command line:
#
#	TESTS		-- specific tests to run
#	EXTRA_HC_OPTS	-- extra flags to send to the Haskell compiler
#	EXTRA_RUNTEST_OPTS -- extra flags to give the test driver
#	CONFIG		-- use a different configuration file
#
# -----------------------------------------------------------------------------

# gastly hack, because the driver requires that $tool be an absolute path name.
GHC_INPLACE_ABS	= $(FPTOOLS_TOP_ABS)/ghc/compiler/ghc-inplace

RUNTESTS     = $(TOP)/driver/runtests
RUNTEST_OPTS =  --config=$(CONFIG) tool=$(GHC_INPLACE_ABS) extra_hc_flags="$(EXTRA_HC_OPTS)" $(EXTRA_RUNTEST_OPTS)
CONFIG       = $(TOP)/config/msrc/cam-02-unx.T
TESTS	     = 

all :: test

test:
	$(RUNTESTS) $(RUNTEST_OPTS) $(TESTS)

verbose:
	$(RUNTESTS) $(RUNTEST_OPTS) verbose= $(TESTS)

accept:
	$(RUNTESTS) $(RUNTEST_OPTS) accept= verbose= $(TESTS)