aboutsummaryrefslogtreecommitdiff
path: root/Makefile.dune
diff options
context:
space:
mode:
authorEmilio Jesus Gallego Arias2019-12-09 01:32:10 +0100
committerEmilio Jesus Gallego Arias2019-12-16 10:31:45 +0100
commitbfbcd1e3feeaa7eb24c15686439926c536c5d483 (patch)
treebf97d766e395c7c9c8ffea433e19c1b2476462f1 /Makefile.dune
parent861a83842efcb536e9ffdd0ba7173621daab47a4 (diff)
[dune] Use a special directory for the boot build
This is related to and fixes #10694 in part. When calling bootstrap in an incremental build step, we must be sure the generated dune files are in place. In the CI, these won't be in place, so we must bootstrap without altering the digest and trace database coming from the artifact. Using a separate boot step to recreate the missing `dune` files works fine and takes just a few seconds.
Diffstat (limited to 'Makefile.dune')
-rw-r--r--Makefile.dune11
1 files changed, 6 insertions, 5 deletions
diff --git a/Makefile.dune b/Makefile.dune
index 19e8a770bd..bafb40d55f 100644
--- a/Makefile.dune
+++ b/Makefile.dune
@@ -11,7 +11,8 @@
# use DUNEOPT=--display=short for a more verbose build
# DUNEOPT=--display=short
-BUILD_CONTEXT=_build/default
+BOOT_DIR=_build_boot
+BOOT_CONTEXT=$(BOOT_DIR)/default
help:
@echo "Welcome to Coq's Dune-based build system. Targets are:"
@@ -45,8 +46,8 @@ plugins/ltac/dune:
@echo "(library (name ltac_plugin) (public_name coq.plugins.ltac) (modules_without_implementation extraargs extratactics))" > plugins/ltac/dune
voboot: plugins/ltac/dune
- dune build $(DUNEOPT) @vodeps
- dune exec ./tools/coq_dune.exe $(BUILD_CONTEXT)/.vfiles.d
+ dune build --build-dir=$(BOOT_DIR) $(DUNEOPT) @vodeps
+ dune exec --build-dir=$(BOOT_DIR) -- ./tools/coq_dune.exe $(BOOT_CONTEXT)/.vfiles.d
states: voboot
dune build --display=short $(DUNEOPT) dev/shim/coqtop-prelude
@@ -104,8 +105,8 @@ ocheck: voboot
ireport:
dune clean
- dune build $(DUNEOPT) @vodeps --profile=ireport
- dune exec coq_dune $(BUILD_CONTEXT)/.vfiles.d --profile=ireport
+ dune build --build-dir=$(BOOT_DIR) $(DUNEOPT) @vodeps
+ dune exec --build-dir=$(BOOT_DIR) -- ./tools/coq_dune.exe $(BOOT_CONTEXT)/.vfiles.d
dune build $(DUNEOPT) @install --profile=ireport
clean: