1 BIN_DIR = /usr/local/bin
2 REQUIRES = lablgtkmathview helm-cic_textual_parser helm-tex_cic_textual_parser \
3 gdome2-xslt helm-mathql_interpreter helm-mathql_generator \
4 helm-tactics hbugs-client mathml-editor helm-cic_transformations \
5 helm-cic_textual_parser2
6 PREDICATES = "gnome,init,glade"
7 OCAMLOPTIONS = -package "$(REQUIRES)" -predicates "$(PREDICATES)" -pp camlp4o
9 OCAMLC = $(OCAMLFIND) ocamlc -thread $(OCAMLOPTIONS)
10 OCAMLOPT = $(OCAMLFIND) ocamlopt -thread $(OCAMLOPTIONS)
11 OCAMLDEP = ocamldep -pp camlp4o
13 LIBRARIES = $(shell $(OCAMLFIND) query -recursive -predicates "byte $(PREDICATES)" -format "%d/%a" $(REQUIRES))
14 LIBRARIES_OPT = $(shell $(OCAMLFIND) query -recursive -predicates "native $(PREDICATES)" -format "%d/%a" $(REQUIRES))
16 all: styles gTopLevel regtest
17 opt: styles gTopLevel.opt regtest.opt
20 $(MAKE) -C ../hbugs/ start
22 $(MAKE) -C ../hbugs/ stop
25 proofEngine.mli logicalOperations.mli oldDisambiguate.mli \
26 disambiguatingParser.mli termEditor.mli texTermEditor.mli xmlDiff.mli \
27 chosenTransformer.mli termViewer.mli invokeTactics.mli hbugs.mli \
31 $(INTERFACE_FILES) $(INTERFACE_FILES:%.mli=%.ml) \
32 gTopLevel.ml regtest.ml batchParser.ml batchParser.mli
34 TOPLEVELOBJS = $(INTERFACE_FILES:%.mli=%.cmo) gTopLevel.cmo
36 $(INTERFACE_FILES:%.mli=%.cmo) batchParser.cmo regtest.cmo
38 $(INTERFACE_FILES:%.mli=%.cmo): $(LIBRARIES)
39 $(INTERFACE_FILES:%.mli=%.cmx): $(LIBRARIES_OPT)
42 @echo "***********************************************************************"
43 @if [ -d stylesheets -a -d meta_stylesheets ] ; then echo -e "* stylesheets and metastylesheets found: *\\n* I will create the request hyperlinks in styles *" ; else echo -e "* stylesheets or meta_stylesheets not found: *\\n* you should check-out the two directories from the MoWGLI repository *" ; exit -1 ; fi
44 @echo "***********************************************************************"
46 (cd styles && for i in ../stylesheets/*.xsl ; do ln -s $$i; done)
47 (cd styles && for i in ../stylesheets/generated/*.xsl ; do ln -s $$i; done)
48 (cd styles && rm rootcontent.xsl && ln -s ../rootcontent.xsl)
51 $(OCAMLDEP) $(DEPOBJS) > .depend
53 gTopLevel: $(TOPLEVELOBJS) $(LIBRARIES)
54 $(OCAMLC) -linkpkg -o $@ $(TOPLEVELOBJS)
55 gTopLevel.opt: $(TOPLEVELOBJS:.cmo=.cmx) $(LIBRARIES_OPT)
56 $(OCAMLOPT) -linkpkg -o $@ $(TOPLEVELOBJS:.cmo=.cmx)
58 regtest: $(REGTESTOBJS) $(LIBRARIES)
59 $(OCAMLC) -linkpkg -o $@ $(REGTESTOBJS)
60 regtest.opt: $(REGTESTOBJS:.cmo=.cmx) $(LIBRARIES)
61 $(OCAMLOPT) -linkpkg -o $@ $(REGTESTOBJS:.cmo=.cmx)
63 .SUFFIXES: .ml .mli .cmo .cmi .cmx
71 $(TOPLEVELOBJS): $(LIBRARIES)
72 $(TOPLEVELOBJS:.cmo=.cmx)): $(LIBRARIES_OPT)
75 rm -f *.cm[iox] *.o gTopLevel{,.opt} regtest{,.opt}
77 cp gTopLevel gTopLevel.opt $(BIN_DIR)
79 rm -f $(BIN_DIR)/gTopLevel $(BIN_DIR)/gTopLevel.opt
81 .PHONY: install uninstall clean test
83 INTESTS := $(wildcard tests/*.cic)
84 OUTTESTS := $(patsubst %, %.test, $(INTESTS))
88 tests/%.cic.test: tests/%.cic regtest
89 time ./regtest -gen $<
91 ./regtest $(INTESTS) 2> /dev/null
93 ./regtest -dump $(INTESTS) 2> /dev/null
95 ifneq ($(MAKECMDGOALS), depend)