Makefile revision 5ea9168eddbfbfe2282ed46dfe107a8962d6727b
d6fa26d0adaec6c910115be34fe7a5a5f402c14fMark Andrews# Makefile
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User# $Header$
71cef386fae61275b03e203825680b39fedaa8c6Tinderbox User# Author: (c) Klaus L�ttich, Christian Maeder, Uni Bremen 2002-2005
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User# Year: 2004
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User# This Makefile will compile the new hets system and provides also
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User# targets for test programs during implementation phases.
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
d6fa26d0adaec6c910115be34fe7a5a5f402c14fMark Andrews# !!! Note: This makefile is written for GNU make !!!
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User# (gmake on solaris)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userall: patch hets
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt####################################################################
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User## Some varibles, which control the compilation
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserINCLUDE_PATH = hxt
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserCLEAN_PATH = . hxt/Data hxt/Text/XML/HXT/DOM hxt/Text/XML/HXT/Parser \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User utils utils/DrIFT-src utils/GenerateRules utils/InlineAxioms Common \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Common/Lib Common/ATerm Logic CASL CASL/CCC CASL/CompositionTable \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Syntax Static GUI HasCASL Haskell Modal CoCASL COL \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User CspCASL ATC ToHaskell Proofs Comorphisms Isabelle Driver \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Taxonomy CASL_DL SPASS OWL_DL $(PFE_PATHS)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User# the 'replacing spaces' example was taken from the (GNU) Make info manual
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userempty =
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userspace = $(empty) $(empty)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User## set ghc imports properly for your system
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserGHC_IMPORTS = `$(HC) --print-libdir`/imports
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User# import directories for ghc-5.04.2
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserGHC5 = $(GHC_IMPORTS)/base:$(GHC_IMPORTS)/haskell98
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserDRIFT_ENV = \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User DERIVEPATH=.:ghc:$(GHC_IMPORTS):$(GHC5):$(subst $(space),:,$(PFE_PATHS))
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User# override on commandline for other architectures
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserINSTALLDIR = \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User /home/www/agbkb/forschung/formal_methods/CoFI/hets/`utils/sysname.sh`
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserDRIFT_deps = utils/DrIFT-src/*hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserGENERATERULES_deps = utils/GenerateRules/*hs $(DRIFT_deps) Common/Utils.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserINLINEAXIOMS_deps = utils/InlineAxioms/InlineAxioms.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Common/Lib/Pretty.hs Common/Keywords.hs Common/Lib/Set.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Common/Lib/Map.hs Common/Lib/Rel.hs Common/Lib/State.hs Common/Id.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Common/AS_Annotation.hs CASL/AS_Basic_CASL.hs CASL/ShowMixfix.hs \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User CASL/Utils.hs Common/Lexer.hs Common/Token.hs Common/Anno_Parser.hs \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Common/GlobalAnnotations.hs Common/PrettyPrint.hs \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Common/Print_AS_Annotation.hs Common/PPUtils.hs CASL/LiteralFuns.hs \
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User CASL/Print_AS_Basic.hs Common/AnnoState.hs CASL/Formula.hs \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User CASL/OpItem.hs CASL/SortItem.hs CASL/Inject.hs Common/Result.hs \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Common/ConvertLiteral.hs Common/Earley.hs CASL/MixfixParser.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User CASL/Parse_AS_Basic.hs CASL/Sign.hs CASL/Overload.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User CASL/StaticAna.hs Modal/AS_Modal.hs Modal/Parse_AS.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Modal/ModalSign.hs Modal/Print_AS.hs Modal/StatAna.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHC = ghc
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserPERL = perl
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHAPPY = happy -sga
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserGENRULES = utils/genRules
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserGENRULECALL = $(GENRULES) -r ShATermConvertible -i Common.ATerm.Lib
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserDRIFT = utils/DrIFT
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserINLINEAXIOMS = utils/outlineAxioms
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHADDOCK = haddock
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCPPP = cpp
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User# remove -fno-warn-orphans for older ghcs
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox UserHC_WARN = -Wall -fno-warn-orphans
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHC_FLAGS = -package fgl \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(HC_WARN) -fglasgow-exts -fno-monomorphism-restriction \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -fallow-overlapping-instances -fallow-undecidable-instances
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# -ddump-minimal-imports
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# flags also come in via ../uni/uni-package.conf
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# but added it here in case of compilation without uni
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHC_INCLUDE = $(addprefix -i, $(INCLUDE_PATH))
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox Userlogics = CASL HasCASL Isabelle Modal CoCASL COL CspCASL CASL_DL SPASS OWL_DL
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserTESTTARGETS += test_parser hetpa hetana Test.o \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User atermlibtest hatermdiff atctest atctest2 taxonomy
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserUNI_PACKAGE_CONF = $(wildcard ../uni/uni-package.conf)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userifneq ($(strip $(UNI_PACKAGE_CONF)),)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHC_PACKAGE = -package-conf $(UNI_PACKAGE_CONF) -package uni-davinci \
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User -package uni-server -DUNI_PACKAGE
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# some modules from uni for haddock
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# if uni/server is included also HaXml sources are needed
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Useruni_dirs = ../uni/davinci ../uni/graphs ../uni/events \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User ../uni/reactor ../uni/util ../uni/posixutil
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Useruni_sources = $(wildcard $(addsuffix /haddock/*.hs, $(uni_dirs))) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(wildcard ../uni/htk/haddock/*/*.hs)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserTESTTARGETS += hetdg OWL_DL/readAStest
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userendif
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User### list of directories to run checks in
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox UserTESTDIRS += Common CASL HasCASL
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserPFE_TOOLDIR = $(wildcard ../programatica/tools)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userifneq ($(strip $(PFE_TOOLDIR)),)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserPFE_DIRS = base/AST base/TI base/parse2 base/parse2/Lexer base/parse2/Parser \
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User base/parse2/LexerGen base/parse2/LexerSpec base/tests/HbcLibraries \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User base/pretty base/syntax base/lib base/lib/Monads base/Modules base/defs \
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User base/transforms base/transforms/Deriving property \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User property/syntax property/AST property/transforms \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User property/TI property/defs property/parse2 property/parse2/Parser
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserPFE_PATHS = $(addprefix $(PFE_TOOLDIR)/, $(PFE_DIRS))
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userpfe_sources = $(wildcard $(addsuffix /*hs, $(PFE_PATHS)))
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserPFE_PATH = $(addprefix -i, $(PFE_PATHS))
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserPFE_FLAGS = -package data -package text $(PFE_PATH) -DPROGRAMATICA
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userhappy_files += $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserLEX_DIR = $(PFE_TOOLDIR)/base/parse2/Lexer
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userpatch: Haskell/Programatica.patch
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User patch -sNlp0 -d $(PFE_TOOLDIR) -i `pwd`/$< || exit 0
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User$(LEX_DIR)/HsLex.hs: $(LEX_DIR)Gen/HsLexerGen
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User echo "{-# OPTIONS -w #-}" > $@
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $< >> $@
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User$(LEX_DIR)Gen/HsLexerGen: $(LEX_DIR)Gen/*.hs $(LEX_DIR)Spec/*.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(LEX_DIR)/HsTokens.hs
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User $(HC) --make -O -package data \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -i$(PFE_TOOLDIR)/base/tests/HbcLibraries \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -i$(PFE_TOOLDIR)/base/lib \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -i$(LEX_DIR) -i$(LEX_DIR)Gen -i$(LEX_DIR)Spec \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $@.hs -o $@
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User strip $@
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userlogics += Haskell
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userderived_sources += Haskell/PreludeString.hs $(LEX_DIR)/HsLex.hs \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $(LEX_DIR)Gen/HsLexerGen
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserAPPENDPRELUDESTRING = utils/appendHaskellPreludeString \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Haskell/ProgramaticaPrelude.hs
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User## rule for appendHaskellPreludeString
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHaskell/PreludeString.hs: Haskell/PreludeString.append.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(APPENDPRELUDESTRING)
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User $(APPENDPRELUDESTRING) < $< > $@
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserAst_Haskell_files = HsDeclStruct HsExpStruct HsFieldsStruct \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User HsGuardsStruct HsKindStruct HsPatStruct HsTypeStruct HsAssocStruct \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User HsModule HsName HsLiteral HsIdent
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserOther_PFE_files = property/AST/HsPropStruct base/defs/PNT \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User base/defs/UniqueNames base/Modules/TypedIds base/Modules/Ents \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User base/parse2/SourceNames base/syntax/SyntaxRec \
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User property/syntax/PropSyntaxStruct
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHaskell_files = $(addsuffix .hs, \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(addprefix $(PFE_TOOLDIR)/base/AST/, $(Ast_Haskell_files)) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(addprefix $(PFE_TOOLDIR)/, $(Other_PFE_files)))
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User## rule for ATC generation
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserHaskell/ATC_Haskell.der.hs: $(Haskell_files) $(GENRULES)
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User $(GENRULECALL) -i Haskell.BaseATC -o $@ $(Haskell_files)
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserTESTDIRS += ToHaskell
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserTESTTARGETS += hana h2hf
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userendif
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### Profiling (only for debugging)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### Attention every module must be compiled with profiling or the linker
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### cannot link the various .o files properly. So after switching on
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### Profiling, do an 'gmake real_clean; gmake'
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### Comment in the following line for switching on profiling.
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User#HC_PROF = -prof -auto-all -fignore-asserts
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserHC_OPTS = $(HC_FLAGS) $(HC_INCLUDE) $(HC_PACKAGE) $(PFE_FLAGS) $(HC_PROF) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -DCASLEXTENSIONS
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User####################################################################
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User## sources for hets
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox Usernon_sources = Common/LaTeX_maps.svmono.hs CspCASL/Main.hs \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User Common/CaslLanguage.hs ./Test.hs Static/LogicStructured.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserSOURCE_PATHS = $(CLEAN_PATH)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usersources = hets.hs $(filter-out $(non_sources), \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(wildcard $(addsuffix /[A-Z]*hs, $(SOURCE_PATHS))))
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User#endif
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userobjects = $(sources:%.hs=%.o)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userdrifted_files = Syntax/AS_Architecture.hs Syntax/AS_Library.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Common/AS_Annotation.hs CASL/AS_Basic_CASL.hs Syntax/AS_Structured.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User HasCASL/As.hs ATC/DevGraph.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Modal/AS_Modal.hs CoCASL/AS_CoCASL.hs COL/AS_COL.hs CASL_DL/AS_CASL_DL.hs\
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(gendrifted_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Useratc_files = Common/AS_Annotation.der.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Syntax/AS_Structured.der.hs Syntax/AS_Architecture.der.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Common/GlobalAnnotations.hs Syntax/AS_Library.der.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Logic/Prover.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Useratc_der_files = $(foreach file, $(atc_files), \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User ATC/$(basename $(basename $(notdir $(file)))).der.hs)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserATC/AS_Annotation.der.hs: Common/AS_Annotation.der.hs $(GENRULES)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $(GENRULECALL) -o $@ $<
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserATC/AS_Structured.der.hs: Syntax/AS_Structured.der.hs $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Annotation -i ATC.Grothendieck -o $@ $<
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserATC/AS_Architecture.der.hs: Syntax/AS_Architecture.der.hs $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Structured -o $@ $<
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserATC/AS_Library.der.hs: Syntax/AS_Library.der.hs $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Architecture -o $@ $<
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserATC/GlobalAnnotations.der.hs: Common/GlobalAnnotations.hs $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Annotation -o $@ $<
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserATC/Prover.der.hs: Logic/Prover.hs $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -x ProverTemplate -i ATC.AS_Annotation -o $@ $<
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserCASL_files = CASL/Sublogic.hs CASL/Morphism.hs CASL/Sign.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User CASL/AS_Basic_CASL.der.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserHasCASL_files = HasCASL/As.hs HasCASL/Le.hs HasCASL/Sublogic.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserIsabelle_files = Isabelle/IsaSign.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserModal_files = Modal/AS_Modal.hs Modal/ModalSign.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCoCASL_files = CoCASL/AS_CoCASL.hs CoCASL/CoCASLSign.hs CoCASL/Sublogic.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCOL_files = COL/AS_COL.hs COL/COLSign.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCspCASL_files = CspCASL/AS_CSP_CASL.hs CspCASL/SignCSP.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCASL_DL_files = CASL_DL/AS_CASL_DL.hs CASL_DL/Sign.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserSPASS_files = SPASS/Sign.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserOWL_DL_files = OWL_DL/Sign.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Useratc_logic_files = $(foreach logic, $(logics), $(logic)/ATC_$(logic).der.hs)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usergenerated_rule_files = $(atc_der_files) $(atc_logic_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usergendrifted_files = $(patsubst %.der.hs, %.hs, $(generated_rule_files))
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userinline_axiom_files = Comorphisms/CASL2PCFOL.hs Comorphisms/PCFOL2CFOL.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Comorphisms/Modal2CASL.hs Comorphisms/CASL2TopSort.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Comorphisms/CASL2SubCFOL.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usergen_inline_axiom_files = $(patsubst %.hs,%.inline.hs, $(inline_axiom_files))
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userderived_sources += $(drifted_files) Driver/Version.hs $(happy_files) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(inline_axiom_files) Modal/ModalSystems.hs
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# sources that have {-# OPTIONS -cpp #-}
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usercpp_sources = Common/DynamicUtils.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Common/Lib/Set.hs Common/Lib/Map.hs ATC/Set.hs\
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Isabelle/Logic_Isabelle.hs Isabelle/CreateTheories.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User SPASS/Logic_SPASS.hs GUI/Utils.hs Driver/WriteFn.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Comorphisms/LogicList.hs Comorphisms/LogicGraph.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Comorphisms/KnownProvers.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User GUI/ShowGraph.hs hets.hs $(happy_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# unused, remove when header files are gone
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usergenrule_header_files = $(wildcard ATC/*.header.hs)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usernondoc_sources = $(wildcard utils/DrIFT-src/*.hs) \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $(wildcard utils/DrIFT-src/*.lhs) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(wildcard utils/GenerateRules/*.hs) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(wildcard utils/InlineAxioms/*.hs) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(cpp_sources) $(pfe_sources) $(gen_inline_axiom_files) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(genrule_header_files) $(generated_rule_files) \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $(PFE_TOOLDIR)/property/parse2/Parser/PropParser.hspp \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Modal/GeneratePatterns.inline.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Haskell/PreludeString.append.hs Haskell/ProgramaticaPrelude.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User hxt/HXT.hs hxt/Net.hs $(patsubst %.hs, %.der.hs, $(drifted_files))
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userhspp_sources = $(patsubst %.hs, %.hspp, $(cpp_sources))
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# this variable holds the modules that should be documented
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userdoc_sources = $(filter-out $(nondoc_sources), $(sources) $(hspp_sources))
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usertax_sources = Taxonomy/AbstractGraphView.hs Taxonomy/MMiSSOntology.hs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Taxonomy/MMiSSOntologyGraph.hs Taxonomy/OntoParser.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usertax_objects = $(patsubst %.hs, %.o, $(tax_sources))
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User####################################################################
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### targets
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User.PHONY : all hets-opt hets-optimized clean o_clean real_clean bin_clean \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User distclean check capa hacapa h2h h2hf clean_genRules genRules \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User taxonomy count doc apache_doc post_doc4apache \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User derivedSources install_hets install release cgi patch ghci
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User.SECONDARY : %.hs %.d $(generated_rule_files) $(gen_inline_axiom_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userpatch:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userhets: $(sources) $(derived_sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(HC) --make -o $@ hets.hs $(HC_OPTS)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userhets-opt:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) distclean
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) derivedSources
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) clean
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) hets-optimized
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox Userhets-optimized: $(derived_sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(HC) --make -O -o hets hets.hs $(HC_OPTS)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User strip hets
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userhets-old: $(objects)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) $@
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User $(HC) -o hets $(HC_OPTS) $(objects)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usercgi:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) distclean
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) derivedSources
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) real_clean
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) hets.cgi
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userhets.cgi: $(sources) GUI/hets_cgi.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User ghc --make GUI/hets_cgi.hs -o $@ $(HC_INCLUDE) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(HC_FLAGS) $(PFE_FLAGS) -O
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User strip hets.cgi
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User###############################
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### TAGS files for (x)emacs
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User# load them with "M-x" "visit-tags-table" from
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# "HetCATS/hetcats.TAGS"
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# use "M-." to search for a tag
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# !!Beware this is somewhat instable, because it uses an absolute path!!
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userhetcats.TAGS: $(sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User /home/ger/linux/ghc-5.04.2/bin/i386-unknown-linux/hasktags \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(sources); mv TAGS $@; mv tags hetcats.tags
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userhets_maintainers.txt: $(sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User @echo 'File : Maintainer' > $@
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User @echo -n Generating $@ " "
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User @$(PERL) -e \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User 'foreach my $$f (@ARGV) { open I, "<$$f"; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User print "$$f :"; while (<I>) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User { if(m,^\s*Maintainer\s*:\s*(.*)$$,o) { \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User print " $$1" ; last} }; print "\n"; close I; }' \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(sources) >> $@
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User @echo " done"
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User###############################
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User### count lines of code
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usercount: $(sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User wc -l $(sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User###############################
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### Documentation via haddock
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userdoc: docs/index.html
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# generate haddock documentation with links to sources
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# the interface treatment is stolen from uni/mk/suffix.mk
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userdocs/index.html: $(doc_sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) -r docs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User mkdir docs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User cp -r ../uni/www docs/www || mkdir docs/www
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User HINTERFACES0=`find docs/www -name '*.haddock' \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -printf "--read-interface=www/%P,%p "` ; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User HINTERFACES=`echo $$HINTERFACES0 | \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(PERL) -pe 's+/[^/]*.haddock,+,+g'` ; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(HADDOCK) -o docs -h -v -s ../%F $$HINTERFACES \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -t 'Hets - the Heterogeneous Tool Set' \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -p Hets-Haddock-Prologue.txt $(doc_sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# sources are not copied here
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userapache_doc:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) -r docs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User cvs up -d ; echo "CVS exited with: " $$?
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) hets-opt
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) doc
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) post_doc4apache
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) o_clean
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(MAKE) hets.cgi
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userpost_doc4apache:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) -r a-docs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User cp -r docs a-docs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(PERL) utils/post_process_docs.pl a-docs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User 'Common.Lib.Map.html:Common.Lib._Map.html'
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(PERL) utils/post_process_docs.pl a-docs \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User 'Data.Map.html:Data._Map.html'
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User###############################
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### release management
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserderivedSources: $(derived_sources) $(hspp_sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userutils/DrIFT: $(DRIFT_deps)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User (cd utils/DrIFT-src; $(HC) --make DrIFT.hs -o ../DrIFT && \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User strip ../DrIFT)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userutils/genRules: $(GENERATERULES_deps)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User (cd utils/GenerateRules; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(HC) --make -i../DrIFT-src -i../.. $(HC_WARN) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User GenerateRules.hs -o ../genRules && strip ../genRules)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User# "hssource" for ghc-5.04.2
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User$(INLINEAXIOMS): $(INLINEAXIOMS_deps)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(HC) --make utils/InlineAxioms/InlineAxioms.hs $(HC_WARN) $(HC_PROF) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -package hssource -i../.. -o $(INLINEAXIOMS)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User strip $(INLINEAXIOMS)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userrelease:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) -r HetCATS
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User cvs -d :pserver:cvsread@cvs-agbkb.informatik.uni-bremen.de:/repository\
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User co -P HetCATS
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) -r uni
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User if [ -d ../uni ] ; then ln -s ../uni uni ; fi
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) -r programatica
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User if [ -d ../programatica ] ; then \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User mkdir programatica; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User ln -s ../../programatica/tools programatica/tools ; fi
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User (cd HetCATS; $(MAKE) derivedSources; $(MAKE) clean; \
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User cp Makefile Makefile.orig; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User cp ReleaseMakefile Makefile; \
dec590a3deb8e87380a8bd3a77d535dba3729bf6Tinderbox User ./clean.sh; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User find . -name CVS -o -name \*.o -o -name \*.hi | xargs $(RM) -r; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) clean.*)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User tar cvf HetCATS.tar HetCATS
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userinstall-hets:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User chmod g+w hets
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User cp -p hets $(INSTALLDIR)/versions/hets-`cat version_nr`
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User cp -p version_nr $(INSTALLDIR)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User (cd $(INSTALLDIR); $(RM) hets; \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User ln -s versions/hets-`cat version_nr` hets; $(RM) version_nr)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userinstall: hets-opt install-hets
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User#############################
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### ATC DrIFT-rule generation
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UsergenRules: $(generated_rule_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCASL/ATC_CASL.der.hs: $(CASL_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.GlobalAnnotations -o $@ $(CASL_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserHasCASL/ATC_HasCASL.der.hs: $(HasCASL_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(HasCASL_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserIsabelle/ATC_Isabelle.der.hs: $(Isabelle_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(Isabelle_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserModal/ATC_Modal.der.hs: $(Modal_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(Modal_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCASL_DL/ATC_CASL_DL.der.hs: $(CASL_DL_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CASL_DL_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCoCASL/ATC_CoCASL.der.hs: $(CoCASL_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CoCASL_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCOL/ATC_COL.der.hs: $(COL_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(COL_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserCspCASL/ATC_CspCASL.der.hs: $(CspCASL_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i CASL.ATC_CASL -o $@ $(CspCASL_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserSPASS/ATC_SPASS.der.hs: $(SPASS_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Annotation -o $@ $(SPASS_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox UserOWL_DL/ATC_OWL_DL.der.hs: $(OWL_DL_files) $(GENRULES)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(GENRULECALL) -i ATC.AS_Annotation -i OWL_DL.ReadWrite \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User -o $@ $(OWL_DL_files)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userclean_genRules:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) $(generated_rule_files) $(gendrifted_files) $(hspp_sources) \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User Haskell/ATC_Haskell.der.hs
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User###############
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### clean up
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userclean: bin_clean o_clean
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### removes *.hi and *.o in all include directories
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Usero_clean:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User for p in $(CLEAN_PATH) ; do \
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User (cd $$p ; $(RM) *.hi *.o) ; done
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### remove binaries
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userbin_clean:
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) hets
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) hets.cgi
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) test_parser
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) CASL/capa
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) HasCASL/hacapa
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) Haskell/hana
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) ToHaskell/h2h
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) ToHaskell/h2hf
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) Syntax/hetpa
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) Static/hetana
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) GUI/hetdg
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) hetpa
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) hetana
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) hetdg
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) atctest2
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $(RM) atctest
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) Common/annos
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User $(RM) Taxonomy/taxonomyTool
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User $(RM) OWL_DL/readAStest
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### additionally removes the library files
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userreal_clean: clean
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User### additionally removes generated files not in the CVS tree
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox Userdistclean: clean clean_genRules
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) $(derived_sources)
811ccf37deef5ad425a6bfb3a71f6730d4d3ebc4Tinderbox User $(RM) utils/DrIFT utils/genRules $(INLINEAXIOMS)
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User####################################################################
7911e6f9de303bca5a3d8b34f4330c8f7cecffaeTinderbox User### test targets
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User####################################################################
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User### a parser to test annotation parser and Id parsers
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Usertest_parser: Common/test_parser
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserCommon/test_parser: Common/test_parser.hs Common/AS_Annotation.der.hs
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $(HC) --make -o $@ $< $(HC_OPTS)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User### interactive
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Userghci: $(derived_sources)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User $(HC)i $(HC_OPTS)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User### christian's target
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User### CASL parser
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox Usercapa: CASL/capa
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox UserCASL/capa: CASL/capa.hs Common/*.hs CASL/*.hs
c313914d0e66b20969215e519bbf2ab4ecf39512Tinderbox User $(HC) --make -o $@ $< $(HC_OPTS)
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User
fae13836a33b474a6aa2c147df8334f5b1ffae45Tinderbox User### HasCASL parser
hacapa: HasCASL/hacapa
HasCASL/hacapa: HasCASL/hacapa.hs Common/*.hs HasCASL/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### Haskell analysis
hana: Haskell/hana
Haskell/hana: Haskell/hana.hs Haskell/HatAna.hs Haskell/PreludeString.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### Haskell to Isabelle-HOLCF translation
h2hf: ToHaskell/h2hf
ToHaskell/h2hf: ToHaskell/h2hf.hs ToHaskell/*.hs Haskell/*.hs \
HasCASL/*.hs Isabelle/*.hs Common/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### HasCASL to Haskell translation
h2h: ToHaskell/h2h
ToHaskell/h2h: ToHaskell/h2h.hs ToHaskell/*.hs Haskell/*.hs HasCASL/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### HetCASL parser
hetpa: Syntax/hetpa.hs Syntax/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### HetCASL parser
hetana: Static/hetana.hs Static/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### ATC test system
atctest: ATC/ATCTest.hs ATC/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
atctest2: ATC/ATCTest2.hs Common/SimpPretty.hs Common/ATerm/*.hs \
Common/Lib/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### ATerm.Lib test system
atermlibtest: Common/ATerm/ATermLibTest.hs Common/SimpPretty.hs \
Common/ATerm/*.hs Common/Lib/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
hatermdiff: Common/ATerm/ATermDiffMain.hs Common/SimpPretty.hs \
Common/ATerm/*.hs Common/Lib/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### OWL_DL test target
OWL_DL/readAStest: OWL_DL/ToHaskellAS.hs Common/ATerm/*.hs \
Common/Lib/*.hs OWL_DL/*.hs
$(HC) --make -o $@ $< $(HC_OPTS)
### HetCASL with dev graph
hetdg: GUI/hetdg.hs $(drifted_files) *.hs
$(HC) --make -o $@ $< $(HC_OPTS)
taxonomy: Taxonomy/taxonomyTool
Taxonomy/taxonomyTool: Taxonomy/taxonomyTool.hs $(tax_sources)
$(HC) --make -o $@ $< $(HC_OPTS)
### run tests in other directories
check: $(TESTTARGETS)
for i in $(TESTDIRS); do $(MAKE) -C $$i check; done
####################################################################
## Preparing the version of HetCATS
Driver/Version.hs: Driver/Version.in version_nr
$(RM) $@
$(PERL) utils/build_version.pl version_nr < Driver/Version.in > $@
chmod 444 $@
## two hardcoded dependencies for a correct generation of Version.hs
Driver/Options.hs Driver/WriteFn.hs Driver/ReadFn.hs: Driver/Version.hs
hets.hs: Driver/Version.hs
####################################################################
## rules for DrIFT
.SUFFIXES:
%: %.hs
$(HC) --make -o $@ $<
%.hs: %.y
$(HAPPY) -o $@.tmp $<
echo "{-# OPTIONS -w #-}" > $@
cat $@.tmp >> $@
$(RM) $@.tmp
%.hs: %.der.hs $(DRIFT)
$(RM) $@
($(DRIFT_ENV); export DERIVEPATH; $(DRIFT) $< > $@)
chmod 444 $@
## rules for inlineAxioms
%.hs: %.inline.hs $(INLINEAXIOMS)
$(RM) $@
$(INLINEAXIOMS) $< > $@
chmod 444 $@
## rule for cpp and haddock
%.hspp: %.hs
$(HC) -E -cpp -DUNI_PACKAGE -optP -P $<
## compiling rules for object and interface files
%.o %.hi: %.hs
$(HC) -c $< $(HC_OPTS)
%.o %.hi: %.lhs
$(HC) -c $< $(HC_OPTS)
## compiling rules for dependencies
%.d : %.hs
$(HC) -M $< $(HC_OPTS) -optdep-f -optdep$@
%.d : %.lhs
$(HC) -M $< $(HC_OPTS) -optdep-f -optdep$@
## rule for Modal/ModalSystems.hs needed for ModalLogic Translation
# uses intransparently utils/outlineAxioms
Modal/ModalSystems.hs: Modal/GeneratePatterns.inline.hs.in \
utils/genTransMFormFunc.pl $(INLINEAXIOMS)
$(RM) $@
$(PERL) utils/genTransMFormFunc.pl $< $@
chmod 444 $@