Makefile revision 68aab98a58d1460c77a1573a86c32a891756a420
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)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder####################################################################
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## Some varibles, which control the compilation
a53841f6d6e86ac751c12a33dc8aadf53f59d977Klaus LuettichCLEAN_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 \
a737caf82de97c1907027c03e4b4509eb492b4b8Christian Maeder CspCASL ATC ToHaskell Proofs Comorphisms Isabelle Driver \
01e383014b555bbcf639c0ca60c5810b3eff83c0Christian Maeder# the 'replacing spaces' example was taken from the (GNU) Make info manual
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder## set ghc imports properly for your system
ce8b15da31cd181b7e90593cbbca98f47eda29d6Till MossakowskiGHC_IMPORTS = `$(HC) --print-libdir`/imports
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder# 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))
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder# override on commandline for other architectures
2e2094a642e3775b0d76b890556407941d3a53b6Christian Maeder /home/www/agbkb/forschung/formal_methods/CoFI/hets/`utils/sysname.sh`
c0c2380bced8159ff0297ece14eba948bd236471Christian MaederGENERATERULES_deps = utils/GenerateRules/*hs $(DRIFT_deps) Common/Utils.hs
8410667510a76409aca9bb24ff0eda0420088274Christian MaederINLINEAXIOMS_deps = utils/InlineAxioms/InlineAxioms.hs \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder Common/Lib/Pretty.hs Common/Keywords.hs Common/Lib/Set.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Common/Lib/Map.hs Common/Lib/Rel.hs Common/Lib/State.hs Common/Id.hs \
8410667510a76409aca9bb24ff0eda0420088274Christian Maeder Common/AS_Annotation.hs CASL/AS_Basic_CASL.hs CASL/ShowMixfix.hs \
404166b9366552e9ec5abb87a37c76ec8a815fb7Klaus Luettich CASL/Utils.hs Common/Lexer.hs Common/Token.hs Common/Anno_Parser.hs \
b1f59a4ea7c96f4c03a4d7cfcb9c5e66871cfbbbChristian Maeder Common/GlobalAnnotations.hs Common/PrettyPrint.hs \
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich Common/Print_AS_Annotation.hs Common/PPUtils.hs CASL/LiteralFuns.hs \
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich CASL/Print_AS_Basic.hs Common/AnnoState.hs CASL/Formula.hs \
4d56f2fa72e4aec20eb827c11ed49c8cbb7014bdChristian Maeder CASL/OpItem.hs CASL/SortItem.hs CASL/Inject.hs Common/Result.hs \
4cb215739e9ab13447fa21162482ebe485b47455Christian Maeder Common/ConvertLiteral.hs Common/Earley.hs CASL/MixfixParser.hs \
8ef75f1cc0437656bf622cec5ac9e8ea221da8f2Christian Maeder CASL/Parse_AS_Basic.hs CASL/Sign.hs CASL/Overload.hs \
404166b9366552e9ec5abb87a37c76ec8a815fb7Klaus Luettich CASL/StaticAna.hs Modal/AS_Modal.hs Modal/Parse_AS.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Modal/ModalSign.hs Modal/Print_AS.hs Modal/StatAna.hs
8d97ef4f234681b11bb5924bd4d03adef858d2d2Christian MaederGENRULECALL = $(GENRULES) -r ShATermConvertible -i Common.ATerm.Lib
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder# remove -fno-warn-orphans for older ghcs
7cc09dd93962a2155c34d209d1d4cd7d7b838264Christian Maeder $(HC_WARN) -fglasgow-exts -fno-monomorphism-restriction \
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder -fallow-overlapping-instances -fallow-undecidable-instances
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder# -ddump-minimal-imports
c3053d57f642ca507cdf79512e604437c4546cb9Christian Maeder# flags also come in via ../uni/uni-package.conf
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder# but added it here in case of compilation without uni
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian MaederHC_INCLUDE = $(addprefix -i, $(INCLUDE_PATH))
c2fcc35abb03cf0b4ca4b050efeb10827f38c322Christian Maederlogics = CASL HasCASL Isabelle Modal CoCASL COL CspCASL CASL_DL SPASS OWL_DL
356fa49fe3e6a8398f92d13e9f920d0f093697ecChristian MaederUNI_PACKAGE_CONF = $(wildcard ../uni/uni-package.conf)
356fa49fe3e6a8398f92d13e9f920d0f093697ecChristian MaederHC_PACKAGE = -package-conf $(UNI_PACKAGE_CONF) -package uni-davinci \
0206ab93ef846e4e0885996d052b9b73b9dc66b0Christian Maeder# some modules from uni for haddock
f13d1e86e58da53680e78043e8df182eed867efbChristian Maeder# if uni/server is included also HaXml sources are needed
c2a4d8ae266aa37cc922eba97077520229a19902Christian Maederuni_dirs = ../uni/davinci ../uni/graphs ../uni/events \
757e6c79ec40491d45dc72c82b5eb59a386634b0Jian Chun Wanguni_sources = $(wildcard $(addsuffix /haddock/*.hs, $(uni_dirs))) \
c55a0f77be7e88d3620b419ec8961f4379a586e3Klaus Luettich### list of directories to run checks in
363939beade943a02b31004cea09dec34fa8a6d9Christian MaederPFE_TOOLDIR = $(wildcard ../programatica/tools)
8cacad2a09782249243b80985f28e9387019fe40Christian MaederPFE_DIRS = base/AST base/TI base/parse2 base/parse2/Lexer base/parse2/Parser \
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder base/parse2/LexerGen base/parse2/LexerSpec base/tests/HbcLibraries \
a7c27282e71cf4505026645f96d4f5cb8a284e32Christian Maeder base/pretty base/syntax base/lib base/lib/Monads base/Modules base/defs \
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder base/transforms base/transforms/Deriving property \
8a28707e9155465c6f2236a06eac6580a65c7025Christian Maeder property/syntax property/AST property/transforms \
df35538fec1d9135602308d577255c0d466b6365Christian Maeder property/TI property/defs property/parse2 property/parse2/Parser
431d34c7007a787331c4e5ec997badb0f8190fc7Christian MaederPFE_PATHS = $(addprefix $(PFE_TOOLDIR)/, $(PFE_DIRS))
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maederpfe_sources = $(wildcard $(addsuffix /*hs, $(PFE_PATHS)))
9e748851c150e1022fb952bab3315e869aaf0214Christian MaederPFE_FLAGS = -package data -package text $(PFE_PATH) -DPROGRAMATICA
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maederhappy_files += $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hs
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder patch -sNlp0 -d $(PFE_TOOLDIR) -i `pwd`/$< || exit 0
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder$(LEX_DIR)/HsLex.hs: $(LEX_DIR)Gen/HsLexerGen
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder echo "{-# OPTIONS -w #-}" > $@
9e748851c150e1022fb952bab3315e869aaf0214Christian Maeder$(LEX_DIR)Gen/HsLexerGen: $(LEX_DIR)Gen/*.hs $(LEX_DIR)Spec/*.hs \
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maeder -i$(LEX_DIR) -i$(LEX_DIR)Gen -i$(LEX_DIR)Spec \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maederderived_sources += Haskell/PreludeString.hs $(LEX_DIR)/HsLex.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederAPPENDPRELUDESTRING = utils/appendHaskellPreludeString \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder## rule for appendHaskellPreludeString
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederHaskell/PreludeString.hs: Haskell/PreludeString.append.hs \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian MaederAst_Haskell_files = HsDeclStruct HsExpStruct HsFieldsStruct \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder HsGuardsStruct HsKindStruct HsPatStruct HsTypeStruct HsAssocStruct \
ad4889ebb40efae8595b0969dd6ba1162d52bac3Christian MaederOther_PFE_files = property/AST/HsPropStruct base/defs/PNT \
4017ebc0f692820736d796af3110c3b3018c108aChristian Maeder base/defs/UniqueNames base/Modules/TypedIds base/Modules/Ents \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder base/parse2/SourceNames base/syntax/SyntaxRec \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder $(addprefix $(PFE_TOOLDIR)/base/AST/, $(Ast_Haskell_files)) \
4017ebc0f692820736d796af3110c3b3018c108aChristian Maeder $(addprefix $(PFE_TOOLDIR)/, $(Other_PFE_files)))
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder## rule for ATC generation
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederHaskell/ATC_Haskell.der.hs: $(Haskell_files) $(GENRULES)
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder $(GENRULECALL) -i Haskell.BaseATC -o $@ $(Haskell_files)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder### Profiling (only for debugging)
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder### Attention every module must be compiled with profiling or the linker
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder### cannot link the various .o files properly. So after switching on
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder### Profiling, do an 'gmake real_clean; gmake'
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder### Comment in the following line for switching on profiling.
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder#HC_PROF = -prof -auto-all
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederHC_OPTS = $(HC_FLAGS) $(HC_INCLUDE) $(HC_PACKAGE) $(PFE_FLAGS) $(HC_PROF) \
4017ebc0f692820736d796af3110c3b3018c108aChristian Maeder####################################################################
b568982efd0997d877286faa592d81b03c8c67b8Christian Maeder## sources for hets
0be0db405c49906bd7057255069bf6df53395ac9Klaus Luettichnon_sources = Common/LaTeX_maps.svmono.hs CspCASL/Main.hs \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder Common/CaslLanguage.hs ./Test.hs Static/LogicStructured.hs
f2f9df2e17e70674f0bf426ed1763c973ee4cde0Christian Maedersources = hets.hs $(filter-out $(non_sources), \
d946c1bfdd7d58aa7c023efe864d5999eb44a61bChristian Maeder $(wildcard $(addsuffix /[A-Z]*hs, $(SOURCE_PATHS))))
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maederdrifted_files = Syntax/AS_Architecture.hs Syntax/AS_Library.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Common/AS_Annotation.hs CASL/AS_Basic_CASL.hs Syntax/AS_Structured.hs \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder Modal/AS_Modal.hs CoCASL/AS_CoCASL.hs COL/AS_COL.hs CASL_DL/AS_CASL_DL.hs\
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder Syntax/AS_Structured.der.hs Syntax/AS_Architecture.der.hs \
ca074a78b8dcccbb8c419586787882f98d0c6163Christian Maeder Common/GlobalAnnotations.hs Syntax/AS_Library.der.hs \
f1541d4a151dbd08002dbd14e7eb1d5dde253689Christian Maederatc_der_files = $(foreach file, $(atc_files), \
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maeder ATC/$(basename $(basename $(notdir $(file)))).der.hs)
89f7631cbfbd1bb99fc152b434bd362a7799d295Christian MaederATC/AS_Annotation.der.hs: Common/AS_Annotation.der.hs $(GENRULES)
f1541d4a151dbd08002dbd14e7eb1d5dde253689Christian MaederATC/AS_Structured.der.hs: Syntax/AS_Structured.der.hs $(GENRULES)
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -i ATC.Grothendieck -o $@ $<
f4505a64a089693012a3f5c3b1f12a82cd7a2a5aKlaus LuettichATC/AS_Architecture.der.hs: Syntax/AS_Architecture.der.hs $(GENRULES)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(GENRULECALL) -i ATC.AS_Structured -o $@ $<
f4505a64a089693012a3f5c3b1f12a82cd7a2a5aKlaus LuettichATC/AS_Library.der.hs: Syntax/AS_Library.der.hs $(GENRULES)
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder $(GENRULECALL) -i ATC.AS_Architecture -o $@ $<
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaederATC/GlobalAnnotations.der.hs: Common/GlobalAnnotations.hs $(GENRULES)
2c619a4dfdc1df27573eba98e81ed1ace906941dChristian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $<
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaederATC/Prover.der.hs: Logic/Prover.hs $(GENRULES)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(GENRULECALL) -x ProverTemplate -i ATC.AS_Annotation -o $@ $<
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaederCASL_files = CASL/Sublogic.hs CASL/Morphism.hs CASL/Sign.hs \
7c5c311d67e187280877c45bd89dcba9038bc0a3Christian MaederHasCASL_files = HasCASL/As.hs HasCASL/Le.hs HasCASL/Sublogic.hs
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederModal_files = Modal/AS_Modal.hs Modal/ModalSign.hs
83394c6b6e6de128e71b67c9251ed7a84485d082Christian MaederCoCASL_files = CoCASL/AS_CoCASL.hs CoCASL/CoCASLSign.hs CoCASL/Sublogic.hs
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian MaederCspCASL_files = CspCASL/AS_CSP_CASL.hs CspCASL/SignCSP.hs
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian MaederCASL_DL_files = CASL_DL/AS_CASL_DL.hs CASL_DL/Sign.hs
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix Reckersatc_logic_files = $(foreach logic, $(logics), $(logic)/ATC_$(logic).der.hs)
fb328c4f646dd3dd78a9391c5cb58450a3dd0aa9Klaus Luettichgenerated_rule_files = $(atc_der_files) $(atc_logic_files)
cf04ba46b9eb495d334466e24e082e391055ca7bDominik Lueckegendrifted_files = $(patsubst %.der.hs, %.hs, $(generated_rule_files))
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix Reckersinline_axiom_files = Comorphisms/CASL2PCFOL.hs Comorphisms/PCFOL2CFOL.hs \
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maeder Comorphisms/Modal2CASL.hs Comorphisms/CASL2TopSort.hs \
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maedergen_inline_axiom_files = $(patsubst %.hs,%.inline.hs, $(inline_axiom_files))
9e748851c150e1022fb952bab3315e869aaf0214Christian Maederderived_sources += $(drifted_files) Driver/Version.hs $(happy_files) \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(inline_axiom_files) Modal/ModalSystems.hs
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder# sources that have {-# OPTIONS -cpp #-}
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder Common/Lib/Set.hs Common/Lib/Map.hs ATC/Set.hs\
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder Isabelle/Logic_Isabelle.hs Isabelle/CreateTheories.hs \
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder SPASS/Logic_SPASS.hs GUI/Utils.hs Driver/WriteFn.hs \
383aa66e5142365fe9b1f88b18c1da5b27cc8c04Christian Maeder Comorphisms/LogicList.hs Comorphisms/LogicGraph.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder# unused, remove when header files are gone
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maedergenrule_header_files = $(wildcard ATC/*.header.hs)
819e29dba060687cf391e444e0f6ff88c1908cc3Christian Maedernondoc_sources = $(wildcard utils/DrIFT-src/*.hs) \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder $(cpp_sources) $(pfe_sources) $(gen_inline_axiom_files) \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder $(genrule_header_files) $(generated_rule_files) \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hspp \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder Haskell/PreludeString.append.hs Haskell/ProgramaticaPrelude.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder hxt/HXT.hs hxt/Net.hs $(patsubst %.hs, %.der.hs, $(drifted_files))
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maederhspp_sources = $(patsubst %.hs, %.hspp, $(cpp_sources))
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder# this variable holds the modules that should be documented
ac34194a668399bb8ef238da77c3a09e93fb253bChristian Maederdoc_sources = $(filter-out $(nondoc_sources), $(sources) $(hspp_sources))
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maedertax_sources = Taxonomy/AbstractGraphView.hs Taxonomy/MMiSSOntology.hs \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder Taxonomy/MMiSSOntologyGraph.hs Taxonomy/OntoParser.hs
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maedertax_objects = $(patsubst %.hs, %.o, $(tax_sources))
6fe9628743562678acf97d6730ebcfee5e9e50c2Christian Maeder####################################################################
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder.PHONY : all hets-opt hets-optimized clean d_clean real_clean bin_clean \
3b06e23643a9f65390cb8c1caabe83fa7e87a708Till Mossakowski lib_clean distclean check capa hacapa h2h clean_genRules genRules \
b1f59a4ea7c96f4c03a4d7cfcb9c5e66871cfbbbChristian Maeder taxonomy count doc apache_doc post_doc4apache \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder derivedSources install_hets install release patch
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder.SECONDARY : %.hs %.d $(generated_rule_files) $(gen_inline_axiom_files)
63e50b4c36074d5fb9de872c4007b688b4bce534Christian Maeder ghc --make -package WASH GUI/hets_cgi.hs -o $@ $(HC_INCLUDE) \
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maedertaxonomy: Taxonomy/taxonomyTool.hs $(tax_sources)
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder $(HC) --make -o Taxonomy/taxonomyTool $< -ifgl $(HC_OPTS)
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder###############################
6a79849bed67264c396dddb3e9c184bdfc1a1bc9Christian Maeder### TAGS files for (x)emacs
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder# load them with "M-x" "visit-tags-table" from
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder# use "M-." to search for a tag
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian 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 \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(sources); mv TAGS $@; mv tags hetcats.tags
e8db9a65830cf71504e33c6f441a67b4d184a3caChristian Maeder @echo 'File : Maintainer' > $@
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder 'foreach my $$f (@ARGV) { open I, "<$$f"; \
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder print "$$f :"; while (<I>) \
6bf24e5eb644064ad650eb3fd9774483fccbf601Christian Maeder { if(m,^\s*Maintainer\s*:\s*(.*)$$,o) { \
dbe752ee940baae7f9f231f29c62284bb0f90a25Christian Maeder print " $$1" ; last} }; print "\n"; close I; }' \
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder @echo " done"
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder###############################
53818ced114da21321063fff307aa41c1ab31dd3Achim Mahnke### count lines of code
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder###############################
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich### Documentation via haddock
f443a57f2a8e0ca3daa7431b0c89a18ba52c337aChristian Maeder# generate haddock documentation with links to sources
363939beade943a02b31004cea09dec34fa8a6d9Christian Maeder# the interface treatment is stolen from uni/mk/suffix.mk
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder HINTERFACES0=`find docs/www -name '*.haddock' \
f041c9a6bda23de33a38490e35b831ae18d96b45Christian Maeder $(HADDOCK) -o docs -h -v -s ../%F $$HINTERFACES \
dcbd32289a7bdf1e6edd06c6ab0698c6a9dbf37aChristian Maeder -t 'Hets - the Heterogeneous Tool Set' \
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder -p Hets-Haddock-Prologue.txt $(doc_sources)
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder# sources are not copied here
215d42ce4d6397a453d5887292bc786e8fa9c1a2Christian Maeder $(PERL) utils/post_process_docs.pl a-docs \
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder $(PERL) utils/post_process_docs.pl a-docs \
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder###############################
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder### release management
215d42ce4d6397a453d5887292bc786e8fa9c1a2Christian MaederderivedSources: $(derived_sources) $(hspp_sources)
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder (cd utils/DrIFT-src; $(HC) --make DrIFT.hs -o ../DrIFT && \
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder $(HC) --make -i../DrIFT-src -i../.. $(HC_WARN) \
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder GenerateRules.hs -o ../genRules && strip ../genRules)
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder# "hssource" for ghc-5.04.2
27785f379d6810811b4e6d23feab18845fde9a98Christian Maeder $(HC) --make utils/InlineAxioms/InlineAxioms.hs $(HC_WARN) $(HC_PROF) \
4017ebc0f692820736d796af3110c3b3018c108aChristian Maeder -package hssource -i../.. -o $(INLINEAXIOMS)
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder cvs -d :pserver:cvsread@cvs-agbkb.informatik.uni-bremen.de:/repository\
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder if [ -d ../uni ] ; then ln -s ../uni uni ; fi
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder if [ -d ../programatica ] ; then \
b49276c9f50038e0bd499ad49f7bd6444566a834Christian Maeder ln -s ../../programatica/tools programatica/tools ; fi
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder (cd HetCATS; $(MAKE) derivedSources; $(MAKE) clean; \
c7ec85d1103173e089aa5048fd7afb2f9b505124Klaus Luettich find . -name CVS -o -name \*.o -o -name \*.hi | xargs $(RM) -r; \
a883cd4d01fe39d23219cf5333425f195be24d8bChristian Maeder cp -p hets $(INSTALLDIR)/versions/hets-`cat version_nr`
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich ln -s versions/hets-`cat version_nr` hets; $(RM) version_nr)
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich#############################
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich### ATC DrIFT-rule generation
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus LuettichCASL/ATC_CASL.der.hs: $(CASL_files) $(GENRULES)
c4ef79587a902327f36277c45a8d91d1e67bd6d5Klaus Luettich $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(CASL_files)
b905126bab9454b89041f92b3c50bb9efc85e427Klaus LuettichHasCASL/ATC_HasCASL.der.hs: $(HasCASL_files) $(GENRULES)
b905126bab9454b89041f92b3c50bb9efc85e427Klaus Luettich $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(HasCASL_files)
b905126bab9454b89041f92b3c50bb9efc85e427Klaus LuettichIsabelle/ATC_Isabelle.der.hs: $(Isabelle_files) $(GENRULES)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(Isabelle_files)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaederModal/ATC_Modal.der.hs: $(Modal_files) $(GENRULES)
dbe752ee940baae7f9f231f29c62284bb0f90a25Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(Modal_files)
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian MaederCASL_DL/ATC_CASL_DL.der.hs: $(CASL_DL_files) $(GENRULES)
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CASL_DL_files)
68aab98a58d1460c77a1573a86c32a891756a420Christian MaederCoCASL/ATC_CoCASL.der.hs: $(CoCASL_files) $(GENRULES)
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CoCASL_files)
96646aed2ae087b942ae23f15bbe729a8f7c43d3Christian MaederCOL/ATC_COL.der.hs: $(COL_files) $(GENRULES)
96646aed2ae087b942ae23f15bbe729a8f7c43d3Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(COL_files)
3a7788e09dd23b364a46c9488cbd1522369113dbChristian MaederCspCASL/ATC_CspCASL.der.hs: $(CspCASL_files) $(GENRULES)
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CspCASL_files)
dbe752ee940baae7f9f231f29c62284bb0f90a25Christian MaederSPASS/ATC_SPASS.der.hs: $(SPASS_files) $(GENRULES)
ef67402074be14deb95e4ff564737d5593144130Klaus Luettich $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(SPASS_files)
c9e197862d9d8ef2585270dd08f5194b3aed4a9dKlaus LuettichOWL_DL/ATC_OWL_DL.der.hs: $(OWL_DL_files) $(GENRULES)
e7e1ab2ac3f1fded8611bb92ae00e8f3b8c693fbKlaus Luettich $(GENRULECALL) -i ATC.AS_Annotation -i OWL_DL.ReadWrite \
d784803f9c752667b4fcf7393d698002bedf3f89Klaus Luettich $(RM) $(generated_rule_files) $(gendrifted_files) $(hspp_sources) \
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder###############
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder### removes *.hi and *.o in all include directories
1f8a7f8343f7df719768d2b1d7e3077ee291a1caChristian Maeder### remove binaries
9e748851c150e1022fb952bab3315e869aaf0214Christian Maeder### additionally removes the library files
c22d75ec3ea1306219d1c09a5b3e8ff04f753ad6Christian Maeder### additionally removes generated files not in the CVS tree
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder $(RM) utils/DrIFT utils/genRules $(INLINEAXIOMS)
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder####################################################################
5bb7eeaca10ea76595229375f907a5a388b7c882Christian Maeder### test targets
5bb7eeaca10ea76595229375f907a5a388b7c882Christian Maeder####################################################################
63f0e65a37b95621334db9ee4ba0cd9d826f5c0fChristian Maeder### a parser to test annotation parser and Id parsers
ac0bbbcb2774629bb87986e69cf53d3402c5f575Christian MaederCommon/test_parser: Common/test_parser.hs Common/AS_Annotation.der.hs
ddc9315cc0b1f5dd3d8f99a77f1c75064db33b48Christian Maeder### interactive
8410667510a76409aca9bb24ff0eda0420088274Christian Maeder### christian's target
8410667510a76409aca9bb24ff0eda0420088274Christian Maeder### CASL parser
e62d49c0dc2893da75faad896bd135e2e9a7087bKlaus Luettich### HasCASL parser
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus LuettichHasCASL/hacapa: HasCASL/hacapa.hs Common/*.hs HasCASL/*.hs
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich### Haskell analysis
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus LuettichHaskell/hana: Haskell/hana.hs Haskell/HatAna.hs Haskell/PreludeString.hs
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich### Haskell to Isabelle-HOLCF translation
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus LuettichToHaskell/h2hf: ToHaskell/h2hf.hs ToHaskell/*.hs Haskell/*.hs HasCASL/*.hs Isabelle/*.hs Common/*.hs
ac43fa22d2d3f91a17674ac164cba3cf39a17795Klaus Luettich### HasCASL to Haskell translation
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix ReckersToHaskell/h2h: ToHaskell/h2h.hs ToHaskell/*.hs Haskell/*.hs HasCASL/*.hs
61fa0ac06ede811c7aad54ec4c4202346727368eChristian Maeder### HetCASL parser
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder### HetCASL parser
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder### ATC test system
3b06e23643a9f65390cb8c1caabe83fa7e87a708Till Mossakowskiatctest2: ATC/ATCTest2.hs Common/SimpPretty.hs Common/ATerm/*.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maederatermlibtest: Common/ATerm/ATermLibTest.hs Common/SimpPretty.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder $(HC) --make -o $@ $< $(HC_OPTS) $(EXTRA_HC_OPTS)
8b0f493ae42bad8b94918cc0957f1af57096cda4Felix Reckershatermdiff: Common/ATerm/ATermDiffMain.hs Common/SimpPretty.hs \
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder $(HC) --make -o $@ $< $(HC_OPTS) $(EXTRA_HC_OPTS)
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian Maeder### OWL_DL test target
d23b0cc79c0d204e6ec758dff8d0ba71c9f693f7Christian MaederOWL_DL/readAStest: OWL_DL/ToHaskellAS.hs Common/ATerm/*.hs \
abf2487c3aece95c371ea89ac64319370dcb6483Klaus Luettich $(HC) --make -o $@ $< $(HC_OPTS) $(EXTRA_HC_OPTS)
abf2487c3aece95c371ea89ac64319370dcb6483Klaus Luettich### HetCASL with dev graph
6dc9bc98d0854fe2e3dd3bfc4275096a0c28ee1cChristian Maeder### run tests in other directories
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder for i in $(TESTDIRS); do $(MAKE) -C $$i check; done
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder####################################################################
3e61f574717499939bd8e0ff538ea9e7b72d4e2dKlaus Luettich## Preparing the version of HetCATS
a80c28bb8b7a23ccdf7e08d0fe216fc19cc97273Klaus LuettichDriver/Version.hs: Driver/Version.in version_nr
a80c28bb8b7a23ccdf7e08d0fe216fc19cc97273Klaus Luettich $(PERL) utils/build_version.pl version_nr < Driver/Version.in > $@
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## two hardcoded dependencies for a correct generation of Version.hs
b9625461755578f3eed04676d42a63fd2caebd0cChristian MaederDriver/Options.hs Driver/WriteFn.hs Driver/ReadFn.hs: Driver/Version.hs
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder####################################################################
d0652648f9879c67a194f8b03baafe2700c68eb4Christian Maeder## rules for DrIFT
83394c6b6e6de128e71b67c9251ed7a84485d082Christian Maeder echo "{-# OPTIONS -w #-}" > $@
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder ($(DRIFT_ENV); export DERIVEPATH; $(DRIFT) $(DRIFT_OPTS) $< > $@)
1aee4aaddde105264c1faf394d88e302c05094ffChristian Maeder## rules for inlineAxioms
e7757995211bd395dc79d26fe017d99375f7d2a6Christian Maeder## rule for cpp and haddock
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## compiling rules for object and interface files
2c619a4dfdc1df27573eba98e81ed1ace906941dChristian Maeder## compiling rules for dependencies
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder## rule for Modal/ModalSystems.hs needed for ModalLogic Translation
5191fa24c532d1f67e7a642e9aece65efb8a0975Christian Maeder# uses intransparently utils/outlineAxioms