Makefile revision 03f242dcc84c327431783cf8694f8682f927ac85
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder# Author: (c) Klaus L�ttich, Christian Maeder, Uni Bremen 2002-2005
43b4c41fbb07705c9df321221ab9cb9832460407Christian Maeder# This Makefile will compile the new hets system and provides also
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder# targets for test programs during implementation phases.
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder# !!! Note: This makefile is written for GNU make !!!
43b4c41fbb07705c9df321221ab9cb9832460407Christian Maeder# (gmake on solaris)
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maeder####################################################################
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maeder## Some varibles, which control the compilation
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaederCLEAN_PATH = . hxt/Data hxt/Text/XML/HXT/DOM hxt/Text/XML/HXT/Parser \
a53841f6d6e86ac751c12a33dc8aadf53f59d977Klaus Luettich utils utils/DrIFT-src utils/GenerateRules utils/InlineAxioms Common \
a53841f6d6e86ac751c12a33dc8aadf53f59d977Klaus Luettich Common/Lib Common/ATerm Logic CASL CASL/CCC CASL/CompositionTable \
a53841f6d6e86ac751c12a33dc8aadf53f59d977Klaus Luettich Syntax Static GUI HasCASL Haskell Modal CoCASL COL \
a53841f6d6e86ac751c12a33dc8aadf53f59d977Klaus Luettich CspCASL ATC ToHaskell Proofs Comorphisms Isabelle Driver \
96646aed2ae087b942ae23f15bbe729a8f7c43d3Christian Maeder# the 'replacing spaces' example was taken from the (GNU) Make info manual
5e5d3e82af3bc2834f8718a52d9f45da80220273Dominik Luecke## set ghc imports properly for your system
5db0bfca8a3cd5d5f487ad70524bd6ec49fb439fChristian MaederGHC_IMPORTS = `$(HC) --print-libdir`/imports
ce8b15da31cd181b7e90593cbbca98f47eda29d6Till Mossakowski# import directories for ghc-5.04.2
e7757995211bd395dc79d26fe017d99375f7d2a6Christian MaederGHC5 = $(GHC_IMPORTS)/base:$(GHC_IMPORTS)/haskell98
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder DERIVEPATH=.:ghc:$(GHC_IMPORTS):$(GHC5):$(subst $(space),:,$(PFE_PATHS))
a1ed34933c266ce85066acb0d7b20c90cb8eb213Christian Maeder# override on commandline for other architectures
8410667510a76409aca9bb24ff0eda0420088274Christian Maeder /home/www/agbkb/forschung/formal_methods/CoFI/hets/`utils/sysname.sh`
8410667510a76409aca9bb24ff0eda0420088274Christian MaederGENERATERULES_deps = utils/GenerateRules/*hs $(DRIFT_deps) Common/Utils.hs
404166b9366552e9ec5abb87a37c76ec8a815fb7Klaus LuettichINLINEAXIOMS_deps = utils/InlineAxioms/InlineAxioms.hs \
b1f59a4ea7c96f4c03a4d7cfcb9c5e66871cfbbbChristian Maeder Common/Lib/Pretty.hs Common/Keywords.hs Common/Lib/Set.hs \
ad270004874ce1d0697fb30d7309f180553bb315Christian Maeder Common/Lib/Map.hs Common/Lib/Rel.hs Common/Lib/State.hs Common/Id.hs \
4d56f2fa72e4aec20eb827c11ed49c8cbb7014bdChristian Maeder Common/AS_Annotation.hs CASL/AS_Basic_CASL.hs CASL/ShowMixfix.hs \
4cb215739e9ab13447fa21162482ebe485b47455Christian Maeder CASL/Utils.hs Common/Lexer.hs Common/Token.hs Common/Anno_Parser.hs \
8ef75f1cc0437656bf622cec5ac9e8ea221da8f2Christian Maeder Common/GlobalAnnotations.hs Common/PrettyPrint.hs \
404166b9366552e9ec5abb87a37c76ec8a815fb7Klaus Luettich Common/Print_AS_Annotation.hs Common/PPUtils.hs CASL/LiteralFuns.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder CASL/Print_AS_Basic.hs Common/AnnoState.hs CASL/Formula.hs \
55adfe57a4de1f36adc3e3bfc16f342e44a7d444Christian Maeder CASL/OpItem.hs CASL/SortItem.hs CASL/Inject.hs Common/Result.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder Common/ConvertLiteral.hs Common/Earley.hs CASL/MixfixParser.hs \
8d97ef4f234681b11bb5924bd4d03adef858d2d2Christian Maeder CASL/Parse_AS_Basic.hs CASL/Sign.hs CASL/Overload.hs \
f4a2a20e49f41b2afa657e5e64d9e349c7faa091Christian Maeder CASL/StaticAna.hs Modal/AS_Modal.hs Modal/Parse_AS.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Modal/ModalSign.hs Modal/Print_AS.hs Modal/StatAna.hs
1aee4aaddde105264c1faf394d88e302c05094ffChristian MaederGENRULECALL = $(GENRULES) -r ShATermConvertible -i Common.ATerm.Lib
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder# remove -fno-warn-orphans for older ghcs
f4a2a20e49f41b2afa657e5e64d9e349c7faa091Christian Maeder $(HC_WARN) -fglasgow-exts -fno-monomorphism-restriction \
f4a2a20e49f41b2afa657e5e64d9e349c7faa091Christian Maeder -fallow-overlapping-instances -fallow-undecidable-instances
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder# -ddump-minimal-imports
d0279930f87bf39843e0bd2992a4789322662144Christian Maeder# flags also come in via ../uni/uni-package.conf
c2fcc35abb03cf0b4ca4b050efeb10827f38c322Christian Maeder# but added it here in case of compilation without uni
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian MaederHC_INCLUDE = $(addprefix -i, $(INCLUDE_PATH))
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian Maederlogics = CASL HasCASL Isabelle Modal CoCASL COL CspCASL CASL_DL SPASS OWL_DL
8b767d09a78927b111f5596fdff9ca7d2c1a439fChristian MaederUNI_PACKAGE_CONF = $(wildcard ../uni/uni-package.conf)
f04e8f3ff56405901be968fd4c6e9769239f1a9bKlaus LuettichHC_PACKAGE = -package-conf $(UNI_PACKAGE_CONF) -package uni-davinci \
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder# some modules from uni for haddock
a7c27282e71cf4505026645f96d4f5cb8a284e32Christian Maeder# if uni/server is included also HaXml sources are needed
363939beade943a02b31004cea09dec34fa8a6d9Christian Maederuni_dirs = ../uni/davinci ../uni/graphs ../uni/events \
8a28707e9155465c6f2236a06eac6580a65c7025Christian Maeder ../uni/reactor ../uni/util ../uni/posixutil
797ccd67cb8ae127be097cd43448801b673e3b69Christian Maederuni_sources = $(wildcard $(addsuffix /haddock/*.hs, $(uni_dirs))) \
498aa48bdb931ab50990d3b74318a5db2312186cChristian Maeder### list of directories to run checks in
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian MaederPFE_TOOLDIR = $(wildcard ../programatica/tools)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederPFE_DIRS = base/AST base/TI base/parse2 base/parse2/Lexer base/parse2/Parser \
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder base/parse2/LexerGen base/parse2/LexerSpec base/tests/HbcLibraries \
c0c2380bced8159ff0297ece14eba948bd236471Christian 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
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederPFE_PATHS = $(addprefix $(PFE_TOOLDIR)/, $(PFE_DIRS))
9e748851c150e1022fb952bab3315e869aaf0214Christian Maederpfe_sources = $(wildcard $(addsuffix /*hs, $(PFE_PATHS)))
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederPFE_FLAGS = -package data -package text $(PFE_PATH) -DPROGRAMATICA
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maederhappy_files += $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hs
a5e5b8c3e5c11177e5034ef2423813a5d28979edChristian Maeder patch -sNlp0 -d $(PFE_TOOLDIR) -i `pwd`/$< || exit 0
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder$(LEX_DIR)/HsLex.hs: $(LEX_DIR)Gen/HsLexerGen
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder echo "{-# OPTIONS -w #-}" > $@
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder$(LEX_DIR)Gen/HsLexerGen: $(LEX_DIR)Gen/*.hs $(LEX_DIR)Spec/*.hs \
2d130d212db7208777ca896a7ecad619a8944971Christian Maeder -i$(LEX_DIR) -i$(LEX_DIR)Gen -i$(LEX_DIR)Spec \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maederderived_sources += Haskell/PreludeString.hs $(LEX_DIR)/HsLex.hs \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederAPPENDPRELUDESTRING = utils/appendHaskellPreludeString \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder## rule for appendHaskellPreludeString
88318aafc287e92931dceffbb943d58a9310001dChristian MaederHaskell/PreludeString.hs: Haskell/PreludeString.append.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederAst_Haskell_files = HsDeclStruct HsExpStruct HsFieldsStruct \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder HsGuardsStruct HsKindStruct HsPatStruct HsTypeStruct HsAssocStruct \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian MaederOther_PFE_files = property/AST/HsPropStruct base/defs/PNT \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder base/defs/UniqueNames base/Modules/TypedIds base/Modules/Ents \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder base/parse2/SourceNames base/syntax/SyntaxRec \
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettich $(addprefix $(PFE_TOOLDIR)/base/AST/, $(Ast_Haskell_files)) \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder $(addprefix $(PFE_TOOLDIR)/, $(Other_PFE_files)))
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder## rule for ATC generation
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederHaskell/ATC_Haskell.der.hs: $(Haskell_files) $(GENRULES)
f2f9df2e17e70674f0bf426ed1763c973ee4cde0Christian Maeder $(GENRULECALL) -i Haskell.BaseATC -o $@ $(Haskell_files)
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder### Profiling (only for debugging)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder### Attention every module must be compiled with profiling or the linker
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder### cannot link the various .o files properly. So after switching on
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder### Profiling, do an 'gmake real_clean; gmake'
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder### Comment in the following line for switching on profiling.
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder#HC_PROF = -prof -auto-all
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederHC_OPTS = $(HC_FLAGS) $(HC_INCLUDE) $(HC_PACKAGE) $(PFE_FLAGS) $(HC_PROF) \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder####################################################################
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder## sources for hets
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maedernon_sources = Common/LaTeX_maps.svmono.hs CspCASL/Main.hs \
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder Common/CaslLanguage.hs ./Test.hs Static/LogicStructured.hs
06ba24fa9695b698437546276f37aa5e1924ad1bChristian Maedersources = hets.hs $(filter-out $(non_sources), \
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder $(wildcard $(addsuffix /[A-Z]*hs, $(SOURCE_PATHS))))
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maederdrifted_files = Syntax/AS_Architecture.hs Syntax/AS_Library.hs \
c9a7e6af169a2adfb92f42331cd578065ed83a2bChristian Maeder Common/AS_Annotation.hs CASL/AS_Basic_CASL.hs Syntax/AS_Structured.hs \
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder Modal/AS_Modal.hs CoCASL/AS_CoCASL.hs COL/AS_COL.hs CASL_DL/AS_CASL_DL.hs\
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder Syntax/AS_Structured.der.hs Syntax/AS_Architecture.der.hs \
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder Common/GlobalAnnotations.hs Syntax/AS_Library.der.hs \
42b12fba6830ada5057949f825fc27edf5574e5fChristian Maederatc_der_files = $(foreach file, $(atc_files), \
42b12fba6830ada5057949f825fc27edf5574e5fChristian Maeder ATC/$(basename $(basename $(notdir $(file)))).der.hs)
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederATC/AS_Annotation.der.hs: Common/AS_Annotation.der.hs $(GENRULES)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederATC/AS_Structured.der.hs: Syntax/AS_Structured.der.hs $(GENRULES)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -i ATC.Grothendieck -o $@ $<
93f5b72fdb9ee734caa750b43dd79bbb590dcd73Christian MaederATC/AS_Architecture.der.hs: Syntax/AS_Architecture.der.hs $(GENRULES)
93f5b72fdb9ee734caa750b43dd79bbb590dcd73Christian Maeder $(GENRULECALL) -i ATC.AS_Structured -o $@ $<
328a85c807f2a95c3f147d10b05927eaf862ebebChristian MaederATC/AS_Library.der.hs: Syntax/AS_Library.der.hs $(GENRULES)
317bcd45211dd8f28a8ebb3dee7a67197391fc0dDominik LueckeATC/GlobalAnnotations.der.hs: Common/GlobalAnnotations.hs $(GENRULES)
5b818f10e11fc79def1fdd5c8a080d64a6438d87Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $<
819e29dba060687cf391e444e0f6ff88c1908cc3Christian MaederATC/Prover.der.hs: Logic/Prover.hs $(GENRULES)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(GENRULECALL) -x ProverTemplate -i ATC.AS_Annotation -o $@ $<
a14767aeac3e78ed100f5b75e210ba563ee10dbaChristian MaederCASL_files = CASL/Sublogic.hs CASL/Morphism.hs CASL/Sign.hs \
9e748851c150e1022fb952bab3315e869aaf0214Christian MaederHasCASL_files = HasCASL/As.hs HasCASL/Le.hs HasCASL/Sublogic.hs
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian MaederModal_files = Modal/AS_Modal.hs Modal/ModalSign.hs
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian MaederCoCASL_files = CoCASL/AS_CoCASL.hs CoCASL/CoCASLSign.hs CoCASL/Sublogic.hs
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian MaederCspCASL_files = CspCASL/AS_CSP_CASL.hs CspCASL/SignCSP.hs
a14767aeac3e78ed100f5b75e210ba563ee10dbaChristian MaederCASL_DL_files = CASL_DL/AS_CASL_DL.hs CASL_DL/Sign.hs
697e63e30aa3c309a1ef1f9357745111f8dfc5a9Christian Maederatc_logic_files = $(foreach logic, $(logics), $(logic)/ATC_$(logic).der.hs)
697e63e30aa3c309a1ef1f9357745111f8dfc5a9Christian Maedergenerated_rule_files = $(atc_der_files) $(atc_logic_files)
f9e0b18852b238ddb649d341194e05d7200d1bbeChristian Maedergendrifted_files = $(patsubst %.der.hs, %.hs, $(generated_rule_files))
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maederinline_axiom_files = Comorphisms/CASL2PCFOL.hs Comorphisms/PCFOL2CFOL.hs \
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maeder Comorphisms/Modal2CASL.hs Comorphisms/CASL2TopSort.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maedergen_inline_axiom_files = $(patsubst %.hs,%.inline.hs, $(inline_axiom_files))
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maederderived_sources += $(drifted_files) Driver/Version.hs $(happy_files) \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder $(inline_axiom_files) Modal/ModalSystems.hs
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder# sources that have {-# OPTIONS -cpp #-}
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder Common/Lib/Set.hs Common/Lib/Map.hs ATC/Set.hs\
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder Isabelle/Logic_Isabelle.hs Isabelle/CreateTheories.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder SPASS/Logic_SPASS.hs GUI/Utils.hs Driver/WriteFn.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder Comorphisms/LogicList.hs Comorphisms/LogicGraph.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder# unused, remove when header files are gone
1842453990fed8a1bd7a5ac792d7982c1d2bfcd5Christian Maedergenrule_header_files = $(wildcard ATC/*.header.hs)
1842453990fed8a1bd7a5ac792d7982c1d2bfcd5Christian Maedernondoc_sources = $(wildcard utils/DrIFT-src/*.hs) \
4561227a776bdf0ab679b19fb92f1eaaed8786f7Christian Maeder $(cpp_sources) $(pfe_sources) $(gen_inline_axiom_files) \
01e278bdd7dce13b9303ed3d79683d83c89d09f9Liam O'Reilly $(genrule_header_files) $(generated_rule_files) \
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hspp \
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder Haskell/PreludeString.append.hs Haskell/ProgramaticaPrelude.hs \
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder hxt/HXT.hs hxt/Net.hs $(patsubst %.hs, %.der.hs, $(drifted_files))
05a206508bc898f87fe6ab6e069814df3c29d303Dominik Lueckehspp_sources = $(patsubst %.hs, %.hspp, $(cpp_sources))
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder# this variable holds the modules that should be documented
3b06e23643a9f65390cb8c1caabe83fa7e87a708Till Mossakowskidoc_sources = $(filter-out $(nondoc_sources), $(sources) $(hspp_sources))
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maedertax_sources = Taxonomy/AbstractGraphView.hs Taxonomy/MMiSSOntology.hs \
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maeder Taxonomy/MMiSSOntologyGraph.hs Taxonomy/OntoParser.hs
8c812cd83569e973f10cf69a342424ceabc07af9Christian Maedertax_objects = $(patsubst %.hs, %.o, $(tax_sources))
1b3a2f98d1cd01fc9e0591f69507e20526727559Dominik Luecke####################################################################
e39a1626bee36d6ad13a2c0014a80ef179a65bcbChristian Maeder.PHONY : all hets-opt hets-optimized clean d_clean real_clean bin_clean \
f8e1a1eca871a26a535a4ee7d51902ba94b1db1eChristian Maeder lib_clean distclean check capa hacapa h2h clean_genRules genRules \
abf2487c3aece95c371ea89ac64319370dcb6483Klaus Luettich taxonomy count doc apache_doc post_doc4apache \
c70ef4c3b3a62764f715510c9fd67dde3acfe454Christian Maeder derivedSources install_hets install release patch
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder.SECONDARY : %.hs %.d $(generated_rule_files) $(gen_inline_axiom_files)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder ghc --make -package WASH GUI/hets_cgi.hs -o $@ $(HC_INCLUDE) \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maedertaxonomy: Taxonomy/taxonomyTool.hs $(tax_sources)
6bf24e5eb644064ad650eb3fd9774483fccbf601Christian Maeder $(HC) --make -o Taxonomy/taxonomyTool $< -ifgl $(HC_OPTS)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder###############################
f04e8f3ff56405901be968fd4c6e9769239f1a9bKlaus Luettich### TAGS files for (x)emacs
e8db9a65830cf71504e33c6f441a67b4d184a3caChristian Maeder# load them with "M-x" "visit-tags-table" from
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder# use "M-." to search for a tag
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder# !!Beware this is somewhat instable, because it uses an absolute path!!
6bf24e5eb644064ad650eb3fd9774483fccbf601Christian Maeder /home/ger/linux/ghc-5.04.2/bin/i386-unknown-linux/hasktags \
dbe752ee940baae7f9f231f29c62284bb0f90a25Christian Maeder $(sources); mv TAGS $@; mv tags hetcats.tags
53818ced114da21321063fff307aa41c1ab31dd3Achim Mahnke @echo 'File : Maintainer' > $@
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder 'foreach my $$f (@ARGV) { open I, "<$$f"; \
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder print "$$f :"; while (<I>) \
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder { if(m,^\s*Maintainer\s*:\s*(.*)$$,o) { \
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich print " $$1" ; last} }; print "\n"; close I; }' \
368c26b8ad68a4b2c42963626087667000c2eebfChristian Maeder @echo " done"
368c26b8ad68a4b2c42963626087667000c2eebfChristian Maeder###############################
f443a57f2a8e0ca3daa7431b0c89a18ba52c337aChristian Maeder### count lines of code
857992065be4ed40a72c6296b6c0aec62ab4c5b9Christian Maeder###############################
fdb2d618144159395f7bf8ce3327b3c112a17dd3Till Mossakowski### Documentation via haddock
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder# generate haddock documentation with links to sources
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder# the interface treatment is stolen from uni/mk/suffix.mk
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder cp -r ../uni/www docs/www || mkdir docs/www
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder HINTERFACES0=`find docs/www -name '*.haddock' \
6d549a835ffd3a11c3ed74e0f8fda30fda6a9528Christian Maeder $(HADDOCK) -o docs -h -v -s ../%F $$HINTERFACES \
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder -t 'Hets - the Heterogeneous Tool Set' \
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder -p Hets-Haddock-Prologue.txt $(doc_sources)
c4451dc7da4a15726ba96179aecf046a5df5cae1Christian Maeder# sources are not copied here
0c355dd0b739631ee472f9a656e266be27fa4e64Christian Maeder $(PERL) utils/post_process_docs.pl a-docs \
fa21fba9ceb1ddf7b3efd54731a12ed8750191d8Christian Maeder $(PERL) utils/post_process_docs.pl a-docs \
b49276c9f50038e0bd499ad49f7bd6444566a834Christian Maeder###############################
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder### release management
c7ec85d1103173e089aa5048fd7afb2f9b505124Klaus LuettichderivedSources: $(derived_sources) $(hspp_sources)
c7ec85d1103173e089aa5048fd7afb2f9b505124Klaus Luettich (cd utils/DrIFT-src; $(HC) --make DrIFT.hs -o ../DrIFT && \
b905126bab9454b89041f92b3c50bb9efc85e427Klaus Luettich $(HC) --make -i../DrIFT-src -i../.. $(HC_WARN) \
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich GenerateRules.hs -o ../genRules && strip ../genRules)
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich# "hssource" for ghc-5.04.2
5818d884784339c1b8aa6c6d972bad4eafd36ccbKlaus Luettich $(HC) --make utils/InlineAxioms/InlineAxioms.hs $(HC_WARN) $(HC_PROF) \
b905126bab9454b89041f92b3c50bb9efc85e427Klaus Luettich cvs -d :pserver:cvsread@cvs-agbkb.informatik.uni-bremen.de:/repository\
33d042fe6a9eb27a4c48f840b80838f3e7d98e34Christian Maeder if [ -d ../uni ] ; then ln -s ../uni uni ; fi
dbe752ee940baae7f9f231f29c62284bb0f90a25Christian Maeder if [ -d ../programatica ] ; then \
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder ln -s ../../programatica/tools programatica/tools ; fi
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder (cd HetCATS; $(MAKE) derivedSources; $(MAKE) clean; \
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder find . -name CVS -o -name \*.o -o -name \*.hi | xargs $(RM) -r; \
ef67402074be14deb95e4ff564737d5593144130Klaus Luettich cp -p hets $(INSTALLDIR)/versions/hets-`cat version_nr`
462d9dc583444aab82732e14a75610684d2dc7e9Christian Maeder ln -s versions/hets-`cat version_nr` hets; $(RM) version_nr)
1323eba62fc519b068f5aaec4f9d2be05ffabea9Klaus Luettich#############################
a80c28bb8b7a23ccdf7e08d0fe216fc19cc97273Klaus Luettich### ATC DrIFT-rule generation
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian MaederCASL/ATC_CASL.der.hs: $(CASL_files) $(GENRULES)
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(CASL_files)
5d39c60274aaa76506292d2d9e885fccd27e1eabChristian MaederHasCASL/ATC_HasCASL.der.hs: $(HasCASL_files) $(GENRULES)
5d39c60274aaa76506292d2d9e885fccd27e1eabChristian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(HasCASL_files)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaederIsabelle/ATC_Isabelle.der.hs: $(Isabelle_files) $(GENRULES)
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(Isabelle_files)
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian MaederModal/ATC_Modal.der.hs: $(Modal_files) $(GENRULES)
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(Modal_files)
aebb0b18fe5e6ba7dd7e4c66a16a905611ef7ba9Christian MaederCASL_DL/ATC_CASL_DL.der.hs: $(CASL_DL_files) $(GENRULES)
404166b9366552e9ec5abb87a37c76ec8a815fb7Klaus Luettich $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CASL_DL_files)
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian MaederCoCASL/ATC_CoCASL.der.hs: $(CoCASL_files) $(GENRULES)
aebb0b18fe5e6ba7dd7e4c66a16a905611ef7ba9Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CoCASL_files)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederCOL/ATC_COL.der.hs: $(COL_files) $(GENRULES)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(COL_files)
f2d9352f2999f82c36b4b65535d14a6a40ae5a82Christian MaederCspCASL/ATC_CspCASL.der.hs: $(CspCASL_files) $(GENRULES)
340706b6c0c6e3dbacdd7003e20e9cab7f9aa765Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CspCASL_files)
f2d9352f2999f82c36b4b65535d14a6a40ae5a82Christian MaederSPASS/ATC_SPASS.der.hs: $(SPASS_files) $(GENRULES)
340706b6c0c6e3dbacdd7003e20e9cab7f9aa765Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(SPASS_files)
1dfba1f850f6a43094962b459998d1ea11472461Christian MaederOWL_DL/ATC_OWL_DL.der.hs: $(OWL_DL_files) $(GENRULES)
1dfba1f850f6a43094962b459998d1ea11472461Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -i OWL_DL.ReadWrite \
99afa6000472f3d291fdf9193ea19d334a58658dChristian Maeder $(RM) $(generated_rule_files) $(gendrifted_files) $(hspp_sources) \
c22d75ec3ea1306219d1c09a5b3e8ff04f753ad6Christian Maeder###############
99afa6000472f3d291fdf9193ea19d334a58658dChristian Maeder### removes *.hi and *.o in all include directories
cd36bffee51c77cdadcb9f916b34fa512e311946Christian Maeder### remove binaries
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich### additionally removes the library files
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich### additionally removes generated files not in the CVS tree
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich $(RM) utils/DrIFT utils/genRules $(INLINEAXIOMS)
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich####################################################################
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich### test targets
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich####################################################################
ac43fa22d2d3f91a17674ac164cba3cf39a17795Klaus Luettich### a parser to test annotation parser and Id parsers
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix ReckersCommon/test_parser: Common/test_parser.hs Common/AS_Annotation.der.hs
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder### interactive
b891e9ad7dd358a7df24b59bf00d51515078497cChristian Maeder### christian's target
b891e9ad7dd358a7df24b59bf00d51515078497cChristian Maeder### CASL parser
1c9a63e4f7c6879f51fe0f32154a9116f2c126dbChristian MaederCASL/capa: CASL/capa.hs Common/*.hs CASL/*.hs
b891e9ad7dd358a7df24b59bf00d51515078497cChristian Maeder### HasCASL parser
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederHasCASL/hacapa: HasCASL/hacapa.hs Common/*.hs HasCASL/*.hs
3b06e23643a9f65390cb8c1caabe83fa7e87a708Till Mossakowski### Haskell analysis
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederHaskell/hana: Haskell/hana.hs Haskell/HatAna.hs Haskell/PreludeString.hs
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder### Haskell to Isabelle-HOLCF translation
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederToHaskell/h2hf: ToHaskell/h2hf.hs ToHaskell/*.hs Haskell/*.hs HasCASL/*.hs Isabelle/*.hs Common/*.hs
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder### HasCASL to Haskell translation
f04e8f3ff56405901be968fd4c6e9769239f1a9bKlaus LuettichToHaskell/h2h: ToHaskell/h2h.hs ToHaskell/*.hs Haskell/*.hs HasCASL/*.hs
b891e9ad7dd358a7df24b59bf00d51515078497cChristian Maeder### HetCASL parser
e39a1626bee36d6ad13a2c0014a80ef179a65bcbChristian Maeder### HetCASL parser
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder### ATC test system
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maederatctest2: ATC/ATCTest2.hs Common/SimpPretty.hs Common/ATerm/*.hs \
a80c28bb8b7a23ccdf7e08d0fe216fc19cc97273Klaus Luettich### ATerm.Lib test system
82e29b77f0ef4cccd7ed734692c5e1e93dbbc645Christian Maederatermlibtest: Common/ATerm/ATermLibTest.hs Common/SimpPretty.hs \
13731dfbb4b6a31b35dd210e832e920065b6ac45Christian Maeder $(HC) --make -o $@ $< $(HC_OPTS) $(EXTRA_HC_OPTS)
b9625461755578f3eed04676d42a63fd2caebd0cChristian Maederhatermdiff: Common/ATerm/ATermDiffMain.hs Common/SimpPretty.hs \
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(HC) --make -o $@ $< $(HC_OPTS) $(EXTRA_HC_OPTS)
210aa1071465039588fa9e38c10e343631c34655Christian Maeder### OWL_DL test target
363939beade943a02b31004cea09dec34fa8a6d9Christian MaederOWL_DL/readAStest: OWL_DL/ToHaskellAS.hs Common/ATerm/*.hs \
b1f59a4ea7c96f4c03a4d7cfcb9c5e66871cfbbbChristian Maeder $(HC) --make -o $@ $< $(HC_OPTS) $(EXTRA_HC_OPTS)
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich### HetCASL with dev graph
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaedercheckMakeBinaries: test_parser hetpa hetana Test.o \
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder### run tests in other directories
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder for i in $(TESTDIRS); do $(MAKE) -C $$i check; done
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder####################################################################
68d10d143f29fcff3c637ba24f90e983995ceae6Christian Maeder## Preparing the version of HetCATS
e7757995211bd395dc79d26fe017d99375f7d2a6Christian MaederDriver/Version.hs: Driver/Version.in version_nr
340706b6c0c6e3dbacdd7003e20e9cab7f9aa765Christian Maeder $(PERL) utils/build_version.pl version_nr < Driver/Version.in > $@
68d10d143f29fcff3c637ba24f90e983995ceae6Christian Maeder## two hardcoded dependencies for a correct generation of Version.hs
e1559d046eb2c6dde0e6e272b37b6756eac0e8adChristian MaederDriver/Options.hs Driver/WriteFn.hs Driver/ReadFn.hs: Driver/Version.hs
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder####################################################################
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## rules for DrIFT
50515239e7e190f4a34ca581dd685d002148fbddChristian Maeder echo "{-# OPTIONS -w #-}" > $@
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder ($(DRIFT_ENV); export DERIVEPATH; $(DRIFT) $(DRIFT_OPTS) $< > $@)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## rules for inlineAxioms
bcaf979d9babe6346aa343687aa7d596e2894cccPaolo Torrini## rule for cpp and haddock
5ce19352a9cc47d982819cc889a71cd0a61ac171Christian Maeder## compiling rules for object and interface files
47b0e9f3cb008cb7997f4e3bae26e4d62dcc887aChristian Maeder## compiling rules for dependencies
99afa6000472f3d291fdf9193ea19d334a58658dChristian Maeder## rule for Modal/ModalSystems.hs needed for ModalLogic Translation
43b4c41fbb07705c9df321221ab9cb9832460407Christian Maeder# uses intransparently utils/outlineAxioms