]> matita.cs.unibo.it Git - helm.git/commitdiff
Makefile improved.
authorClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Mon, 3 Dec 2001 14:56:05 +0000 (14:56 +0000)
committerClaudio Sacerdoti Coen <claudio.sacerdoticoen@unibo.it>
Mon, 3 Dec 2001 14:56:05 +0000 (14:56 +0000)
helm/proofChecker/Makefile

index 1c3b9a174daacbc09249307f0fb6dba6eff1bab9..8cea8c8dc6dafcb895d26b3eb1dd5a371f32fda4 100644 (file)
@@ -2,10 +2,13 @@ BIN_DIR = /usr/local/bin
 REQUIRES = helm-cic_proof_checking
 PREDICATES =
 OCAMLOPTIONS = -package "$(REQUIRES)" -predicates "$(PREDICATES)"
-OCAMLC = ocamlfind ocamlc $(OCAMLOPTIONS)
+OCAMLC = ocamlfind ocamlc $(OCAMLOPTIONS) -g
 OCAMLOPT = ocamlfind ocamlopt $(OCAMLOPTIONS)
 OCAMLDEP = ocamldep
 
+LIBRARIES = $(shell ocamlfind query -recursive -predicates "byte $(PREDICATES)" -format "%d/%a" $(REQUIRES))
+LIBRARIES_OPT = $(shell ocamlfind query -recursive -predicates "native $(PREDICATES)" -format "%d/%a" $(REQUIRES))
+
 all: proofChecker
 opt: proofChecker.opt
 
@@ -16,18 +19,18 @@ PROOFCHECKEROBJS = proofChecker.cmo
 depend:
        $(OCAMLDEP) $(DEPOBJS) > .depend
 
-proofChecker: $(PROOFCHECKEROBJS)
+proofChecker: $(PROOFCHECKEROBJS) $(LIBRARIES)
        $(OCAMLC)  -linkpkg -o proofChecker $(PROOFCHECKEROBJS)
 
-proofChecker.opt: $(PROOFCHECKEROBJS:.cmo=.cmx)
+proofChecker.opt: $(PROOFCHECKEROBJS:.cmo=.cmx) $(LIBRARIES_OPT)
        $(OCAMLOPT) -linkpkg -o proofChecker.opt $(PROOFCHECKEROBJS:.cmo=.cmx)
 
 .SUFFIXES: .ml .mli .cmo .cmi .cmx
-.ml.cmo:
+.ml.cmo: $(LIBRARIES)
        $(OCAMLC) -c $<
-.mli.cmi:
+.mli.cmi: $(LIBRARIES)
        $(OCAMLC) -c $<
-.ml.cmx:
+.ml.cmx: $(LIBRARIES_OPT)
        $(OCAMLOPT) -c $<
 
 clean: