X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fmatita%2FMakefile;h=39b348eea1a9ac19867bc15ec661835eb5695603;hb=1792dd8245b13e0093c99a993299e11621062773;hp=78e8fe8d574abc27b5fb33bd5e516f2acc78809d;hpb=196b1e626bd6ba5ef6b258a88294f116e30232e9;p=helm.git diff --git a/helm/software/matita/Makefile b/helm/software/matita/Makefile index 78e8fe8d5..39b348eea 100644 --- a/helm/software/matita/Makefile +++ b/helm/software/matita/Makefile @@ -178,9 +178,9 @@ tests.opt: $(foreach d,$(TEST_DIRS),$(d)-test-opt) cleantests: $(foreach d,$(TEST_DIRS),$(d)-cleantests) cleantests.opt: $(foreach d,$(TEST_DIRS),$(d)-cleantests-opt) -%-test: matitac matitadep matitaclean coq.moo +%-test: matitac matitadep matitaclean -cd $* && make -k clean all -%-test-opt: matitac.opt matitadep.opt matitaclean.opt coq.moo.opt +%-test-opt: matitac.opt matitadep.opt matitaclean.opt -cd $* && make -k clean.opt opt %-cleantests: matitaclean -cd $* && make clean @@ -209,17 +209,17 @@ dist_library@%: $(H)MATITA_RT_BASE_DIR=`pwd` \ MATITA_FLAGS="-system -conffile `pwd`/matita.conf.xml.build" \ ./matitamake$(BEST_EXT) -conffile `pwd`/matita.conf.xml.build \ - init dist_$* `pwd`/$* + init $* `pwd`/$* @echo "MATITAMAKE -system build" $(H)MATITA_RT_BASE_DIR=`pwd` \ MATITA_FLAGS="-system -conffile `pwd`/matita.conf.xml.build" \ ./matitamake$(BEST_EXT) -conffile `pwd`/matita.conf.xml.build \ - build dist_$* + build $* touch $@ endif -DEST = @RT_BASE_DIR@ +DESTDIR = $(RT_BASE_DIR) INSTALL_STUFF = \ icons/ \ matita.gtkrc \ @@ -227,21 +227,35 @@ INSTALL_STUFF = \ matita.ma.templ \ core_notation.moo \ matita.conf.xml \ + matita.conf.xml.user \ closed.xml \ gtkmathview.matita.conf.xml \ template_makefile.in \ - library/ \ - $(PROGRAMS_BYTE) \ + AUTHORS \ + LICENSE \ $(NULL) ifeq ($(HAVE_OCAMLOPT),yes) INSTALL_STUFF += $(PROGRAMS_OPT) +else +INSTALL_STUFF += $(PROGRAMS_BYTE) endif install: - install -d $(DEST) - cp -a .matita/ - cp -a $(INSTALL_STUFF) $(DEST) + # install main dir and executables + install -d $(DESTDIR) + cp -a $(INSTALL_STUFF) $(DESTDIR) + # install the library and corresponding scripts + if [ -d $(DESTDIR)/library ]; then rm -rf $(DESTDIR)/library; fi + cp -a .matita/xml/matita/ $(DESTDIR)/library/ + if [ -d $(DESTDIR)/ma ]; then rm -rf $(DESTDIR)/ma; fi + install -d $(DESTDIR)/ma +ifeq ($(HAVE_OCAMLOPT),yes) + for p in $(PROGRAMS_BYTE); do ln -s $$p.opt $(DESTDIR)/$$p; done +endif + cp -a library/ $(DESTDIR)/ma/stdlib/ + cp -a contribs/ $(DESTDIR)/ma/contribs/ uninstall: + rm -rf $(DESTDIR) STATIC_LINK = dist/static_link/static_link # for matita