diff options
Diffstat (limited to 'Makefile.build')
-rw-r--r-- | Makefile.build | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/Makefile.build b/Makefile.build index bae04da3c..0c14f2354 100644 --- a/Makefile.build +++ b/Makefile.build @@ -36,10 +36,12 @@ endif # of include, and they will then be automatically deleted, leading to an # infinite loop. -ALLDEPS=$(addsuffix .d, \ +MLFILES:=$(MLSTATICFILES) $(MLEXTRAFILES) + +ALLDEPS:=$(addsuffix .d, \ $(ML4FILES) $(MLFILES) $(MLIFILES) $(CFILES) $(MLLIBFILES) $(VFILES)) -.SECONDARY: $(ALLDEPS) $(GENFILES) $(GENML4FILES) +.SECONDARY: $(ALLDEPS) $(GENFILES) $(ML4FILES:.ml4=.ml) # NOTA: the -include below will lauch the build of all .d. Some of them # will _fail_ at first, this is to be expected (no grammar.cma initially). @@ -839,6 +841,12 @@ COND_OPTFLAGS= \ HACKMLI = $(if $(wildcard $<i),,-intf-suffix .cmi) +define diff + $(strip $(foreach f, $(1), $(if $(filter $(f),$(2)),,$f))) +endef + +MLWITHOUTMLI := $(call diff, $(MLFILES), $(MLIFILES:.mli=.ml)) + $(MLWITHOUTMLI:.ml=.cmx): %.cmx: %.cmi # for .ml with .mli this is already the case $(MLWITHOUTMLI:.ml=.cmi): %.cmi: %.cmo |