Skip to content
Snippets Groups Projects
Commit e0b972d7 authored by Ralf Jung's avatar Ralf Jung
Browse files

update Makefile

parent d1d5440b
No related branches found
No related tags found
No related merge requests found
Pipeline #
# Determine Coq version
COQ_VERSION=$(shell coqc --version | egrep -o 'version 8.[0-9]' | egrep -o '8.[0-9]')
COQ_MAKEFILE_FLAGS ?=
ifeq ($(COQ_VERSION), 8.6)
COQ_MAKEFILE_FLAGS += -arg -w -arg -notation-overridden,-redundant-canonical-projection
endif
# Forward most targets to Coq makefile (with some trick to make this phony)
%: Makefile.coq phony %: Makefile.coq phony
+@make -f Makefile.coq $@ +@make -f Makefile.coq $@
# Compile this project
all: Makefile.coq all: Makefile.coq
+@make -f Makefile.coq all +@make -f Makefile.coq all
clean: Makefile.coq clean: Makefile.coq
+@make -f Makefile.coq clean +@make -f Makefile.coq clean
find \( -name "*.v.d" -o -name "*.vo" -o -name "*.aux" -o -name "*.cache" -o -name "*.glob" -o -name "*.vio" \) -print -delete
rm -f Makefile.coq rm -f Makefile.coq
# Create Coq Makefile
Makefile.coq: _CoqProject Makefile Makefile.coq: _CoqProject Makefile
coq_makefile -f _CoqProject | sed 's/$$(COQCHK) $$(COQCHKFLAGS) $$(COQLIBS)/$$(COQCHK) $$(COQCHKFLAGS) $$(subst -Q,-R,$$(COQLIBS))/' > Makefile.coq coq_makefile $(COQ_MAKEFILE_FLAGS) -f _CoqProject -o Makefile.coq.tmp
sed 's/$$(COQCHK) $$(COQCHKFLAGS) $$(COQLIBS)/$$(COQCHK) $$(COQCHKFLAGS) $$(subst -Q,-R,$$(COQLIBS))/' < Makefile.coq.tmp \
| awk '/^install:$$/{print;print "\tif [ -d \"$$(DSTROOT)\"$$(COQLIBINSTALL)/iris/ ]; then find \"$$(DSTROOT)\"$$(COQLIBINSTALL)/iris/ -name \"*.vo\" -print -delete; fi";next}1' > Makefile.coq
rm Makefile.coq.tmp
# Install build-dependencies
build-dep: build-dep:
cat opam.pins | build/opam-pins.sh cat opam.pins | build/opam-pins.sh
opam pin add coq-lambda-rust "$$(pwd)#HEAD" -k git -y -n opam pin add coq-lambda-rust "$$(pwd)#HEAD" -k git -y -n
opam install coq-lambda-rust --deps-only -y opam install coq-lambda-rust --deps-only -y
_CoqProject: ; # Phony targets (i.e. targets that should be run no matter the timestamps of the involved files)
Makefile: ;
phony: ; phony: ;
.PHONY: all clean phony
.PHONY: all clean phony iris-local iris-system
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment