From c4fc3d3d4bcad5fd6dbca6f55dffd20580006f35 Mon Sep 17 00:00:00 2001 From: letouzey Date: Mon, 16 Mar 2009 13:41:47 +0000 Subject: Makefile: fix ignored errors, several attempts to clarify things * I encountered error messages during compilation, for instance ocamlopt complaining about non-existing coq_config.cmi when compiling coq_config.ml. Moreover, make was _not_ stopping at these errors (WTF?!). After some debug, it turned out to be (indirectly) my fault: I placed earlier the inclusion of the new .mllib.d in Makefile.stage1, but this is too early, coqdep, which is used to compute these files, isn't built yet. Due to the semantics of "-include", make tries to build it, fails with the above error, and goes on happily. Arrgh. After moving the inclusion of these .mllib.d to Makefile.stage2, everything seems to work ok now. * Since we're using such "nice" non-trivial features of make, I've started a small FAQ section about them at the beginning of Makefile * Recursive calls to make are now done with two options: --no-builtin-rules : let's avoid builtin rules like "%:%.o" ... --warn-undefined-variable : using a non-defined variable isn't necessarily bad, but I found a few bugs with this option, and I suggest we keep it. * Clarified the rules about stage* in Makefile and their STAGE*_TARGETS variables in Makefile.common. Now a newcomer _might_ have a chance to grasp in less than a day what's going on ... git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@11983 85f007b7-540e-0410-9357-904b9bb8a0f7 --- Makefile.stage2 | 2 ++ 1 file changed, 2 insertions(+) (limited to 'Makefile.stage2') diff --git a/Makefile.stage2 b/Makefile.stage2 index 6fe020be9f..81e192cfc0 100644 --- a/Makefile.stage2 +++ b/Makefile.stage2 @@ -8,6 +8,8 @@ include Makefile.stage1 +-include $(MLLIBFILES:.mllib=.mllib.d) +.SECONDARY: $(MLLIBFILES:.mli=.mllib.d) -include $(ML4FILES:.ml4=.ml4.ml.d) .SECONDARY: $(ML4FILES:.ml4=.ml4.ml.d) -- cgit v1.2.3