Makefile revision 09a67ca9b5cdf09e06470d4c965484783e2963f4
# $Id$
# Author: Klaus L�ttich
# Year: 2003
# This Makefile will compile the new hetcats system and provides also
# targets for test programs during implementation phases.
# !!! Note: This makefile is written for GNU make !!!
# (gmake on solaris ; make on linux)
####################################################################
## Some varibles, which control the compilation
CLEAN_PATH = Common:Logic:CASL:Syntax:Static:GUI:HasCASL:Haskell:Haskell/Language:Modal:CspCASL:$(INCLUDE_PATH)
HC_INCLUDE = -i$(INCLUDE_PATH)
### Profiling and Warnings (only for debugging)
### Attention every module must be compiled with profiling or the linker
### cannot link the various .o files properly. So after switching on
### Profiling, do an 'gmake clean; gmake'
### If you need Profiling comment out the following line
#HC_PROF = -prof -auto-all -Wall
### list of directories to run checks in
####################################################################
## sources for hetcats (semi - manually produced with a perl script)
# this variable holds the modules that should be documented
# the imported parsec library is not included!
####################################################################
### targets
#.PRECIOUS: sources_hetcats.mk
$(RM) $@
###############################
### TAGS files for (x)emacs
# load them with "M-x" "visit-tags-table" from
# use "M-." to search for a tag
# !!Beware this is somewhat instable, because it uses an absolute path!!
hetcats.TAGS: $(sources)
###############################
### Documentation via haddock
-t 'HetCATS -- a heterogenous CASL tool set'
###############
### clean up
### removes *.hi and *.o in all include directories
### remove binaries
$(RM) test_parser
### additonally removes *.d (dependency files) in every include directory
### also delete *.d.bak (dependency file backups)
### remove files also in own libraries
### additionally removes the files that define the sources-variable
### additionally removes files not in CVS tree
$(RM) $(drifted_files)
####################################################################
### test targets
####################################################################
### a parser to test annotation parser and Id parsers
$(RM) $@
### interactive
ghci:
### christian's target
### CASL parser
$(RM) $@
### HasCASL parser
$(RM) $@
### Haskell parser
$(RM) $@
$(HAPPY) $<
### Haskell wrap parser
$(RM) $@
### HetCASL parser
$(RM) $@
### HetCASL parser
$(RM) $@
### HetCASL with dev graph
$(RM) $@
$(HC) --make -o $@ $< $(HC_OPTS) -package-conf ../uni/uni-package.conf -package uni-davinci -package uni-server
### run tests in other directories
####################################################################
## Preparing the version of HetCATS
## two hardcoded dependencies for a correct generation of Version.hs
####################################################################
## rules for DrIFT
$(HAPPY) $<
$(AG) $<
$(DRIFT) $< > $@
$(AG) $< -o $@
$(DRIFT) $< > $@
## compiling rules for object and interface files
## compiling rules for dependencies
%.d : %.hs
%.d : %.lhs
####################################################################
## Setting a global search path (for dependency files)
## include every .d file in INCLUDE_PATH