[m-rev.] diff: avoid duplicate entries in slice dir _init.c files

Julien Fischer juliensf at csse.unimelb.edu.au
Tue Jun 12 18:45:18 AEST 2007


Estimated hours taken: 1
Branches: main

Avoid duplicate entries in slice directory _init.c files.

slice/Mmakefile:
 	Avoid duplicate entries in the _init.c files in the slice directory
 	in debugging grades by making sure that mkinit only includes
 	the modules from the mdbcomp library once.  They are currently
 	included twice because we copy the mdbcomp modules into the slice
 	directory and also tell c2init to include mer_mdbcomp.init.

Julien.

Index: Mmakefile
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/slice/Mmakefile,v
retrieving revision 1.10
diff -u -r1.10 Mmakefile
--- Mmakefile	7 Dec 2006 05:10:38 -0000	1.10
+++ Mmakefile	12 Jun 2007 08:43:57 -0000
@@ -10,6 +10,18 @@
  LINK_STATIC=yes
  include $(MERCURY_DIR)/Mmake.common

+#----------------------------------------------------------------------------#
+
+# Override some settings from ../Mmake.workspace so that in debugging grades
+# we do not include mer_mdbcomp.init when creating the _init.c files in
+# this directory.  We copy the mdbcomp modules into this directory so if we
+# do include mer_mdbcomp.init we will end up with duplicate entries in the
+# _init.c files.
+
+C2INITFLAGS = --trace-init-file $(BROWSER_DIR)/$(BROWSER_LIB_NAME).init
+
+#----------------------------------------------------------------------------#
+
  -include Mmake.slice.params

  # Override the default rule in `mmake --use-mmc-make' that asks `mmc' to

--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list