src/HOL/Makefile
author lcp
Thu, 13 Apr 1995 15:03:07 +0200
changeset 1044 5bf29088250e
parent 953 17d7fad9c9a2
child 1063 d33e3523a5e6
permissions -rw-r--r--
Simplified using pattern replacements.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     1
#########################################################################
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     2
#									#
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     3
# 			Makefile for Isabelle (CHOL)			#
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     4
#									#
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     5
#########################################################################
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     6
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     7
#To make the system, cd to this directory and type  
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     8
#	make -f Makefile 
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
     9
#To make the system and test it on standard examples, type  
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    10
#	make -f Makefile test
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    11
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    12
#Environment variable ISABELLECOMP specifies the compiler.
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    13
#Environment variable ISABELLEBIN specifies the destination directory.
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    14
#For Poly/ML, ISABELLEBIN must begin with a /
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    15
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    16
#Makes pure Isabelle (Pure) if this file is ABSENT -- but not 
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    17
#if it is out of date, since this Makefile does not know its dependencies!
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    18
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    19
BIN = $(ISABELLEBIN)
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    20
COMP = $(ISABELLECOMP)
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    21
NAMES = HOL Ord Set Fun subset equalities Prod Trancl Sum WF \
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    22
       mono Lfp Gfp Nat Inductive Finite Arith Sexp Univ List 
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    23
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    24
FILES = ROOT.ML add_ind_def.ML datatype.ML hologic.ML\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    25
	ind_syntax.ML indrule.ML intr_elim.ML simpdata.ML\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    26
	subtype.ML thy_syntax.ML ../Pure/section_utils.ML\
944
01d6571fa106 Added dependencies on ../Provers/hypsubst.ML and removed those on
nipkow
parents: 923
diff changeset
    27
	../Provers/hypsubst.ML ../Provers/classical.ML\
01d6571fa106 Added dependencies on ../Provers/hypsubst.ML and removed those on
nipkow
parents: 923
diff changeset
    28
        ../Provers/simplifier.ML ../Provers/splitter.ML\
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    29
 	$(NAMES:%=%.thy) $(NAMES:%=%.ML)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    30
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    31
$(BIN)/CHOL:   $(BIN)/Pure  $(FILES) 
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    32
	if [ -d $${ISABELLEBIN:?}/Pure ];\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    33
           	then echo Bad value for ISABELLEBIN: \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    34
                	$(BIN) is the Isabelle source directory; \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    35
                	exit 1; \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    36
           	fi;\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    37
	case "$(COMP)" in \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    38
	poly*)	echo 'make_database"$(BIN)/CHOL"; quit();'  \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    39
			| $(COMP) $(BIN)/Pure;\
953
17d7fad9c9a2 Now calls exit_use instead of use, for prompt failure if errors are detected.
lcp
parents: 944
diff changeset
    40
		echo 'open PolyML; exit_use"ROOT";' | $(COMP) $(BIN)/CHOL ;;\
