From a11974b287a9ede8d5cc352aef27a4d4b456a611 Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Tue, 24 Feb 2015 12:50:19 +0100 Subject: [PATCH] make the Makefile compile the library correctly, and automatically find all the files --- Makefile | 32 +----- README.txt | 2 +- configure | 2 - lib/ModuRes/Makefile | 236 ------------------------------------------- 4 files changed, 5 insertions(+), 267 deletions(-) delete mode 100755 configure delete mode 100644 lib/ModuRes/Makefile diff --git a/Makefile b/Makefile index a7e4ef57..219ed473 100644 --- a/Makefile +++ b/Makefile @@ -24,7 +24,7 @@ $(call includecmdwithout@,$(COQBIN)coqtop -config) ########################## COQLIBS?=-I . -R lib/ModuRes ModuRes -COQDOCLIBS?=-R lib/ModuRes ModuRes +COQDOCLIBS?=-I lib ########################## # # @@ -64,7 +64,7 @@ endif # # ###################### -VFILES:=$(wildcard *.v) +VFILES:=$(wildcard *.v) $(wildcard lib/ModuRes/*.v) -include $(addsuffix .d,$(VFILES)) .SECONDARY: $(addsuffix .d,$(VFILES)) @@ -88,7 +88,7 @@ endif # # ####################################### -all: $(VOFILES) ./lib/ModuRes +all: $(VOFILES) spec: $(VIFILES) @@ -122,16 +122,7 @@ beautify: $(VFILES:=.beautified) @echo 'Do not do "make clean" until you are sure that everything went well!' @echo 'If there were a problem, execute "for file in $$(find . -name \*.v.old -print); do mv $${file} $${file%.old}; done" in your shell/' -.PHONY: all opt byte archclean clean install userinstall depend html validate ./lib/ModuRes - -################### -# # -# Subdirectories. # -# # -################### - -./lib/ModuRes: - cd ./lib/ModuRes ; $(MAKE) all +.PHONY: all opt byte archclean clean install userinstall depend html validate #################### # # @@ -148,28 +139,13 @@ opt: userinstall: +$(MAKE) USERINSTALL=true install -install: - install -d $(DSTROOT)$(COQLIBINSTALL)/ModuRes; \ - for i in $(VOFILESINC); do \ - install -m 0644 $$i $(DSTROOT)$(COQLIBINSTALL)/ModuRes/`basename $$i`; \ - done - +cd ./lib/ModuRes && $(MAKE) DSTROOT="$(DSTROOT)" INSTALLDEFAULTROOT="$(INSTALLDEFAULTROOT)/./lib/ModuRes" install - -install-doc: - install -d "$(DSTROOT)"$(COQDOCINSTALL)/ModuRes/html - for i in html/*; do \ - install -m 0644 $$i "$(DSTROOT)"$(COQDOCINSTALL)/ModuRes/$$i;\ - done - clean: rm -f $(VOFILES) $(VIFILES) $(GFILES) $(VFILES:.v=.v.d) $(VFILES:=.beautified) $(VFILES:=.old) rm -f all.ps all-gal.ps all.pdf all-gal.pdf all.glob $(VFILES:.v=.glob) $(VFILES:.v=.tex) $(VFILES:.v=.g.tex) all-mli.tex - rm -rf html mlihtml - (cd ./lib/ModuRes ; $(MAKE) clean) archclean: rm -f *.cmx *.o - (cd ./lib/ModuRes ; $(MAKE) archclean) printenv: @"$(COQBIN)coqtop" -config diff --git a/README.txt b/README.txt index d0dd05ba..6144b865 100644 --- a/README.txt +++ b/README.txt @@ -83,7 +83,7 @@ HOW TO COMPILE To compile the development, run - > (cd lib/ModuRes; make) && make + > make -j in the folder containing this README. diff --git a/configure b/configure deleted file mode 100755 index 244a33b8..00000000 --- a/configure +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -coq_makefile lib/ModuRes -R lib/ModuRes ModuRes *.v -o Makefile diff --git a/lib/ModuRes/Makefile b/lib/ModuRes/Makefile deleted file mode 100644 index bd848acd..00000000 --- a/lib/ModuRes/Makefile +++ /dev/null @@ -1,236 +0,0 @@ -############################################################################# -## v # The Coq Proof Assistant ## -## "$@" || ( RV=$$?; rm -f "$@"; exit $${RV} ) - -%.v.beautified: - $(COQC) $(COQDEBUG) $(COQFLAGS) -beautify $* - -# WARNING -# -# This Makefile has been automagically generated -# Edit at your own risks ! -# -# END OF WARNING - -- GitLab