diff: pass MCFLAGS etc. down to recursive mmakes
Fergus Henderson
fjh at cs.mu.OZ.AU
Fri Oct 30 03:25:18 AEDT 1998
Estimated hours taken: 0.5
Fix a bug reported by Renaud Paquay <rpa at miscrit.be>.
compiler/modules.m:
scripts/Mmake.rules:
When invoking Mmake recursively, pass down the values of
MC and ALL_MCFLAGS, in case their values were overridden
on the command line.
Index: compiler/modules.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/modules.m,v
retrieving revision 1.89
diff -u -r1.89 modules.m
--- modules.m 1998/10/29 09:19:56 1.89
+++ modules.m 1998/10/29 16:09:08
@@ -1559,6 +1559,8 @@
"ifneq ($(RM_C),:)\n",
ObjFileName, " : ", SourceFileName, "\n",
"\t$(MMAKE_MAKE_CMD) $(MFLAGS) ",
+ "MC=""$(MC)"" ",
+ "ALL_MCFLAGS=""$(ALL_MCFLAGS)"" ",
"ALL_GRADEFLAGS=""$(ALL_GRADEFLAGS)"" ",
CFileName, "\n",
"\t$(MGNUC) $(ALL_GRADEFLAGS) ",
@@ -1567,6 +1569,8 @@
"\t$(RM_C) ", CFileName, "\n",
PicObjFileName, " : ", SourceFileName, "\n",
"\t$(MMAKE_MAKE_CMD) $(MFLAGS) ",
+ "MC=""$(MC)"" ",
+ "ALL_MCFLAGS=""$(ALL_MCFLAGS)"" ",
"ALL_GRADEFLAGS=""$(ALL_GRADEFLAGS)"" ",
CFileName, "\n",
"\t$(MGNUC) $(ALL_GRADEFLAGS) ",
Index: scripts/Mmake.rules
===================================================================
RCS file: /home/mercury1/repository/mercury/scripts/Mmake.rules,v
retrieving revision 1.64
diff -u -r1.64 Mmake.rules
--- Mmake.rules 1998/08/04 14:06:05 1.64
+++ Mmake.rules 1998/10/29 16:11:47
@@ -179,14 +179,14 @@
ifneq ($(RM_C),:)
$(os_subdir)%.o : %.m
- $(MMAKE_MAKE_CMD) $(MFLAGS) GRADEFLAGS="$(GRADEFLAGS)" \
- EXTRA_GRADEFLAGS="$(EXTRA_GRADEFLAGS)" $(cs_subdir)$*.c
+ $(MMAKE_MAKE_CMD) $(MFLAGS) MC="$(MC)" ALL_MCFLAGS="$(ALL_MCFLAGS)" \
+ ALL_GRADEFLAGS="$(ALL_GRADEFLAGS)" $(cs_subdir)$*.c
$(MGNUC) $(ALL_GRADEFLAGS) $(ALL_MGNUCFLAGS) -c $(cs_subdir)$*.c -o $@
$(RM_C) $(cs_subdir)$*.c
$(os_subdir)%.pic_o : %.m
- $(MMAKE_MAKE_CMD) $(MFLAGS) GRADEFLAGS="$(GRADEFLAGS)" \
- EXTRA_GRADEFLAGS="$(EXTRA_GRADEFLAGS)" $(cs_subdir)$*.c
+ $(MMAKE_MAKE_CMD) $(MFLAGS) MC="$(MC)" ALL_MCFLAGS="$(ALL_MCFLAGS") \
+ ALL_GRADEFLAGS="$(ALL_GRADEFLAGS)" $(cs_subdir)$*.c
$(MGNUC) $(ALL_GRADEFLAGS) $(ALL_MGNUCFLAGS) $(CFLAGS_FOR_PIC) \
-c $(cs_subdir)$*.c -o $@
--
Fergus Henderson <fjh at cs.mu.oz.au> | "I have always known that the pursuit
WWW: <http://www.cs.mu.oz.au/~fjh> | of excellence is a lethal habit"
PGP: finger fjh at 128.250.37.3 | -- the last words of T. S. Garp.
More information about the developers
mailing list