Makefile revision 48c12c2751928dcfe1d6a49e6c3ebb6dcaa4867f
fd9abdda70912b99b24e3bf1a38f26fde908a74cnd# Author: (c) Klaus L�ttich, Christian Maeder, Uni Bremen 2002-2005
fd9abdda70912b99b24e3bf1a38f26fde908a74cnd# Year: 2004
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# This Makefile will compile the new hets system and provides also
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# targets for test programs during implementation phases.
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# !!! Note: This makefile is written for GNU make !!!
96ad5d81ee4a2cc66a4ae19893efc8aa6d06fae7jailletc# (gmake on solaris)
2e545ce2450a9953665f701bb05350f0d3f26275nd####################################################################
d29d9ab4614ff992b0e8de6e2b88d52b6f1f153erbowen## Some varibles, which control the compilation
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiHAIFA_PATHS = Network Network/Server Org Org/W3 Org/W3/N2001 \
af33a4994ae2ff15bc67d19ff1a7feb906745bf8rbowen Org/Xmlsoap Org/Xmlsoap/Schemas Org/Xmlsoap/Schemas/Soap \
3f08db06526d6901aa08c110b5bc7dde6bc39905nd Text Text/XML Text/XML/HXT Text/XML/Schema Text/XML/Schema/TypeMapper \
3f08db06526d6901aa08c110b5bc7dde6bc39905nd utils utils/DrIFT-src utils/GenerateRules utils/InlineAxioms Common \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi Common/Lib Common/ATerm Logic CASL CASL/CCC CASL/CompositionTable \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi Syntax Static GUI HasCASL Haskell Modal CoCASL COL ConstraintCASL \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi CspCASL ATC Proofs Comorphisms Isabelle Driver Modifications \
f086b4b402fa9a2fefc7dda85de2a3cc1cd0a654rjung Taxonomy CASL_DL SoftFOL OWL_DL OMDoc PGIP Propositional
f4cbda69df0490c6deaacb8d04f103d200ddd183nd# the 'replacing spaces' example was taken from the (GNU) Make info manual
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# override on commandline for other architectures
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi /home/www/agbkb/forschung/formal_methods/CoFI/hets/`utils/sysname.sh`
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiGENERATERULES_deps = utils/GenerateRules/*hs $(DRIFT_deps)
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiGENITCORRECTIONS_deps = utils/itcor/GenItCorrections.hs
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiINLINEAXIOMS_deps = utils/InlineAxioms/InlineAxioms.hs \
30471a4650391f57975f60bbb6e4a90be7b284bfhumbedooh Modal/Parse_AS.hs Modal/ModalSign.hs Modal/Print_AS.hs Modal/StatAna.hs
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiGENRULECALL = $(GENRULES) -r Typeable -r ShATermConvertible \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiSETUPPREFIX = --prefix=$(HOME)/.ghc/$(ARCH)-$(OSBYUNAME)-hets-packages
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi ../$(SETUP) build; ../$(SETUP) haddock; ../$(SETUP) install --user
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# remove -fno-warn-orphans for older ghcs and add -ifgl
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi $(HC_WARN) -fglasgow-exts -fallow-overlapping-instances \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# -ddump-minimal-imports
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# uncomment to above line to generate .imports files for displayDependencyGraph
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiHC_OPTS_MAC := $(if $(findstring Darwin,$(shell uname -s)), \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi -optl-F$(HOME)/Library/Frameworks -optl-framework -optlGNUreadline,)
1d980e5489836e977ba59b419e27b0ec875c4bd3takashilogics = CASL HasCASL Isabelle Modal CoCASL COL CspCASL CASL_DL SoftFOL \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiTESTTARGETFILES += CASL/fromKif.hs CASL/capa.hs HasCASL/hacapa.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi ATC/ATCTest.hs ATC/ATCTest2.hs Common/ATerm/ATermLibTest.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi Common/ATerm/ATermDiffMain.hs Common/annos.hs Common/test_parser.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi SoftFOL/tests/PrintTPTPTests.hs Comorphisms/test/showKP.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi SoftFOL/tests/soapTest.hs Comorphisms/test/sublogicGraph.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiUNI_PACKAGE_CONF = $(wildcard ../uni/uni-package.conf)
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiHC_PACKAGE = -package-conf $(UNI_PACKAGE_CONF) -package uni-davinci \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# some modules from uni for haddock
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi# if uni/server is included also HaXml sources are needed
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiuni_dirs = ../uni/davinci ../uni/graphs ../uni/events \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiuni_sources = $(wildcard $(addsuffix /haddock/*.hs, $(uni_dirs))) \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiTESTTARGETFILES += OWL_DL/ToHaskellAS.hs Taxonomy/taxonomyTool.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi SoftFOL/tests/CMDL_tests.hs Static/test/TestDGTrans.hs
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi### list of directories to run checks in
1d980e5489836e977ba59b419e27b0ec875c4bd3takashihs_clean_files = Haskell/TiATC.hs Haskell/TiDecorateATC.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiPFE_DIRS = base/AST base/TI base/parse2 base/parse2/Lexer base/parse2/Parser \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi base/parse2/LexerGen base/parse2/LexerSpec base/tests/HbcLibraries \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi base/pretty base/syntax base/lib base/lib/Monads base/Modules base/defs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi property/TI property/defs property/parse2 property/parse2/Parser
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiPFE_PATHS = $(addprefix $(PFE_TOOLDIR)/, $(PFE_DIRS))
1d980e5489836e977ba59b419e27b0ec875c4bd3takashipfe_sources = $(wildcard $(addsuffix /*hs, $(PFE_PATHS)))
1d980e5489836e977ba59b419e27b0ec875c4bd3takashihappy_files += $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hs
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiprogramatica_pkg: $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hs \
b9bf3918f6eaf7747bcbfbd02792bcbe4a052784nilgun echo "of programatica package found"; else \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi cp -f utils/programatica.cabal ../programatica/tools; \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi echo "{-# OPTIONS -w #-}" > $@
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi$(LEX_DIR)Gen/HsLexerGen: $(LEX_DIR)Gen/*.hs $(LEX_DIR)Spec/*.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiderived_sources += Haskell/PreludeString.hs $(LEX_DIR)/HsLex.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiutils/appendHaskellPreludeString: utils/appendHaskellPreludeString.hs
b9bf3918f6eaf7747bcbfbd02792bcbe4a052784nilgunAPPENDPRELUDESTRING = utils/appendHaskellPreludeString \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi## rule for appendHaskellPreludeString
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiHaskell/PreludeString.hs: Haskell/PreludeString.append.hs \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashiAst_Haskell_files = HsDeclStruct HsExpStruct HsFieldsStruct \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi HsGuardsStruct HsKindStruct HsPatStruct HsTypeStruct HsAssocStruct \
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi#Ti_Haskell_files = TiTypes TiKinds TiDecorate TiInstanceDB
727872d18412fc021f03969b8641810d8896820bhumbedooh#Ti_Prop_files = property/TI/TiPropDecorate property/syntax/PropSyntaxRec
727872d18412fc021f03969b8641810d8896820bhumbedoohOther_PFE_files = property/AST/HsPropStruct base/defs/PNT \
cc7e1025de9ac63bd4db6fe7f71c158b2cf09fe4humbedooh base/defs/UniqueNames base/Modules/TypedIds base/Modules/Ents \
0d0ba3a410038e179b695446bb149cce6264e0abnd $(addprefix $(PFE_TOOLDIR)/base/AST/, $(Ast_Haskell_files)) \
0d0ba3a410038e179b695446bb149cce6264e0abnd## rule for ATC generation
205f749042ed530040a4f0080dbcb47ceae8a374rjungTESTTARGETFILES += Haskell/hana.hs Haskell/h2h.hs Haskell/h2hf.hs
7fec19672a491661b2fe4b29f685bc7f4efa64d4nd### Profiling (only for debugging)
1d980e5489836e977ba59b419e27b0ec875c4bd3takashi### Attention every module must be compiled with profiling or the linker
$(GENRULECALL) -o $@ $<
$(GENRULECALL) -o $@ $<
$(GENRULECALL) -o $@ $<
$(GENRULECALL) -o $@ $<
cpp_sources = \
$(wildcard utils/GenerateRules/*.hs) \
$(wildcard utils/InlineAxioms/*.hs) \
$(RM) $@
cgi:
(cd utils/GenerateRules; \
GenerateRules.hs -o ../genRules && strip ../genRules)
-i../.. -o $(INLINEAXIOMS)
if [ -d ../programatica ] ; then \
./clean.sh; \
### Common/LaTeX_maps.hs generation
strip $@
@echo -n "Generating pretty/LaTeX_maps.hs ... "
@(cd pretty >/dev/null; ../utils/genItCorrections \
$(GENRULES)
-o $@ $(OWL_DL_files)
$(RM) $@
## two hardcoded dependencies for a correct generation of Version.hs
.SUFFIXES:
%.hs: %.y
$(RM) $@
$(RM) $@
$(INLINEAXIOMS) $< > $@
%.d : %.hs
%.d : %.lhs
$(RM) $@
$(RM) $@
$(PERL) $+ > $@
## rule for Modal/ModalSystems.hs needed for ModalLogic Translation
# uses intransparently utils/outlineAxioms
$(RM) $@
@if [ -d $(INSTALLER_DIR) ] ; then \
sed "s/^\(SPASS_DIR_MAC=\).*/\1`ls utils/SPASS-ppc-mac/ | grep SPASS`/" Makefile.inst > Makefile.inst2 ;\
@echo Please do