X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fmatita%2FMakefile.in;h=b4cb75bd4ceb7e4a50f0d52f441489843fe4bafc;hb=6d1af82b714e5c6a7f33534d6832598e72cb23c3;hp=a3a6fe77dc617050a913f1685587a9e5d4299c8e;hpb=619a3a478a4f6b0a50782b620009f6a141c30a53;p=helm.git diff --git a/helm/matita/Makefile.in b/helm/matita/Makefile.in index a3a6fe77d..b4cb75bd4 100644 --- a/helm/matita/Makefile.in +++ b/helm/matita/Makefile.in @@ -1,3 +1,5 @@ +export SHELL=/bin/bash + MAKEFLAGS+=--no-print-directory OCAMLPATH = ../ocaml/METAS/ OCAMLFIND = OCAMLPATH=$(OCAMLPATH):$$OCAMLPATH @OCAMLFIND@ @@ -20,52 +22,74 @@ OCAMLC_FLAGS = $(OCAML_FLAGS) $(OCAML_THREADS_FLAGS) OCAMLC = $(OCAMLFIND) ocamlc $(OCAMLC_FLAGS) $(OCAML_DEBUG_FLAGS) OCAMLOPT = $(OCAMLFIND) opt $(OCAMLC_FLAGS) OCAMLDEP = $(OCAMLFIND) ocamldep $(OCAML_FLAGS) + +MATITA_FLAGS = +NODB=false +ifeq ($(NODB),true) + MATITA_FLAGS += -nodb +endif + + # objects for matita (GTK GUI) +NULL = CMOS = \ buildTimeConf.cmo \ matitaLog.cmo \ matitaTypes.cmo \ + matitaMoo.cmo \ matitaExcPp.cmo \ matitaMisc.cmo \ matitaDb.cmo \ + matitamakeLib.cmo \ + matitaInit.cmo \ matitaSync.cmo \ - matitacleanLib.cmo \ + matitacleanLib.cmo \ matitaDisambiguator.cmo \ matitaEngine.cmo \ - matitacLib.cmo \ - matitamakeLib.cmo \ + matitacLib.cmo \ matitaScript.cmo \ matitaGeneratedGui.cmo \ matitaGtkMisc.cmo \ + matitaMathView.cmo \ matitaGui.cmo \ - matitaMathView.cmo + $(NULL) # objects for matitac (batch compiler) CCMOS = \ buildTimeConf.cmo \ matitaLog.cmo \ matitaTypes.cmo \ + matitaMoo.cmo \ matitaExcPp.cmo \ matitaMisc.cmo \ matitaDb.cmo \ + matitamakeLib.cmo \ + matitaInit.cmo \ matitaSync.cmo \ matitaDisambiguator.cmo \ - matitaEngine.cmo \ matitacleanLib.cmo \ - matitacLib.cmo + matitaEngine.cmo \ + matitacLib.cmo \ + $(NULL) CLEANCMOS = $(CCMOS) -MAKECMOS = $(CCMOS) matitamakeLib.cmo - +MAKECMOS = $(CCMOS) +PROGRAMS_BYTE = matita matitac cicbrowser matitadep matitaclean matitamake +PROGRAMS = $(PROGRAMS_BYTE) matitatop dump_moo +PROGRAMS_OPT = $(patsubst %,%.opt,$(PROGRAMS_BYTE)) -all: matita.conf.xml matita matitac matitatop cicbrowser matitadep matitaclean matitamake +all: matita.conf.xml $(PROGRAMS) coq.moo matita.conf.xml: matita.conf.xml.sample - @echo - @echo "matita.conf.xml.sample is newer than matita.conf.xml" - @echo - @echo "PLEASE update your configuration file!" - @echo "(copying matita.conf.xml.sample should work)" - @echo - @false + @if diff matita.conf.xml.sample matita.conf.xml 1>/dev/null 2>/dev/null; then\ + touch matita.conf.xml;\ + else\ + echo;\ + echo "matita.conf.xml.sample is newer than matita.conf.xml";\ + echo;\ + echo "PLEASE update your configuration file!";\ + echo "(copying matita.conf.xml.sample should work)";\ + echo;\ + false;\ + fi matita.conf.xml.sample: matita.conf.xml.sample.in autoconf @@ -74,6 +98,11 @@ matita.conf.xml.sample: matita.conf.xml.sample.in @echo "WARNING: The configuration sample file has changed!" @echo +coq.moo: coq.ma matitac + ./matitac $(MATITA_FLAGS) coq.ma +coq.moo.opt: coq.ma matitac.opt + ./matitac.opt $(MATITA_FLAGS) coq.ma + ifeq ($(HAVE_OCAMLOPT),yes) CMXS = $(patsubst %.cmo,%.cmx,$(CMOS)) CCMXS = $(patsubst %.cmo,%.cmx,$(CCMOS)) @@ -89,7 +118,7 @@ CLEANLIB_DEPS := $(shell $(OCAMLFIND) query -recursive -predicates "byte" -forma CLEANLIBX_DEPS := $(shell $(OCAMLFIND) query -recursive -predicates "native" -format "%d/%a" $(CLEANREQUIRES)) MAKELIB_DEPS := $(shell $(OCAMLFIND) query -recursive -predicates "byte" -format "%d/%a" $(MAKEREQUIRES)) MAKELIBX_DEPS := $(shell $(OCAMLFIND) query -recursive -predicates "native" -format "%d/%a" $(MAKEREQUIRES)) -opt: matita.opt matitac.opt cicbrowser.opt matitadep.opt matitaclean.opt matitamake.opt +opt: $(PROGRAMS_OPT) coq.moo.opt else opt: @echo "Native code compilation is disabled" @@ -100,6 +129,9 @@ matita: $(LIB_DEPS) $(CMOS) matita.ml matita.opt: $(LIBX_DEPS) $(CMXS) matita.ml $(OCAMLOPT) $(PKGS) -linkpkg -o $@ $(CMXS) matita.ml +dump_moo: buildTimeConf.cmo matitaLog.cmo matitaMoo.cmo dump_moo.ml + $(OCAMLC) $(PKGS) -linkpkg -o $@ $^ + matitac: $(CLIB_DEPS) $(CCMOS) matitac.ml $(OCAMLC) $(CPKGS) -linkpkg -o $@ $(CCMOS) matitac.ml matitac.opt: $(CLIBX_DEPS) $(CCMXS) matitac.ml @@ -147,7 +179,9 @@ clean: cicbrowser cicbrowser.opt \ matitadep matitadep.opt \ matitaclean matitaclean.opt \ - matitatop matitatop.opt + matitamake matitamake.opt \ + matitatop matitatop.opt \ + dump_moo distclean: clean rm -f matitaGeneratedGui.ml matitaGeneratedGui.mli rm -f config.log config.status Makefile buildTimeConf.ml @@ -156,12 +190,18 @@ distclean: clean rm -f configure matita.conf.xml.sample tests: matitac matitadep matitaclean - @(cd library && make clean all) - @(cd tests && make clean all) + @(cd library && make MATITAC="- ../scripts/do_tests.sh $(DO_TESTS_OPTS) ../matitac ../matitaclean /dev/null" clean all) + @(cd tests && make MATITAC="- ../scripts/do_tests.sh $(DO_TESTS_OPTS) ../matitac ../matitaclean /dev/null" clean all) + @(cd contribs/LAMBDA-TYPES && make MATITAC="- ../../scripts/do_tests.sh $(DO_TESTS_OPTS) ../../matitac ../../matitaclean /dev/null" clean all) tests.opt: matitac.opt matitadep.opt matitaclean.opt - @(cd library && make clean.opt opt) - @(cd tests && make clean.opt opt) -.PHONY: tests tests.opt + @(cd library && make MATITAC="- ../scripts/do_tests.sh $(DO_TESTS_OPTS) ../matitac.opt ../matitaclean.opt /dev/null" clean.opt opt) + @(cd tests && make MATITAC="- ../scripts/do_tests.sh $(DO_TESTS_OPTS) ../matitac.opt ../matitaclean.opt /dev/null" clean.opt opt) + @(cd contribs/LAMBDA-TYPES && make MATITAC="- ../../scripts/do_tests.sh $(DO_TESTS_OPTS) ../../matitac.opt ../../matitaclean.opt /dev/null" clean.opt opt) +cleantests: matitaclean + @(cd library && make clean) + @(cd tests && make clean) + @(cd contribs/LAMBDA-TYPES && make clean) +.PHONY: tests tests.opt cleantests tags: TAGS .PHONY: TAGS @@ -188,3 +228,4 @@ endif ifeq ($(MAKECMDGOALS),opt) $(CMOS:%.cmo=%.cmi): $(LIBX_DEPS) endif +