summaryrefslogtreecommitdiff
path: root/Makefile.menhir
diff options
context:
space:
mode:
authorGabriel Scherer <gabriel.scherer@gmail.com>2018-12-08 16:19:06 +0100
committerGabriel Scherer <gabriel.scherer@gmail.com>2018-12-12 09:30:55 +0100
commit46ef054330be5d0759a68ce9ee2bcc01e31edd39 (patch)
treececee98f07cdaa539488fd937e4151a19e4e4520 /Makefile.menhir
parent9cabb9fa547c8f2c5988de4e4b8d8dc6edac200b (diff)
downloadocaml-46ef054330be5d0759a68ce9ee2bcc01e31edd39.tar.gz
Makefiles: restructure CAMLDEP usage to easily add flags
This change should be a refactoring no-op. Before, a DEPFLAGS variable existed in some makefiles to contain include directories to be passed to ocamldep invocations, but no support for easily adding command-line flags to ocamldep was available (invocations would systematically use -slash, which was duplicated across callsites). With this PR, a new DEPINCLUDES variable contains the include directories, and DEPFLAGS is repurposed to contain other command-line flags for the tool -- currently "slash".
Diffstat (limited to 'Makefile.menhir')
-rw-r--r--Makefile.menhir6
1 files changed, 3 insertions, 3 deletions
diff --git a/Makefile.menhir b/Makefile.menhir
index 16ab2b1fe6..31a24c49f0 100644
--- a/Makefile.menhir
+++ b/Makefile.menhir
@@ -139,10 +139,10 @@ clean-menhir: partialclean-menhir
.PHONY: depend-menhir
depend-menhir:
- $(MENHIR) --depend --ocamldep "$(CAMLDEP) -slash $(DEPFLAGS)" \
+ $(MENHIR) --depend --ocamldep "$(CAMLDEP) $(DEPFLAGS) $(DEPINCLUDES)" \
parsing/parser.mly > .depend.menhir
-# this rule depends on the variables CAMLDEP and DEPFLAGS
-# define in Makefile, so it can only be invoked from the main Makefile
+# this rule depends on the variables CAMLDEP, DEPFLAGS, DEPINCLUDES
+# defined in Makefile, so it can only be invoked from the main Makefile
include .depend.menhir