SRCFILES = AnBmain.hs FPTranslator.hs AnBOnP.hs Msg.hs LMsg.hs MsgPat.hs AnBParser.hs Lexer.hs Ast.hs FiniteMap.hs NewIfLexer.hs TheoLexer.hs TheoParser.hs Constants.hs IntsOnly.hs Decomposition.hs MsgTree.hs Remola.hs Symbolic.hs NewIfParser.hs NewIfLexer.hs Search.hs TheoLoad.hs PrettyUgly.hs Main.hs Translator.hs

########################

all:	
	make ofmc

########################

ofmc:	$(SRCFILES)
	ghc -fglasgow-exts -XNoMonomorphismRestriction -static  -package base --make -O2 Main.hs -o ofmc

########################

NewIfLexer.hs:	NewIfLexer.x
	alex NewIfLexer.x

########################

NewIfParser.hs:	NewIfParser.y
	happy -ioutput  NewIfParser.y

########################

TheoLexer.hs:	TheoLexer.x
	alex TheoLexer.x

########################

TheoParser.hs:	TheoParser.y
	happy -ioutput  TheoParser.y

########################

Lexer.hs:	Lexer.x
	alex Lexer.x

########################

AnBParser.hs:	AnBParser.y
	happy -ioutput  AnBParser.y

########################

install:
	cp ofmc release/bin.`uname`/

########################

test:	
	pushd testsuite ; time ./runall ; popd

########################
# in case the output of the tool has changed:

ofcopy: 
	cp testsuite/*ofmc.of testsuite/output/
	cp testsuite/avispa-library/*ofmc.of testsuite/output/
#########################

clean: 
	rm -f *\.hi *\.o ofmc 

