Commit 543a9a2e authored by Ian Lynagh's avatar Ian Lynagh
Browse files

Add test mod175 for trac 437 (Recompilation check should include flags)

parent 5a54c38e
TOP=../../../..
include $(TOP)/mk/boilerplate.mk
include $(TOP)/mk/test.mk
clean:
rm -f *.o
rm -f *.hi
rm -f test test2
# Test for trac bug #437 (Test2 needs to be recompiled in the second GHC
# invocation as the main-is flag now applies to it).
mod175:
$(MAKE) clean
$(TEST_HC) -v0 --make -main-is Test.main Test.hs -o test
$(TEST_HC) -v0 --make -main-is Test2.main Test2.hs -o test2
./test
./test2
module Test where
import Test2 hiding (main)
main = doit
module Test2 where
doit = putStrLn "You have run Test2.doit"
main = putStrLn "You have run Test2.main"
setTestOpts(only_compiler_types(['ghc']))
test('mod175', normal, run_command, ['$MAKE -s mod175'])
if default_testopts.cleanup != '':
runCmd('$MAKE -C ' + in_testdir('') + ' clean')
You have run Test2.doit
You have run Test2.main
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment