Makefile revision 8f31d51d47da96200437dd3af1d785cd88a46f71
43b4c41fbb07705c9df321221ab9cb9832460407Christian Maeder# Makefile
c63ebf815c8a874525cf18670ad74847f7fc7b26Christian Maeder# $Id$
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# Author: (c) Klaus Luettich, Christian Maeder, Uni Bremen 2002-2009
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# This Makefile will compile the hets system and provides also
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder# targets for test programs during implementation phases.
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder# !!! Note: This makefile is written for GNU make !!!
43b4c41fbb07705c9df321221ab9cb9832460407Christian Maeder# (gmake on solaris)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
f4a2a20e49f41b2afa657e5e64d9e349c7faa091Christian Maederall: hets
f2f9df2e17e70674f0bf426ed1763c973ee4cde0Christian Maeder
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maederinclude var.mk
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# deprecated since haddock 2
68d10d143f29fcff3c637ba24f90e983995ceae6Christian MaederSOURCE_PATHS = . utils/itcor \
96646aed2ae087b942ae23f15bbe729a8f7c43d3Christian Maeder utils utils/DrIFT-src utils/GenerateRules utils/InlineAxioms Common \
01e383014b555bbcf639c0ca60c5810b3eff83c0Christian Maeder Common/Lib Common/ATerm Logic CASL CASL/CCC CASL/CompositionTable \
3b06e23643a9f65390cb8c1caabe83fa7e87a708Till Mossakowski Syntax Static GUI HasCASL Haskell Modal CoCASL COL ConstraintCASL \
9dac90ec2be2a72e03893095461960d483fe2fc2Christian Maeder CspCASL ATC Proofs Comorphisms Isabelle Driver Modifications \
5e5d3e82af3bc2834f8718a52d9f45da80220273Dominik Luecke Taxonomy CASL_DL SoftFOL OWL OMDoc PGIP Propositional RelationalScheme \
124c859ba4741d5e36d5d98634886b430b7af093Christian Maeder VSE Interfaces Temporal CspCASLProver DFOL CMDL
ce8b15da31cd181b7e90593cbbca98f47eda29d6Till Mossakowski
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder# the 'replacing spaces' example was taken from the (GNU) Make info manual
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maederempty =
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maederspace = $(empty) $(empty)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder
a1ed34933c266ce85066acb0d7b20c90cb8eb213Christian MaederDRIFT_ENV = DERIVEPATH=$(subst $(space),:,$(PFE_PATHS))
c0c2380bced8159ff0297ece14eba948bd236471Christian Maeder
404166b9366552e9ec5abb87a37c76ec8a815fb7Klaus LuettichDRIFT_deps = utils/DrIFT-src/*hs
b1f59a4ea7c96f4c03a4d7cfcb9c5e66871cfbbbChristian MaederGENERATERULES_deps = utils/GenerateRules/*hs $(DRIFT_deps)
ad270004874ce1d0697fb30d7309f180553bb315Christian MaederGENITCORRECTIONS_deps = utils/itcor/GenItCorrections.hs
4d56f2fa72e4aec20eb827c11ed49c8cbb7014bdChristian MaederINLINEAXIOMS_deps = utils/InlineAxioms/InlineAxioms.hs \
4cb215739e9ab13447fa21162482ebe485b47455Christian Maeder Common/Doc.hs CASL/ToDoc.hs Modal/AS_Modal.hs \
8ef75f1cc0437656bf622cec5ac9e8ea221da8f2Christian Maeder Modal/Parse_AS.hs Modal/ModalSign.hs Modal/Print_AS.hs Modal/StatAna.hs
404166b9366552e9ec5abb87a37c76ec8a815fb7Klaus Luettich
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederPERL = perl
74eed04be26f549d2f7ca35c370e1c03879b28b1Christian MaederHAPPY = happy -sga
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederGENRULES = utils/genRules
3e8b136f23ed57d40ee617f49bcac37830b58cabChristian MaederGENRULECALL = $(GENRULES) -r Typeable -r ShATermConvertible \
ef9e8535c168d3f774d9e74368a2317a9eda5826Christian Maeder -i Data.Typeable -i ATerm.Lib
3e8b136f23ed57d40ee617f49bcac37830b58cabChristian MaederGENRULECALL2 = $(GENRULES) -r Typeable -r ShATermLG \
ef9e8535c168d3f774d9e74368a2317a9eda5826Christian Maeder -i Data.Typeable -i ATerm.Lib -i ATC.Grothendieck
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederDRIFT = utils/DrIFT
e593b89bfd4952698dc37feced21cefe869d87a2Christian MaederINLINEAXIOMS = utils/outlineAxioms
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederHADDOCK = haddock
f38b3687c5558128515e34fb85d8b466d22dc300Christian MaederHADDOCKVERSION = $(shell $(HADDOCK) --version)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
7cc09dd93962a2155c34d209d1d4cd7d7b838264Christian MaederOSBYUNAME = $(shell uname)
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maederifneq ($(findstring SunOS, $(OSBYUNAME)),)
1aee4aaddde105264c1faf394d88e302c05094ffChristian MaederTAR = gtar
51d769d55d88dfa88bdf54bee78d8fa85a2deba8Christian MaederPATCH = gpatch
f041c9a6bda23de33a38490e35b831ae18d96b45Christian Maederelse
7cc09dd93962a2155c34d209d1d4cd7d7b838264Christian MaederTAR = tar
51d769d55d88dfa88bdf54bee78d8fa85a2deba8Christian MaederPATCH = patch
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maederendif
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder
c3053d57f642ca507cdf79512e604437c4546cb9Christian MaederARCH = $(subst $(space),,$(shell uname -m))
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian MaederSETUP = utils/Setup
f4a2a20e49f41b2afa657e5e64d9e349c7faa091Christian MaederSETUPPREFIX = --prefix=$(HOME)/.ghc/$(ARCH)-$(OSBYUNAME)-hets-packages
f4a2a20e49f41b2afa657e5e64d9e349c7faa091Christian Maeder
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian MaederSETUPPACKAGE = ../$(SETUP) clean; \
05a62e84edac8c64de04f8349dee418598d216b9Christian Maeder ../$(SETUP) configure -O -p $(SETUPPREFIX) --user; \
05a62e84edac8c64de04f8349dee418598d216b9Christian Maeder ../$(SETUP) build; ../$(SETUP) haddock; ../$(SETUP) install --user
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder# list glade files
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian MaederGTK_GLADE_FILES = $(wildcard GUI/Glade/*.glade)
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian MaederGTK_GLADE_HSFILES = $(subst .glade,.hs,$(GTK_GLADE_FILES))
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maederderived_sources += $(GTK_GLADE_HSFILES)
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# the list of logics that need ShATermConvertible instances
d54cd08a4cfa26256c38d8ed12c343adbfe1a0e3Christian Maederlogics = CASL HasCASL Isabelle Modal Temporal CoCASL COL CspCASL CASL_DL \
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian Maeder SoftFOL ConstraintCASL Propositional OWL RelationalScheme VSE OMDoc DFOL \
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian Maeder Maude
8cacad2a09782249243b80985f28e9387019fe40Christian Maeder
363939beade943a02b31004cea09dec34fa8a6d9Christian MaederTESTTARGETFILES += CASL/fromKif.hs CASL/capa.hs HasCASL/hacapa.hs \
a7c27282e71cf4505026645f96d4f5cb8a284e32Christian Maeder Haskell/wrap.hs Isabelle/isa.hs Syntax/hetpa.hs \
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder ATC/ATCTest.hs ATC/ATCTest2.hs Common/ATerm/ATermLibTest.hs \
8a28707e9155465c6f2236a06eac6580a65c7025Christian Maeder Common/ATerm/ATermDiffMain.hs Common/annos.hs Common/test_parser.hs \
f04e8f3ff56405901be968fd4c6e9769239f1a9bKlaus Luettich SoftFOL/tests/PrintTPTPTests.hs Comorphisms/test/showKP.hs \
4e23d551da8fb051cc4752319740ae7858ef1044Christian Maeder Comorphisms/test/sublogicGraph.hs \
797ccd67cb8ae127be097cd43448801b673e3b69Christian Maeder SoftFOL/dfg.hs
431d34c7007a787331c4e5ec997badb0f8190fc7Christian Maeder
f1541d4a151dbd08002dbd14e7eb1d5dde253689Christian Maeder### list of directories to run checks in
498aa48bdb931ab50990d3b74318a5db2312186cChristian MaederTESTDIRS += Common CASL HasCASL test
f1541d4a151dbd08002dbd14e7eb1d5dde253689Christian Maeder
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maederhs_clean_files = Haskell/TiATC.hs Haskell/TiDecorateATC.hs \
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maeder Haskell/TiPropATC.hs Haskell/ATC_Haskell.der.hs
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maeder
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederPFE_TOOLDIR = $(wildcard ../programatica/tools)
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maederifneq ($(strip $(PFE_TOOLDIR)),)
c0c2380bced8159ff0297ece14eba948bd236471Christian MaederPFE_DIRS = base/AST base/TI base/parse2 base/parse2/Lexer base/parse2/Parser \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder base/parse2/LexerGen base/parse2/LexerSpec base/tests/HbcLibraries \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder base/pretty base/syntax base/lib base/lib/Monads base/Modules base/defs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder base/transforms base/transforms/Deriving property \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder property/syntax property/AST property/transforms \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder property/TI property/defs property/parse2 property/parse2/Parser
9e748851c150e1022fb952bab3315e869aaf0214Christian Maeder
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederPFE_PATHS = $(addprefix $(PFE_TOOLDIR)/, $(PFE_DIRS))
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maederpfe_sources = $(wildcard $(addsuffix /*hs, $(PFE_PATHS)))
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederPFE_PATH = $(addprefix -i, $(PFE_PATHS))
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maederhappy_files += $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hs
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederLEX_DIR = $(PFE_TOOLDIR)/base/parse2/Lexer
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder
a5e5b8c3e5c11177e5034ef2423813a5d28979edChristian Maederprogramatica_pkg: $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hs \
bc8cbf12aa172bf5673b92a9e7a0151d4aa4c315Christian Maeder $(LEX_DIR)/HsLex.hs $(SETUP)
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder @if $(HCPKG) field programatica version; then \
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder echo "of programatica package found"; else \
51d769d55d88dfa88bdf54bee78d8fa85a2deba8Christian Maeder ($(PATCH) -usNlp0 -d $(PFE_TOOLDIR) \
a5e5b8c3e5c11177e5034ef2423813a5d28979edChristian Maeder -i `pwd`/Haskell/Programatica.patch || exit 0); \
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder cp -f utils/programatica.cabal ../programatica/tools; \
bc8cbf12aa172bf5673b92a9e7a0151d4aa4c315Christian Maeder cp -f $(SETUP) ../programatica/tools; \
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder (cd ../programatica/tools; \
f4a2a20e49f41b2afa657e5e64d9e349c7faa091Christian Maeder ./Setup configure $(SETUPPREFIX); \
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder ./Setup build; ./Setup install --user) fi
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder$(LEX_DIR)/HsLex.hs: $(LEX_DIR)Gen/HsLexerGen
6ff7a91875597d6e4dfaa68c79187d01473e8341Christian Maeder echo "{-# OPTIONS -w #-}" > $@
6ff7a91875597d6e4dfaa68c79187d01473e8341Christian Maeder $< >> $@
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder$(LEX_DIR)Gen/HsLexerGen: $(LEX_DIR)Gen/*.hs $(LEX_DIR)Spec/*.hs \
4017ebc0f692820736d796af3110c3b3018c108aChristian Maeder $(LEX_DIR)/HsTokens.hs
a9b59eb2ce961014974276cdae0e9df4419bd212Christian Maeder $(HC) --make -fno-monomorphism-restriction -O \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder -i$(PFE_TOOLDIR)/base/tests/HbcLibraries \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder -i$(PFE_TOOLDIR)/base/lib \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder -i$(LEX_DIR) -i$(LEX_DIR)Gen -i$(LEX_DIR)Spec \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder $@.hs -o $@
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder
a3c6d8e0670bf2aa71bc8e2a3b1f45d56dd65e4cChristian Maederlogics += Haskell
dc679edd4ca027663212afdf00926ae2ce19b555Christian Maederderived_sources += Haskell/PreludeString.hs
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder
ca074a78b8dcccbb8c419586787882f98d0c6163Christian MaederAPPENDPRELUDESTRING = utils/appendHaskellPreludeString \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Haskell/ProgramaticaPrelude.hs
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder## rule for appendHaskellPreludeString
ca074a78b8dcccbb8c419586787882f98d0c6163Christian MaederHaskell/PreludeString.hs: Haskell/PreludeString.append.hs \
4017ebc0f692820736d796af3110c3b3018c108aChristian Maeder $(APPENDPRELUDESTRING)
b568982efd0997d877286faa592d81b03c8c67b8Christian Maeder $(RM) $@
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder $(APPENDPRELUDESTRING) < $< > $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich chmod 444 $@
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederAst_Haskell_files = HsDeclStruct HsExpStruct HsFieldsStruct \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder HsGuardsStruct HsKindStruct HsPatStruct HsTypeStruct HsAssocStruct \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder HsModule HsName HsLiteral HsIdent
f2f9df2e17e70674f0bf426ed1763c973ee4cde0Christian Maeder
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder#files in base/TI/
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder#Ti_Haskell_files = TiTypes TiKinds TiDecorate TiInstanceDB
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder#Ti_Prop_files = property/TI/TiPropDecorate property/syntax/PropSyntaxRec
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederOther_PFE_files = property/AST/HsPropStruct base/defs/PNT \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder base/defs/UniqueNames base/Modules/TypedIds base/Modules/Ents \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder base/parse2/SourceNames base/syntax/SyntaxRec \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder property/syntax/PropSyntaxStruct
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder
ca074a78b8dcccbb8c419586787882f98d0c6163Christian MaederHaskell_files = $(addsuffix .hs, \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(addprefix $(PFE_TOOLDIR)/base/AST/, $(Ast_Haskell_files)) \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(addprefix $(PFE_TOOLDIR)/, $(Other_PFE_files)))
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder## rule for ATC generation
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederHaskell/ATC_Haskell.der.hs: $(Haskell_files) $(GENRULES)
3e8b136f23ed57d40ee617f49bcac37830b58cabChristian Maeder $(GENRULECALL) -i Haskell.BaseATC -o $@ $(Haskell_files)
f1541d4a151dbd08002dbd14e7eb1d5dde253689Christian Maeder
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maederhs_der_files += $(hs_clean_files)
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder
e6d5dbbc3308f05197868806e0b860f4f53875f1Christian MaederTESTDIRS += ToHaskell
363939beade943a02b31004cea09dec34fa8a6d9Christian MaederTESTTARGETFILES += Haskell/hana.hs Haskell/h2h.hs Haskell/h2hf.hs
e4f4d096e5e6d60dd91c746d0e833d0ac7a29c50Christian Maederelse
eb74267cf39e4e95f9eeb5c765f4c8dac33971b4Christian Maeder# unset this variable from var.mk because the programatica sources
eb74267cf39e4e95f9eeb5c765f4c8dac33971b4Christian Maeder# are needed to created our sources!
e4f4d096e5e6d60dd91c746d0e833d0ac7a29c50Christian MaederPFE_FLAGS =
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maederendif
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# end of programatica stuff
f1541d4a151dbd08002dbd14e7eb1d5dde253689Christian Maeder
363939beade943a02b31004cea09dec34fa8a6d9Christian MaederTESTTARGETS = Test.o $(subst .hs,,$(TESTTARGETFILES))
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maeder# remove -fno-warn-orphans for older ghcs and add -ifgl
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian MaederHC_WARN = -Wall -fno-warn-orphans
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
10883d13973c46cac98964b66ace7a52b2d059abChristian MaederINCLUDE_PATH =
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian MaederHC_INCLUDE = $(addprefix -i, $(INCLUDE_PATH))
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# uncomment HC_PROF for profiling (and comment out packages in var.mk)
0e5b095a19790411e5352fa7cf57cb0388e70472Christian Maeder# call resulting binary with a final +RTS -p to get a file <binary>.prof
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# HC_PROF = -prof -auto-all -osuf p_o +RTS -K100m -RTS
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian MaederHC_OPTS += $(HC_WARN) $(HC_INCLUDE) $(HC_PROF)
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maeder# -ddump-minimal-imports
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# uncomment the above line to generate .imports files for displayDependencyGraph
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder## deprecated non-sources to be excluded for haddock-0.8
42b12fba6830ada5057949f825fc27edf5574e5fChristian Maedernon_sources = Common/LaTeX_maps.svmono.hs Common/CaslLanguage.hs ./Test.hs \
42b12fba6830ada5057949f825fc27edf5574e5fChristian Maeder $(SETUP).hs
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder## deprecated hets sources for haddock-0.8
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maedersources = hets.hs $(filter-out $(non_sources), \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(wildcard $(addsuffix /[A-Z]*hs, $(SOURCE_PATHS))))
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# files generated by DriFT
93f5b72fdb9ee734caa750b43dd79bbb590dcd73Christian Maederdrifted_files = Common/AS_Annotation.hs \
93f5b72fdb9ee734caa750b43dd79bbb590dcd73Christian Maeder CASL/AS_Basic_CASL.hs Modal/AS_Modal.hs \
93f5b72fdb9ee734caa750b43dd79bbb590dcd73Christian Maeder Syntax/AS_Structured.hs Syntax/AS_Architecture.hs Syntax/AS_Library.hs \
93f5b72fdb9ee734caa750b43dd79bbb590dcd73Christian Maeder Propositional/AS_BASIC_Propositional.hs \
328a85c807f2a95c3f147d10b05927eaf862ebebChristian Maeder CoCASL/AS_CoCASL.hs COL/AS_COL.hs \
a6db617ca58eb6a0587b6366e913107dfecb71b5Heng Jiang CASL_DL/AS_CASL_DL.hs OWL/ReadWrite.hs \
06dd4e7c29f33f6122a910719e3bd9062256e397Andy Gimblett CspCASL/AS_CspCASL_Process.hs CspCASL/AS_CspCASL.hs \
254df6f22d01eacf7c57b85729e0445747b630d9Christian Maeder RelationalScheme/AS.hs ATC/Grothendieck.hs \
5b818f10e11fc79def1fdd5c8a080d64a6438d87Christian Maeder $(gendrifted_files)
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix Reckers
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# files to extract data types from to generate ShATermConvertible instances
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maederatc_files = Common/AS_Annotation.der.hs Common/DefaultMorphism.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Syntax/AS_Structured.der.hs Syntax/AS_Architecture.der.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Common/GlobalAnnotations.hs Syntax/AS_Library.der.hs \
a14767aeac3e78ed100f5b75e210ba563ee10dbaChristian Maeder Logic/Prover.hs Common/LibName.hs Common/ExtSign.hs \
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder Common/ProofTree.hs Static/DevGraph.hs \
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder Common/Id.hs Common/Result.hs Common/OrderedMap.hs \
3e8b136f23ed57d40ee617f49bcac37830b58cabChristian Maeder Common/Lib/Graph.hs
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix Reckers
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# files generated by genRules as input for DriFT
9e748851c150e1022fb952bab3315e869aaf0214Christian Maederatc_der_files = $(foreach file, $(atc_files), \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder ATC/$(basename $(basename $(notdir $(file)))).der.hs)
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# the rules to create ATC .der.hs file for DriFT
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian MaederATC/Id.der.hs: Common/Id.hs $(GENRULES)
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder $(GENRULECALL) -o $@ $<
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian MaederATC/Result.der.hs: Common/Result.hs $(GENRULES)
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder $(GENRULECALL) -i ATC.Id -o $@ $<
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder
aded505f9b42cc38975559c2a5d175ae95de436bChristian MaederATC/OrderedMap.der.hs: Common/OrderedMap.hs $(GENRULES)
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder $(GENRULECALL) -o $@ $<
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder
aded505f9b42cc38975559c2a5d175ae95de436bChristian MaederATC/Graph.der.hs: Common/Lib/Graph.hs $(GENRULES)
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder $(GENRULECALL) -o $@ $<
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder
a14767aeac3e78ed100f5b75e210ba563ee10dbaChristian MaederATC/ProofTree.der.hs: Common/ProofTree.hs $(GENRULES)
a14767aeac3e78ed100f5b75e210ba563ee10dbaChristian Maeder $(GENRULECALL) -o $@ $<
a14767aeac3e78ed100f5b75e210ba563ee10dbaChristian Maeder
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederATC/AS_Annotation.der.hs: Common/AS_Annotation.der.hs $(GENRULES)
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder $(GENRULECALL) -i ATC.Id -i Common.ATerm.ConvInstances -o $@ $<
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder
697e63e30aa3c309a1ef1f9357745111f8dfc5a9Christian MaederATC/LibName.der.hs: Common/LibName.hs $(GENRULES)
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder $(GENRULECALL) -i ATC.Id -i Common.ATerm.ConvInstances -o $@ $<
697e63e30aa3c309a1ef1f9357745111f8dfc5a9Christian Maeder
f9e0b18852b238ddb649d341194e05d7200d1bbeChristian MaederATC/ExtSign.der.hs: Common/ExtSign.hs $(GENRULES)
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder $(GENRULECALL) -i Common.ATerm.ConvInstances -o $@ $<
f9e0b18852b238ddb649d341194e05d7200d1bbeChristian Maeder
819e29dba060687cf391e444e0f6ff88c1908cc3Christian MaederATC/DefaultMorphism.der.hs: Common/DefaultMorphism.hs $(GENRULES)
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maeder $(GENRULECALL) -o $@ $<
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maeder
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederATC/AS_Structured.der.hs: Syntax/AS_Structured.der.hs $(GENRULES)
254df6f22d01eacf7c57b85729e0445747b630d9Christian Maeder $(GENRULECALL2) -o $@ $<
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederATC/AS_Architecture.der.hs: Syntax/AS_Architecture.der.hs $(GENRULES)
254df6f22d01eacf7c57b85729e0445747b630d9Christian Maeder $(GENRULECALL2) -i ATC.AS_Structured -o $@ $<
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederATC/AS_Library.der.hs: Syntax/AS_Library.der.hs $(GENRULES)
254df6f22d01eacf7c57b85729e0445747b630d9Christian Maeder $(GENRULECALL2) -i ATC.AS_Architecture -i ATC.LibName -o $@ $<
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederATC/GlobalAnnotations.der.hs: Common/GlobalAnnotations.hs $(GENRULES)
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder $(GENRULECALL) -i ATC.AS_Annotation -i ATC.Result -o $@ $<
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederATC/Prover.der.hs: Logic/Prover.hs $(GENRULES)
ac34194a668399bb8ef238da77c3a09e93fb253bChristian Maeder $(GENRULECALL) -x Logic.Prover.ProverTemplate \
aded505f9b42cc38975559c2a5d175ae95de436bChristian Maeder -i ATC.AS_Annotation -i ATC.OrderedMap -o $@ $<
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder
1842453990fed8a1bd7a5ac792d7982c1d2bfcd5Christian MaederATC/DevGraph.der.hs: Static/DevGraph.hs $(GENRULES)
254df6f22d01eacf7c57b85729e0445747b630d9Christian Maeder $(GENRULECALL2) -i ATC.LibName -o $@ $<
1842453990fed8a1bd7a5ac792d7982c1d2bfcd5Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# ATC files for every logic
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederCASL_files = CASL/Sublogic.hs CASL/Morphism.hs CASL/Sign.hs \
986d3f255182539098a97ac86da9eeee5b7a72e3Christian Maeder CASL/AS_Basic_CASL.der.hs
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder
4561227a776bdf0ab679b19fb92f1eaaed8786f7Christian MaederHasCASL_files = Common/Prec.hs HasCASL/As.hs HasCASL/Le.hs HasCASL/Sublogic.hs
01e278bdd7dce13b9303ed3d79683d83c89d09f9Liam O'ReillyIsabelle_files = Isabelle/IsaSign.hs
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder
5ad5dffe06818a13e1632b1119fbca7881085fc1Dominik LueckePropositional_files = Propositional/Sign.hs Propositional/Morphism.hs \
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder Propositional/AS_BASIC_Propositional.hs Propositional/Symbol.hs \
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder Propositional/Sublogic.hs
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder
05a206508bc898f87fe6ab6e069814df3c29d303Dominik LueckeRS_files = RelationalScheme/AS.hs RelationalScheme/Sign.hs
05a206508bc898f87fe6ab6e069814df3c29d303Dominik Luecke
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederModal_files = Modal/AS_Modal.hs Modal/ModalSign.hs
d54cd08a4cfa26256c38d8ed12c343adbfe1a0e3Christian MaederTemporal_files = Temporal/AS_BASIC_Temporal.hs Temporal/Sign.hs \
d54cd08a4cfa26256c38d8ed12c343adbfe1a0e3Christian Maeder Temporal/Symbol.hs Temporal/Morphism.hs
d54cd08a4cfa26256c38d8ed12c343adbfe1a0e3Christian Maeder
3b06e23643a9f65390cb8c1caabe83fa7e87a708Till MossakowskiConstraintCASL_files = ConstraintCASL/AS_ConstraintCASL.hs
b1f59a4ea7c96f4c03a4d7cfcb9c5e66871cfbbbChristian MaederCoCASL_files = CoCASL/AS_CoCASL.hs CoCASL/CoCASLSign.hs
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederCOL_files = COL/AS_COL.hs COL/COLSign.hs
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder
0b349288edfa50fdf38fda1a14e1562d03f92574Christian MaederCspCASL_files = CspCASL/AS_CspCASL.hs CspCASL/AS_CspCASL_Process.hs \
33bdce26495121cdbce30331ef90a1969126a840Liam O'Reilly CspCASL/SignCSP.hs CspCASL/Morphism.hs
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder
1b3a2f98d1cd01fc9e0591f69507e20526727559Dominik LueckeCASL_DL_files = CASL_DL/AS_CASL_DL.hs CASL_DL/Sign.hs CASL_DL/Sublogics.hs
f04e8f3ff56405901be968fd4c6e9769239f1a9bKlaus LuettichSoftFOL_files = SoftFOL/Sign.hs
247cc88aa55d0a7b6831767cd593ea885c6747a0Christian MaederOWL_files = OWL/Sign.hs OWL/Sublogic.hs OWL/Morphism.hs
e39a1626bee36d6ad13a2c0014a80ef179a65bcbChristian MaederVSE_files = VSE/As.hs
f8e1a1eca871a26a535a4ee7d51902ba94b1db1eChristian MaederOMDoc_files = OMDoc/OMDocInterface.hs
ea3bff3e547a1ac714d4db39c5efef95e02b2e7dChristian MaederDFOL_files = DFOL/AS_DFOL.hs DFOL/Sign.hs DFOL/Morphism.hs DFOL/Symbol.hs
abf2487c3aece95c371ea89ac64319370dcb6483Klaus Luettich
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian MaederMaude_files = Maude/Sign.hs Maude/Morphism.hs Maude/Sentence.hs \
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian Maeder Maude/Symbol.hs Maude/AS_Maude.hs
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# ATC DrIFT-rule generation for logics
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederCASL/ATC_CASL.der.hs: $(CASL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i ATC.GlobalAnnotations -o $@ $(CASL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederRelationalScheme/ATC_RelationalScheme.der.hs: $(RS_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i ATC.GlobalAnnotations -o $@ $(RS_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederPropositional/ATC_Propositional.der.hs: $(Propositional_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(Propositional_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederHasCASL/ATC_HasCASL.der.hs: $(HasCASL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i ATC.GlobalAnnotations -o $@ $(HasCASL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederIsabelle/ATC_Isabelle.der.hs: $(Isabelle_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -o $@ $(Isabelle_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederModal/ATC_Modal.der.hs: $(Modal_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(Modal_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederTemporal/ATC_Temporal.der.hs: $(Temporal_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(Temporal_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederConstraintCASL/ATC_ConstraintCASL.der.hs: $(ConstraintCASL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(ConstraintCASL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederCASL_DL/ATC_CASL_DL.der.hs: $(CASL_DL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CASL_DL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederCoCASL/ATC_CoCASL.der.hs: $(CoCASL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CoCASL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederCOL/ATC_COL.der.hs: $(COL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(COL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederCspCASL/ATC_CspCASL.der.hs: $(CspCASL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CspCASL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederSoftFOL/ATC_SoftFOL.der.hs: $(SoftFOL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(SoftFOL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederOWL/ATC_OWL.der.hs: $(OWL_files) $(GENRULES)
3e8b136f23ed57d40ee617f49bcac37830b58cabChristian Maeder $(GENRULECALL) -i OWL.ReadWrite -o $@ $(OWL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederVSE/ATC_VSE.der.hs: $(VSE_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -x VSE.As.FoldRec -i CASL.ATC_CASL -o $@ $(VSE_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederOMDoc/ATC_OMDoc.der.hs: $(OMDoc_files) $(GENRULES)
3e8b136f23ed57d40ee617f49bcac37830b58cabChristian Maeder $(GENRULECALL) -i OMDoc.ATerm -o $@ $(OMDoc_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaederDFOL/ATC_DFOL.der.hs: $(DFOL_files) $(GENRULES)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(DFOL_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian MaederMaude/ATC_Maude.der.hs: $(Maude_files) $(GENRULES)
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(Maude_files)
23b4e542dca35852f58d1fb3f7d9078c1de5ab06Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# all ATC .der.hs files for all logics
c70ef4c3b3a62764f715510c9fd67dde3acfe454Christian Maederatc_logic_files = $(foreach logic, $(logics), $(logic)/ATC_$(logic).der.hs)
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maedergenerated_rule_files = $(atc_der_files) $(atc_logic_files)
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix Reckers
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# a rule to create all .der.hs files
456238178f89e5a3de2988ee6c8af924297d52d9Christian MaedergenRules: $(generated_rule_files)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# the final ATC target files created by DriFT
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maedergendrifted_files = $(patsubst %.der.hs, %.hs, $(generated_rule_files))
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# files to be processed by utils/InlineAxioms
b9b960bc75e34658e70c4a0231dbc6a6e7373f2dChristian Maederinline_axiom_files = Comorphisms/CASL2PCFOL.hs \
18a4d5cb6828f080db9c5f9551785c5151027271Christian Maeder Comorphisms/Modal2CASL.hs Comorphisms/CASL2TopSort.hs \
846d851fc0c2c49e949763cd3407634ba0f726c0Christian Maeder Comorphisms/CASL2SubCFOL.hs CASL_DL/PredefinedSign.hs
9e748851c150e1022fb952bab3315e869aaf0214Christian Maeder
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maedergen_inline_axiom_files = $(patsubst %.hs,%.inline.hs, $(inline_axiom_files))
fdb2d618144159395f7bf8ce3327b3c112a17dd3Till Mossakowski
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# all sources that need to be created before ghc can be called
43b4c41fbb07705c9df321221ab9cb9832460407Christian Maederderived_sources += $(drifted_files) Driver/Version.hs $(happy_files) \
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder $(inline_axiom_files) Modal/ModalSystems.hs $(hs_der_files)
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder# sources that have {-# OPTIONS -cpp #-}
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maedercpp_sources = hets.hs $(happy_files) \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder CASL/Logic_CASL.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder Common/Exception.hs \
ff2cced55f8db4fe7b72b46f7852018e1e3283e4Christian Maeder Common/ATerm/ConvInstances.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder Comorphisms/KnownProvers.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder Comorphisms/LogicGraph.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder Comorphisms/LogicList.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder Driver/WriteFn.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder GUI/GraphMenu.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder GUI/ShowGraph.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder GUI/Utils.hs \
8f31d51d47da96200437dd3af1d785cd88a46f71Thiemo Wiedemeyer GUI/ProverGUI.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder Isabelle/CreateTheories.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder OWL/Logic_OWL.hs \
a6c557605b327b033d881e74cc9f3cdbe3713b47Christian Maeder CMDL/InfoCommands.hs \
a6c557605b327b033d881e74cc9f3cdbe3713b47Christian Maeder CMDL/Interface.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder Propositional/Logic_Propositional.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder SoftFOL/Logic_SoftFOL.hs \
4e9e95ba35a68f3c767bc0b23ebf9e904e442517Christian Maeder VSE/Logic_VSE.hs \
2686d4438ffde954ffbb3a3f307642a893b33570Christian Maeder VSE/Prove.hs \
c911a0ec80ca4a178399c68f1e28be4e2bf42fceChristian Maeder Proofs/VSE.hs \
c911a0ec80ca4a178399c68f1e28be4e2bf42fceChristian Maeder Common/BinaryInstances.hs
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# further sources that should be excluded from haddock-0.8
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maedernondoc_sources = $(wildcard utils/DrIFT-src/*.hs) \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(wildcard utils/DrIFT-src/*.lhs) \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(wildcard utils/GenerateRules/*.hs) \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(wildcard utils/InlineAxioms/*.hs) \
8d401657e07a01e10400265f508f75353a9fba4cChristian Maeder $(wildcard utils/itcor/*.hs) \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(cpp_sources) $(pfe_sources) $(gen_inline_axiom_files) \
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(generated_rule_files) \
6bf24e5eb644064ad650eb3fd9774483fccbf601Christian Maeder $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hspp \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Modal/GeneratePatterns.inline.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Haskell/PreludeString.append.hs Haskell/ProgramaticaPrelude.hs \
f04e8f3ff56405901be968fd4c6e9769239f1a9bKlaus Luettich SoftFOL/MathServCommunication.hs \
e8db9a65830cf71504e33c6f441a67b4d184a3caChristian Maeder $(patsubst %.hs, %.der.hs, $(drifted_files))
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maederhspp_sources = $(patsubst %.hs, %.hspp, $(cpp_sources))
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder# this variable holds the modules that should be documented
6bf24e5eb644064ad650eb3fd9774483fccbf601Christian Maederdoc_sources = $(filter-out $(nondoc_sources), $(sources) $(hspp_sources))
dbe752ee940baae7f9f231f29c62284bb0f90a25Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder####################################################################
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder### targets
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich.PHONY : all hets-opt hets-optimized clean o_clean clean_pretty \
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder real_clean bin_clean package_clean distclean packages \
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder programatica_pkg aterm_pkg maintainer-clean annos \
f443a57f2a8e0ca3daa7431b0c89a18ba52c337aChristian Maeder check capa hacapa h2h h2hf showKP clean_genRules genRules \
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder count doc fromKif derivedSources release cgi ghci
857992065be4ed40a72c6296b6c0aec62ab4c5b9Christian Maeder
fdb2d618144159395f7bf8ce3327b3c112a17dd3Till Mossakowski.SECONDARY : %.hs %.d $(generated_rule_files) $(gen_inline_axiom_files)
7c99e334446bb97120e30e967baeeddfdd1278deKlaus Luettich
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder$(SETUP): utils/Setup.hs
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder $(HC) --make -O -o $@ $<
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder
10883d13973c46cac98964b66ace7a52b2d059abChristian Maederpackages: aterm_pkg programatica_pkg
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder
2d130d212db7208777ca896a7ecad619a8944971Christian Maederprogramatica_pkg:
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder
10883d13973c46cac98964b66ace7a52b2d059abChristian Maederaterm_sources = $(wildcard atermlib/src/ATerm/*.hs)
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder
10883d13973c46cac98964b66ace7a52b2d059abChristian Maederaterm_pkg: $(aterm_sources) $(SETUP)
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder @if $(HCPKG) field aterm version; then \
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder echo "of aterm package found"; else \
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder cp -f LICENSE.txt atermlib; \
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder cp -f LIZENZ.txt atermlib; \
bf25e8c286cda74ef89a9cbc3c2143557e0d49c3Christian Maeder cp -f utils/Setup.hs atermlib; \
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder cp -f $(SETUP) atermlib; \
05a62e84edac8c64de04f8349dee418598d216b9Christian Maeder (cd atermlib; $(SETUPPACKAGE)) fi
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maederhets-opt:
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder $(MAKE) distclean
33d042fe6a9eb27a4c48f840b80838f3e7d98e34Christian Maeder $(MAKE) derivedSources
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder $(MAKE) clean
fa21fba9ceb1ddf7b3efd54731a12ed8750191d8Christian Maeder $(MAKE) hets-optimized
fa21fba9ceb1ddf7b3efd54731a12ed8750191d8Christian Maeder
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maederhets-optimized: $(derived_sources)
0c355dd0b739631ee472f9a656e266be27fa4e64Christian Maeder $(HC) --make -O -o hets hets.hs $(HC_OPTS)
fa21fba9ceb1ddf7b3efd54731a12ed8750191d8Christian Maeder
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maedercgi:
c7ec85d1103173e089aa5048fd7afb2f9b505124Klaus Luettich $(MAKE) distclean
c7ec85d1103173e089aa5048fd7afb2f9b505124Klaus Luettich $(MAKE) derivedSources
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder $(MAKE) clean
c7ec85d1103173e089aa5048fd7afb2f9b505124Klaus Luettich $(MAKE) hets.cgi
c7ec85d1103173e089aa5048fd7afb2f9b505124Klaus Luettich
b905126bab9454b89041f92b3c50bb9efc85e427Klaus Luettichhets.cgi: $(sources) GUI/hets_cgi.hs
a883cd4d01fe39d23219cf5333425f195be24d8bChristian Maeder ghc --make GUI/hets_cgi.hs -o $@ $(HC_OPTS) -O
b905126bab9454b89041f92b3c50bb9efc85e427Klaus Luettich
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettichhets_maintainers.txt: $(sources)
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich @echo 'File : Maintainer' > $@
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich @echo -n Generating $@ " "
5818d884784339c1b8aa6c6d972bad4eafd36ccbKlaus Luettich @egrep -m 1 "Maintainer" $(sources) | \
5818d884784339c1b8aa6c6d972bad4eafd36ccbKlaus Luettich sed -e 's/: *Maintainer *: */ : /' >> $@
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich @echo " done"
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# count lines of code
b905126bab9454b89041f92b3c50bb9efc85e427Klaus Luettichcount: $(sources)
b905126bab9454b89041f92b3c50bb9efc85e427Klaus Luettich wc -l $(sources)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# Documentation via haddock
33d042fe6a9eb27a4c48f840b80838f3e7d98e34Christian Maederdoc: docs/index.html
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maederifneq ($(findstring 2.,$(HADDOCKVERSION)),)
f38b3687c5558128515e34fb85d8b466d22dc300Christian MaederHADDOCK_OPTS = $(addprefix --optghc=, $(HC_OPTS))
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maederdocs/index.html:
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maeder $(RM) -r docs
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maeder mkdir docs
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maeder $(HADDOCK) -o docs -h -v -s ../%F \
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maeder -t 'Hets - the Heterogeneous Tool Set' \
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maeder -p Hets-Haddock-Prologue.txt $(HADDOCK_OPTS) \
da8353f130412f98f3c942c2d02ff2bb26babd20Christian Maeder Syntax/ADoc.hs $(filter-out Test.hs, $(wildcard *.hs))
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maederelse
dbe752ee940baae7f9f231f29c62284bb0f90a25Christian Maeder# generate haddock documentation with links to sources
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder# the interface treatment is stolen from uni/mk/suffix.mk
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maederdocs/index.html: $(doc_sources)
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder $(RM) -r docs
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder mkdir docs
c1bf9cc3bc3729b0bf925be3be123cbb59bea2a6Christian Maeder cp -r -L ../uni/www docs/www || mkdir docs/www
c1bf9cc3bc3729b0bf925be3be123cbb59bea2a6Christian Maeder HINTERFACES0=`find -L docs/www -name '*.haddock' \
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder -printf "--read-interface=www/%P,%p "` ; \
96646aed2ae087b942ae23f15bbe729a8f7c43d3Christian Maeder HINTERFACES=`echo $$HINTERFACES0 | \
96646aed2ae087b942ae23f15bbe729a8f7c43d3Christian Maeder $(PERL) -pe 's+/[^/]*.haddock,+,+g'` ; \
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder $(HADDOCK) -o docs -h -v -s ../%F $$HINTERFACES \
3a7788e09dd23b364a46c9488cbd1522369113dbChristian Maeder -t 'Hets - the Heterogeneous Tool Set' \
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder -p Hets-Haddock-Prologue.txt $(doc_sources)
f38b3687c5558128515e34fb85d8b466d22dc300Christian Maederendif
ef67402074be14deb95e4ff564737d5593144130Klaus Luettich
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian MaederderivedSources: $(derived_sources) $(hspp_sources)
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder
aebb0b18fe5e6ba7dd7e4c66a16a905611ef7ba9Christian Maeder$(DRIFT): $(DRIFT_deps)
e05fd774e0181e93963d4302303b20698603a505Christian Maeder (cd utils/DrIFT-src; $(HC) --make DrIFT.hs -o ../DrIFT)
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder
aebb0b18fe5e6ba7dd7e4c66a16a905611ef7ba9Christian Maeder$(GENRULES): $(DRIFT) $(GENERATERULES_deps)
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder (cd utils/GenerateRules; \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(HC) --make -i../DrIFT-src -i../.. $(HC_WARN) \
e05fd774e0181e93963d4302303b20698603a505Christian Maeder GenerateRules.hs -o ../genRules)
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder
f2d9352f2999f82c36b4b65535d14a6a40ae5a82Christian Maeder# "-package hssource" for ghc-5.04.2
340706b6c0c6e3dbacdd7003e20e9cab7f9aa765Christian Maeder$(INLINEAXIOMS): $(INLINEAXIOMS_deps)
43bb71dfe7ec405f563864d57c1cacdaa8ce9a80Christian Maeder $(HC) --make utils/InlineAxioms/InlineAxioms.hs $(HC_WARN) $(HC_PROF) \
f2d9352f2999f82c36b4b65535d14a6a40ae5a82Christian Maeder -i../.. -o $(INLINEAXIOMS)
fdb2d618144159395f7bf8ce3327b3c112a17dd3Till Mossakowski
1dfba1f850f6a43094962b459998d1ea11472461Christian Maederutils/appendHaskellPreludeString: utils/appendHaskellPreludeString.hs
1dfba1f850f6a43094962b459998d1ea11472461Christian Maeder $(HC) --make -o $@ $<
1dfba1f850f6a43094962b459998d1ea11472461Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# release management
fa0f3519d71f719d88577b716b1579776b4a2535Christian MaederREV = trunk
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maederrelease:
99afa6000472f3d291fdf9193ea19d334a58658dChristian Maeder $(RM) -r Hets
fa0f3519d71f719d88577b716b1579776b4a2535Christian Maeder svn co https://svn-agbkb.informatik.uni-bremen.de/Hets/$(REV) Hets
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder $(RM) -r uni
c22d75ec3ea1306219d1c09a5b3e8ff04f753ad6Christian Maeder if [ -d ../uni ] ; then ln -s ../uni uni ; fi
9c3edf2b283c09d33b2820696886d1ed32fcadc8Christian Maeder $(RM) -r programatica
c22d75ec3ea1306219d1c09a5b3e8ff04f753ad6Christian Maeder if [ -d ../programatica ] ; then \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder mkdir programatica; \
68b77966b2cf7bf2e340bf0fb6b9efc3e6a00467Christian Maeder ln -s ../../programatica/tools programatica/tools ; fi
99afa6000472f3d291fdf9193ea19d334a58658dChristian Maeder (cd Hets; $(MAKE) derivedSources; $(MAKE) clean; \
5bb7eeaca10ea76595229375f907a5a388b7c882Christian Maeder cp Makefile Makefile.orig; \
5bb7eeaca10ea76595229375f907a5a388b7c882Christian Maeder cp ReleaseMakefile Makefile; \
5bb7eeaca10ea76595229375f907a5a388b7c882Christian Maeder ./clean.sh; \
c59d1c38ef94b4fb1c8d9fda9573bc1e1d2801e7Christian Maeder find . -name .svn -o -name \*.o -o -name \*.hi | xargs $(RM) -r; \
cd36bffee51c77cdadcb9f916b34fa512e311946Christian Maeder $(RM) clean.*; utils/replaceAllHeaders.sh)
99afa6000472f3d291fdf9193ea19d334a58658dChristian Maeder $(TAR) cvf Hets.tar Hets
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# Common/LaTeX_maps.hs generation
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettichutils/genItCorrections: $(GENITCORRECTIONS_deps)
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich $(HC) --make -o $@ $<
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettichpretty/LaTeX_maps.hs: utils/words.pl utils/genItCorrections \
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich pretty/words.input pretty/fonts.input pretty/width-table.tex.templ
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich @echo -n "Generating pretty/LaTeX_maps.hs ... "
36f63902db2b3463faa9f59912ad106e2d5aaa24Klaus Luettich @(cd pretty >/dev/null; $(PERL) ../utils/words.pl > words.pl.log)
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich @(cd pretty >/dev/null; ../utils/genItCorrections \
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich gen_it_characters gen_it_words >> LaTeX_maps.hs)
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich @echo "ready"
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich @echo "please copy the file manually to Common"
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder### clean up
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maederclean_genRules:
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder $(RM) $(generated_rule_files) $(gendrifted_files) $(hspp_sources) \
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maeder $(hs_clean_files)
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix Reckers
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettichclean: bin_clean o_clean clean_pretty
a80c28bb8b7a23ccdf7e08d0fe216fc19cc97273Klaus Luettich
82e29b77f0ef4cccd7ed734692c5e1e93dbbc645Christian Maeder### removes all *.o, *.hi and *.p_o files in all subdirectories
a80c28bb8b7a23ccdf7e08d0fe216fc19cc97273Klaus Luetticho_clean:
5f0e3e4cb7dd31033c9682cafa712d2a66b2f3bcChristian Maeder find . -name \*.o -o -name \*.hi -o -name \*.p_o \
5f0e3e4cb7dd31033c9682cafa712d2a66b2f3bcChristian Maeder -o -name \*.exe -o -name \*.exe.manifest | xargs $(RM)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
b9625461755578f3eed04676d42a63fd2caebd0cChristian Maeder### remove binaries
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maederbin_clean:
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(RM) hets
d0652648f9879c67a194f8b03baafe2700c68eb4Christian Maeder $(RM) hets.cgi
210aa1071465039588fa9e38c10e343631c34655Christian Maeder $(RM) $(SETUP)
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder $(RM) $(TESTTARGETS)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
b1f59a4ea7c96f4c03a4d7cfcb9c5e66871cfbbbChristian Maederclean_pretty:
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich $(RM) pretty/*.c.* pretty/*.h.* pretty/gen_it_* \
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich pretty/generated_words.tex
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder### additionally removes the library files
36f63902db2b3463faa9f59912ad106e2d5aaa24Klaus Luettichreal_clean: clean
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder### clean user packages
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maederpackage_clean:
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder $(HCPKG) unregister HAIFA --user || exit 0
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder $(HCPKG) unregister programatica --user || exit 0
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder $(HCPKG) unregister syb-generics --user || exit 0
10883d13973c46cac98964b66ace7a52b2d059abChristian Maeder $(HCPKG) unregister aterm --user || exit 0
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder### additionally removes generated files not in the CVS tree
68d10d143f29fcff3c637ba24f90e983995ceae6Christian Maederdistclean: clean clean_genRules
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder $(RM) $(derived_sources)
c5e3fc166373b0d90f6e36e8aa234396a1dcd879Christian Maeder $(RM) Modal/GeneratePatterns.inline.hs utils/appendHaskellPreludeString
340706b6c0c6e3dbacdd7003e20e9cab7f9aa765Christian Maeder $(RM) utils/DrIFT utils/genRules $(INLINEAXIOMS)
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich $(RM) utils/genItCorrections pretty/LaTeX_maps.hs pretty/words.pl.log
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
68d10d143f29fcff3c637ba24f90e983995ceae6Christian Maedermaintainer-clean: distclean package_clean
e1559d046eb2c6dde0e6e272b37b6756eac0e8adChristian Maeder $(RM) -r $(HOME)/.ghc/$(ARCH)-$(OSBYUNAME)-hets-packages
68d10d143f29fcff3c637ba24f90e983995ceae6Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder### interactive
2c619a4dfdc1df27573eba98e81ed1ace906941dChristian Maederghci: $(derived_sources)
5580ab3e64410186ccd36cde8a94282d8757ac0dChristian Maeder ghci $(HC_OPTS)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder### Kif parser
50515239e7e190f4a34ca581dd685d002148fbddChristian MaederfromKif: CASL/fromKif
50515239e7e190f4a34ca581dd685d002148fbddChristian Maeder
0b349288edfa50fdf38fda1a14e1562d03f92574Christian Maeder### Annos parser
0b349288edfa50fdf38fda1a14e1562d03f92574Christian Maederannos: Common/annos
0b349288edfa50fdf38fda1a14e1562d03f92574Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder### CASL parser
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maedercapa: CASL/capa
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder### HasCASL parser
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maederhacapa: HasCASL/hacapa
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
8b4c68db8b465107cabef8b9cd5b6bc216e1b156Till Mossakowski### Haskell analysis
8b4c68db8b465107cabef8b9cd5b6bc216e1b156Till Mossakowskihana: Haskell/hana
8b4c68db8b465107cabef8b9cd5b6bc216e1b156Till Mossakowski
bcaf979d9babe6346aa343687aa7d596e2894cccPaolo Torrini### Haskell to Isabelle-HOLCF translation
df29370ae8d8b41587957f6bcdcb43a3f1927e47Christian Maederh2hf: Haskell/h2hf
bcaf979d9babe6346aa343687aa7d596e2894cccPaolo Torrini
5ce19352a9cc47d982819cc889a71cd0a61ac171Christian MaederHaskell/h2hf: Haskell/h2hf.hs Haskell/*.hs Isabelle/*.hs Common/*.hs \
5ce19352a9cc47d982819cc889a71cd0a61ac171Christian Maeder Common/Lib/*.hs Comorphisms/*.hs
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maeder $(HC) -O --make -o $@ $< $(HC_OPTS)
bcaf979d9babe6346aa343687aa7d596e2894cccPaolo Torrini
23ab8855c58adfbd03a0730584b917b24c603901Christian Maeder### HasCASL to Haskell translation
df29370ae8d8b41587957f6bcdcb43a3f1927e47Christian Maederh2h: Haskell/h2h
23ab8855c58adfbd03a0730584b917b24c603901Christian Maeder
e50e41135ece589f7202bd4ef8d6b97531c2a56eKlaus Luettich### test program to check the known provers
47b0e9f3cb008cb7997f4e3bae26e4d62dcc887aChristian MaedershowKP: Comorphisms/test/showKP
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder### run tests in other directories
431d34c7007a787331c4e5ec997badb0f8190fc7Christian Maedercheck: $(TESTTARGETS)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder for i in $(TESTDIRS); do $(MAKE) -C $$i check; done
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
99afa6000472f3d291fdf9193ea19d334a58658dChristian Maeder## Preparing the version of Hets
43b4c41fbb07705c9df321221ab9cb9832460407Christian MaederDriver/Version.hs: Driver/Version.in version_nr
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder $(RM) $@
d5d349836d8b1fa93ea49a59d977b106c6e9233bKlaus Luettich LANG=C $(PERL) utils/build_version.pl version_nr \
d5d349836d8b1fa93ea49a59d977b106c6e9233bKlaus Luettich < Driver/Version.in > $@
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder chmod 444 $@
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## two hardcoded dependencies for a correct generation of Version.hs
43b4c41fbb07705c9df321221ab9cb9832460407Christian MaederDriver/Options.hs Driver/WriteFn.hs Driver/ReadFn.hs: Driver/Version.hs
43b4c41fbb07705c9df321221ab9cb9832460407Christian Maederhets.hs: Driver/Version.hs
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus Luettich
9096f6c6aaded6cd8288656ceccd4c7b3bd0747eChristian MaederATC/DevGraph.hs: Static/DevGraph.hs
9096f6c6aaded6cd8288656ceccd4c7b3bd0747eChristian Maeder
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus Luettich## two dependencies for avoidence of circular prerequisites
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus LuettichCASL_DEPENDENT_BINARIES= hets CASL/capa CASL/fromKif \
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus Luettich Common/annos Common/test_parser Comorphisms/test/showKP \
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus Luettich CspCASL/print_csp HasCASL/hacapa Haskell/h2h Haskell/h2hf \
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus Luettich Haskell/hana Haskell/wrap Isabelle/isa Syntax/hetpa
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus Luettich$(CASL_DEPENDENT_BINARIES): $(sources) $(derived_sources)
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder#? CASL_DL/Logic_CASL_DL.hs: CASL_DL/PredefinedSign.hs
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder## suffix rules
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder.SUFFIXES:
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder## rule for GHC
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder%: %.hs packages
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder $(HC) --make -o $@ $< $(HC_OPTS)
c72c1e75a969ff4c336e77481c2a8e42603f13eeChristian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder## rule for HAPPY
fdef3358918491badb0e29e42b5d3b5a01950716Christian Maeder%.hs: %.y
6ff7a91875597d6e4dfaa68c79187d01473e8341Christian Maeder $(HAPPY) -o $@.tmp $<
6ff7a91875597d6e4dfaa68c79187d01473e8341Christian Maeder echo "{-# OPTIONS -w #-}" > $@
6ff7a91875597d6e4dfaa68c79187d01473e8341Christian Maeder cat $@.tmp >> $@
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder $(RM) $@.tmp
fdef3358918491badb0e29e42b5d3b5a01950716Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder## rule for DrIFT
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder%.hs: %.der.hs $(DRIFT)
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder $(RM) $@
7767474aba4fa2dc51a6c68017d3bcef3b773001Christian Maeder ($(DRIFT_ENV); export DERIVEPATH; $(DRIFT) $< > $@)
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder chmod 444 $@
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder## rule for inlineAxioms
340706b6c0c6e3dbacdd7003e20e9cab7f9aa765Christian Maeder%.hs: %.inline.hs $(INLINEAXIOMS)
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder $(RM) $@
bf76f4fcf07abaebea587df8135de8356c26a363Till Mossakowski $(INLINEAXIOMS) $< > $@
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder chmod 444 $@
fdb2d618144159395f7bf8ce3327b3c112a17dd3Till Mossakowski
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder## rule for cpp and haddock
6e049108aa87dc46bcff96fae50a4625df1d9648Klaus Luettich%.hspp: %.hs
473bc1f3f3443f18e0ee83e4642fab42183470f2Christian Maeder $(HC) -E -cpp -D__HADDOCK__ \
473bc1f3f3443f18e0ee83e4642fab42183470f2Christian Maeder -DUNI_PACKAGE -DCASLEXTENSIONS -DPROGRAMATICA -optP -P $<
6e049108aa87dc46bcff96fae50a4625df1d9648Klaus Luettich
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## compiling rules for object and interface files
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder%.o %.hi: %.hs
f4505a64a089693012a3f5c3b1f12a82cd7a2a5aKlaus Luettich $(HC) -c $< $(HC_OPTS)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder%.o %.hi: %.lhs
f4505a64a089693012a3f5c3b1f12a82cd7a2a5aKlaus Luettich $(HC) -c $< $(HC_OPTS)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## compiling rules for dependencies
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder%.d : %.hs
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(HC) -M $< $(HC_OPTS) -optdep-f -optdep$@
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder%.d : %.lhs
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(HC) -M $< $(HC_OPTS) -optdep-f -optdep$@
1a6464613c59e35072b90ca296ae402cbe956144Christian Maeder
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder## Rule to generate hs files from glade files. Needed for GTK
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder%.hs: %.glade utils/appendHaskellPreludeString \
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder GUI/Glade/Template.append.hs
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder b=`basename $< .glade`; \
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder cat GUI/Glade/Template.append.hs | sed "s/\%s/$$b/" | \
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder utils/appendHaskellPreludeString $< > $@
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maeder
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich## generate the inline file for the predefined CASL_DL sign
0be0db405c49906bd7057255069bf6df53395ac9Klaus LuettichCASL_DL/PredefinedSign.inline.hs: \
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich CASL_DL/PredefinedSign.inline.hs.in utils/appendHaskellPreludeString \
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich CASL_DL/PredDatatypes.het
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich $(RM) $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich utils/appendHaskellPreludeString CASL_DL/PredDatatypes.het \
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich < CASL_DL/PredefinedSign.inline.hs.in > $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich echo " )" >> $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich chmod 444 $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich
5818d884784339c1b8aa6c6d972bad4eafd36ccbKlaus Luettich# Warning: Don't change the order of the depencies!!
0be0db405c49906bd7057255069bf6df53395ac9Klaus LuettichCASL_DL/PredDatatypes.het: utils/transformLibAsBasicSpec.pl \
2e62113845a35e07cb46db05714627c95450f267Klaus Luettich CASL_DL/Datatypes.het
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich $(RM) $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich $(PERL) $+ > $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich chmod 444 $@
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich
438f9bd974c8e668203e636b0f2bc80c589af043Klaus Luettich## rule for Modal/ModalSystems.hs needed for ModalLogic Translation
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder# uses intransparently utils/outlineAxioms
9e748851c150e1022fb952bab3315e869aaf0214Christian MaederModal/ModalSystems.hs: Modal/GeneratePatterns.inline.hs.in \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder utils/genTransMFormFunc.pl $(INLINEAXIOMS)
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder $(RM) $@
438f9bd974c8e668203e636b0f2bc80c589af043Klaus Luettich $(PERL) utils/genTransMFormFunc.pl $< $@
88318aafc287e92931dceffbb943d58a9310001dChristian Maeder chmod 444 $@
feac53e31a8351e3e3c6621f6a14b5714008bfc7Heng Jiang
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# directory for installers
f78ce817f35574674d54e30ad1861a9b4ced20caChristian MaederINSTALLER_DIR = ../installers
f78ce817f35574674d54e30ad1861a9b4ced20caChristian Maeder
f78ce817f35574674d54e30ad1861a9b4ced20caChristian Maederifeq ($(strip $(HETS_VERSION)),)
f78ce817f35574674d54e30ad1861a9b4ced20caChristian MaederHETS_VERSION := `cat version_nr`
fd2c22348e5a69231f92fb44e35a9970b47c4e93Christian Maeder# or `date +%F`
f78ce817f35574674d54e30ad1861a9b4ced20caChristian Maederendif
f78ce817f35574674d54e30ad1861a9b4ced20caChristian Maeder
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# prepare installer creation
89c9d707aa817684b88036a2dad66c3437840677Heng Jianginitialize_installer:
f78ce817f35574674d54e30ad1861a9b4ced20caChristian Maeder mkdir -p $(INSTALLER_DIR)
f78ce817f35574674d54e30ad1861a9b4ced20caChristian Maeder sed "s/^\(HETS_VERSION =\).*/\1$(HETS_VERSION)/" Makefile.installer \
f78ce817f35574674d54e30ad1861a9b4ced20caChristian Maeder > $(INSTALLER_DIR)/Makefile
f041c9a6bda23de33a38490e35b831ae18d96b45Christian Maeder @echo Please do
f041c9a6bda23de33a38490e35b831ae18d96b45Christian Maeder @echo " -> cd $(INSTALLER_DIR)"
f041c9a6bda23de33a38490e35b831ae18d96b45Christian Maeder @echo " -> make"
bea81dabd203833818cb4a5f3758977c695728cdHeng Jiang @echo and wait until it is finished
bf7b17b0e19362e9228672782218678cab275d1eDominik Luecke
456238178f89e5a3de2988ee6c8af924297d52d9Christian Maeder# check out java parts for OWL
c802a1041ed9251f8ad79139454267e802900e2aChristian Maederowl_java:
c802a1041ed9251f8ad79139454267e802900e2aChristian Maeder svn co \
c802a1041ed9251f8ad79139454267e802900e2aChristian Maeder https://owlapi.svn.sourceforge.net/svnroot/owlapi/owl1_1/trunk \
c802a1041ed9251f8ad79139454267e802900e2aChristian Maeder OWL/java/OwlApi
c802a1041ed9251f8ad79139454267e802900e2aChristian Maeder
c802a1041ed9251f8ad79139454267e802900e2aChristian Maederinitialize_java: owl_java
53bbc1c9a4e986d1ee9c081d6f0ac7b9546f212bDominik Luecke ant -q init
bf7b17b0e19362e9228672782218678cab275d1eDominik Luecke
bf7b17b0e19362e9228672782218678cab275d1eDominik Lueckejava-libs:
bf7b17b0e19362e9228672782218678cab275d1eDominik Luecke ant -q java-libs
bf7b17b0e19362e9228672782218678cab275d1eDominik Luecke
bf7b17b0e19362e9228672782218678cab275d1eDominik Lueckejava-files:
bf7b17b0e19362e9228672782218678cab275d1eDominik Luecke ant -q java-files
bf7b17b0e19362e9228672782218678cab275d1eDominik Luecke
75b0c0c2cbfb7edd3f4c0555227aabbe6c1aa195Christian Maederjava-clean:
bf7b17b0e19362e9228672782218678cab275d1eDominik Luecke ant -q java-clean