aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Maxime Dénès <mail@maximedenes.fr>2017-08-12 17:28:39 +0200
committerGravatar Maxime Dénès <mail@maximedenes.fr>2017-08-12 17:28:39 +0200
commit83e506e9a4b8140320e8f505b9ef6e4da05d710c (patch)
tree70ed458e4a3f43b8dc6980f8d53d39022eb08606
parent1f46ff6db53c2ca471d9ea067d0824755b2f34da (diff)
parentfaad4bf4bfacc308b1e93fe8e16ac55d5b8b718f (diff)
Merge PR #963: fix coq_makefile
-rw-r--r--tools/CoqMakefile.in2
-rw-r--r--tools/coq_makefile.ml6
2 files changed, 6 insertions, 2 deletions
diff --git a/tools/CoqMakefile.in b/tools/CoqMakefile.in
index e54ea45d4..3a8ca7b8d 100644
--- a/tools/CoqMakefile.in
+++ b/tools/CoqMakefile.in
@@ -170,7 +170,7 @@ COQMAKEFILE_VERSION:=@COQ_VERSION@
COQSRCLIBS?= $(foreach d,$(COQ_SRC_SUBDIRS), -I "$(COQLIB)$(d)")
-CAMLFLAGS=$(OCAMLLIBS) $(COQSRCLIBS) -I $(CAMLP4LIB)
+CAMLFLAGS=$(OCAMLLIBS) $(COQSRCLIBS) -I $(CAMLP4LIB) $(OCAML_API_FLAGS)
CAMLLIB:=$(shell "$(OCAMLFIND)" printconf stdlib)
diff --git a/tools/coq_makefile.ml b/tools/coq_makefile.ml
index 327f53520..0f38d1938 100644
--- a/tools/coq_makefile.ml
+++ b/tools/coq_makefile.ml
@@ -203,8 +203,12 @@ let generate_conf_coq_config oc args bypass_API =
section oc "Coq configuration.";
let src_dirs = if bypass_API
then Coq_config.all_src_dirs
- else Coq_config.api_dirs @ Coq_config.plugins_dirs @ ["-open API"] in
+ else Coq_config.api_dirs @ Coq_config.plugins_dirs in
Envars.print_config ~prefix_var_name:"COQMF_" oc src_dirs;
+ if bypass_API then
+ Printf.fprintf oc "OCAML_API_FLAGS=\n"
+ else
+ Printf.fprintf oc "OCAML_API_FLAGS=-open API\n";
fprintf oc "COQMF_WINDRIVE=%s\n" (windrive Coq_config.coqlib)
;;