1 BIN_DIR = /usr/local/bin
2 REQUIRES = helm-urimanager helm-cic_textual_parser helm-cic_proof_checking helm-mathql helm-mathql_interpreter
4 OCAMLOPTIONS = -I .. -package "$(REQUIRES)" -predicates "$(PREDICATES)"
5 OCAMLDEPOPTIONS = $(shell ocamlfind query -recursive -predicates "$(PREDICATES)" -i-format $(REQUIRES))
6 OCAMLC = ocamlfind ocamlc $(OCAMLOPTIONS)
7 OCAMLOPT = ocamlfind ocamlopt $(OCAMLOPTIONS)
8 OCAMLDEP = ocamldep -I .. -I ../../ocaml/mathql_interpreter -I ../../ocaml/mathql
10 LIBRARIES = $(shell ocamlfind query -recursive -predicates "byte $(PREDICATES)" -format "%d/%a" $(REQUIRES))
11 LIBRARIES_OPT = $(shell ocamlfind query -recursive -predicates "native $(PREDICATES)" -format "%d/%a" $(REQUIRES))
18 TOPLEVELOBJS = ../mQueryLevels.cmo ../mQueryGenerator.cmo topLevel.cmo
21 $(OCAMLDEP) $(OCAMLDEPOPTIONS) $(DEPOBJS) > .depend
23 topLevel: $(TOPLEVELOBJS) $(LIBRARIES)
24 $(OCAMLC) -linkpkg -o topLevel $(TOPLEVELOBJS)
26 topLevel.opt: $(TOPLEVELOBJS:.cmo=.cmx) $(LIBRARIES_OPT)
27 $(OCAMLOPT) -linkpkg -o topLevel.opt $(TOPLEVELOBJS:.cmo=.cmx)
29 .SUFFIXES: .ml .mli .cmo .cmi .cmx
32 .mli.cmi: $(LIBRARIES)
34 .ml.cmx: $(LIBRARIES_OPT)
38 rm -f *.cm[iox] *.o topLevel topLevel.opt
41 cp topLevel topLevel.opt $(BIN_DIR)
44 rm -f $(BIN_DIR)/topLevel $(BIN_DIR)/topLevel.opt
46 .PHONY: install uninstall clean
48 ifneq ($(MAKECMDGOALS), depend)