17d7fad9c9a2 Now calls exit_use instead of use, for prompt failure if errors are detected.
lcp
parents: 944
diff changeset
    41
	sml*)	echo 'exit_use"ROOT.ML"; xML"$(BIN)/CHOL" banner;' | $(BIN)/Pure ;;\
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    42
	*)	echo Bad value for ISABELLECOMP: \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    43
                	$(COMP) is not poly or sml; exit 1;;\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    44
	esac
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    45
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    46
$(BIN)/Pure:
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    47
	cd ../Pure;  $(MAKE)
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    48
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    49
#### Testing of CHOL
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    50
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    51
#A macro referring to the object-logic (depends on ML compiler)
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    52
LOGIC:sh=case $ISABELLECOMP in \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    53
	poly*)	echo "$ISABELLECOMP $ISABELLEBIN/CHOL" ;;\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    54
	sml*)	echo "$ISABELLEBIN/CHOL" ;;\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    55
	*)	echo "echo Bad value for ISABELLECOMP: \
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    56
                	$ISABELLEBIN is not poly or sml; exit 1" ;;\
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    57
	esac
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    58
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    59
##IMP-semantics example
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    60
IMP_NAMES = Com Denotation Equiv Properties
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    61
IMP_FILES = IMP/ROOT.ML $(IMP_NAMES:%=IMP/%.thy) $(IMP_NAMES:%=IMP/%.ML)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    62
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    63
IMP:    $(BIN)/CHOL  $(IMP_FILES)
953
17d7fad9c9a2 Now calls exit_use instead of use, for prompt failure if errors are detected.
lcp
parents: 944
diff changeset
    64
	echo 'exit_use"IMP/ROOT.ML";quit();' | $(LOGIC)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    65
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    66
##The integers in CHOL
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    67
INTEG_NAMES = Relation Equiv Integ 
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    68
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    69
INTEG_FILES = Integ/ROOT.ML \
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    70
              $(INTEG_NAMES:%=Integ/%.thy) $(INTEG_NAMES:%=Integ/%.ML)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    71
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    72
Integ:  $(BIN)/CHOL  $(INTEG_FILES)
953
17d7fad9c9a2 Now calls exit_use instead of use, for prompt failure if errors are detected.
lcp
parents: 944
diff changeset
    73
	echo 'exit_use"Integ/ROOT.ML";quit();' | $(LOGIC)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    74
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    75
##I/O Automata
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    76
IOA_EX_NAMES = Action Channels Correctness Impl Lemmas Multiset Receiver Sender
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    77
IOA_MT_NAMES = Asig IOA Option Solve
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    78
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    79
IOA_FILES = IOA/ROOT.ML IOA/example/Packet.thy IOA/example/Spec.thy\
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    80
 $(IOA_EX_NAMES:%=IOA/example/%.thy) $(IOA_EX_NAMES:%=IOA/example/%.ML)\
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    81
 $(IOA_MT_NAMES:%=IOA/meta_theory/%.thy) $(IOA_MT_NAMES:%=IOA/meta_theory/%.ML)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    82
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    83
IOA:    $(BIN)/CHOL  $(IOA_FILES)
953
17d7fad9c9a2 Now calls exit_use instead of use, for prompt failure if errors are detected.
lcp
parents: 944
diff changeset
    84
	echo 'exit_use"IOA/ROOT.ML";quit();' | $(LOGIC)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    85
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    86
##Properties of substitutions
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    87
SUBST_NAMES = AList Setplus Subst Unifier UTerm UTLemmas
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    88
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    89
SUBST_FILES = Subst/ROOT.ML \
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    90
              $(SUBST_NAMES:%=Subst/%.thy) $(SUBST_NAMES:%=Subst/%.ML)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    91
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    92
Subst:  $(BIN)/CHOL  $(SUBST_FILES)
953
17d7fad9c9a2 Now calls exit_use instead of use, for prompt failure if errors are detected.
lcp
parents: 944
diff changeset
    93
	echo 'exit_use"Subst/ROOT.ML";quit();' | $(LOGIC)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    94
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    95
##Miscellaneous examples
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    96
EX_NAMES = LexProd MT Acc PropLog Puzzle Qsort LList Rec Simult Term String 
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    97
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
    98
EX_FILES = ex/ROOT.ML ex/cla.ML ex/meson.ML ex/mesontest.ML ex/rel.ML \
1044
5bf29088250e Simplified using pattern replacements.
lcp
parents: 953
diff changeset
    99
           ex/set.ML $(EX_NAMES:%=ex/%.thy) $(EX_NAMES:%=ex/%.ML)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   100
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   101
ex:     $(BIN)/CHOL  $(EX_FILES)
953
17d7fad9c9a2 Now calls exit_use instead of use, for prompt failure if errors are detected.
lcp
parents: 944
diff changeset
   102
	echo 'exit_use"ex/ROOT.ML";quit();' | $(LOGIC)
923
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   103
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   104
#Full test.
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   105
test:   $(BIN)/CHOL IMP Integ IOA Subst ex
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   106
	echo 'Test examples ran successfully' > test
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   107
ff1574a81019 new version of HOL with curried function application
clasohm
parents:
diff changeset
   108
.PRECIOUS:  $(BIN)/Pure $(BIN)/CHOL