[m-rev.] for review: improve handling of non-installed standard library

Simon Taylor stayl at cs.mu.OZ.AU
Wed Apr 17 18:30:26 AEST 2002


Estimated hours taken: 6
Branches: main

Allow alternative locations for the standard library files 
to be specified using options to the various Mercury scripts
rather than environment variables.  This change is necessary
to allow the compiler to be compiled using `mmc --make', because
`mmc --make' does not support the environment variables.

All of the Mercury scripts now accept an option
`--mercury-standard-library-directory' to specify the installed
library to use, or `--no-mercury-standard-library-directory' to
disable the use of the installed library. The location
of the alternate files to use can then be specified
using ordinary options to the scripts.

There is a new environment variable MERCURY_STDLIB_DIR, which has
the same effect as the `--mercury-standard-library-directory' option.

scripts/parse_ml_options.sh-subr.in:
scripts/mgnuc.in:
scripts/mmc.in:
	Handle MERCURY_STDLIB_DIR and `--mercury-standard-library-directory'.

	Remove support for the MERCURY_C_INCL_DIR, MERCURY_MOD_LIB_DIRS
	and MERCURY_TRACE_LIB_DIRS environment variables -- they aren't
	used anywhere. MERCURY_C_INCL_DIR is being removed because the
	assumption it makes (that all header files are installed into
	a single directory) will not hold for much longer because the
	generated header files for hl* grades are grade dependent.

compiler/options.m:
compiler/compile_target_code.m:
	Add an option `--trace-init-file', used to specify `.init'
	files which should only be used when tracing is enabled,
	such as browser/mer_browse.init.

	Allow `--mercury-stdlib-dir' as an abbreviation for
	`--mercury-standard-library-directory'.

doc/user_guide.texi:
	Document MERCURY_STDLIB_DIR, MERCURY_TRACE_LIB_MODS
	and the `--trace-init-file' mmc option.

	Remove documentation for the no longer used MERCURY_C_INCL_DIR,
	MERCURY_MOD_LIB_DIRS, MERCURY_TRACE_LIB_DIRS and
	MERCURY_NC_BUILTIN environment variables.

Index: compiler/compile_target_code.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/compile_target_code.m,v
retrieving revision 1.4
diff -u -u -r1.4 compile_target_code.m
--- compiler/compile_target_code.m	20 Mar 2002 12:36:00 -0000	1.4
+++ compiler/compile_target_code.m	16 Apr 2002 15:53:07 -0000
@@ -695,11 +695,16 @@
 	globals__io_lookup_accumulating_option(init_files, InitFileNamesList),
 	{ join_string_list(InitFileNamesList, "", "", " ", InitFileNames) },
 
+	globals__io_lookup_accumulating_option(trace_init_files,
+		TraceInitFileNamesList),
+	{ join_string_list(TraceInitFileNamesList, "--trace-init-file ",
+		"", " ", TraceInitFileNames) },
+
 	{ TmpInitCFileName = InitCFileName ++ ".tmp" },
 	{ MkInitCmd = string__append_list(
 		["c2init --grade ", Grade, " ", TraceOpt, LinkFlags,
-		" --init-c-file ", TmpInitCFileName, " ",
-		InitFileDirs, " ", InitFileNames, " ", CFileNames]) },
+		" --init-c-file ", TmpInitCFileName, " ", InitFileDirs, " ",
+		InitFileNames, " ", TraceInitFileNames, " ", CFileNames]) },
 	invoke_shell_command(ErrorStream, verbose, MkInitCmd, MkInitOK0),
 	maybe_report_stats(Stats),
 	( { MkInitOK0 = yes } ->
Index: compiler/options.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/options.m,v
retrieving revision 1.367
diff -u -u -r1.367 options.m
--- compiler/options.m	15 Apr 2002 05:04:11 -0000	1.367
+++ compiler/options.m	17 Apr 2002 07:12:51 -0000
@@ -524,6 +524,7 @@
 		;	mercury_standard_library_directory
 		;	init_file_directories
 		;	init_files
+		;	trace_init_files
 
 			% auto-configured options.
 		;	shared_library_extension
@@ -1048,6 +1049,7 @@
 	mercury_standard_library_directory - maybe_string(no),
 	init_file_directories -		accumulating([]),
 	init_files -			accumulating([]),
+	trace_init_files -		accumulating([]),
 
 					% the `mmc' script will override the
 					% following seven defaults with a value
@@ -1620,8 +1622,10 @@
 long_option("mld",			mercury_library_directory_special).
 long_option("mercury-standard-library-directory",
 					mercury_standard_library_directory).
+long_option("mercury-stdlib-dir",	mercury_standard_library_directory).
 long_option("init-file-directory",	init_file_directories).
 long_option("init-file",		init_files).
+long_option("trace-init-file",		trace_init_files).
 long_option("shared-library-extension",	shared_library_extension).
 long_option("library-extension",	library_extension).
 long_option("executable-file-extension", executable_file_extension).
@@ -3328,8 +3332,10 @@
 		"\t`--init-file-directory' and `--c-include-directory'",
 		"\toptions as needed.",
 		"--mercury-standard-library-directory <directory>",
+		"--mercury-stdlib-dir <directory>",
 		"\tSearch <directory> for the Mercury standard library.",
 		"--no-mercury-standard-library-directory",
+		"--no-mercury-stdlib-dir",
 		"\tDon't use the Mercury standard library.",
 		"--ml <library>, --mercury-library <library>",
 		"\tLink with the specified Mercury library.",
@@ -3338,7 +3344,10 @@
 		"\tbe searched for `.init' files by c2init.",
 		"--init-file <init-file>",
 		"\tAppend <init-file> to the list of `.init' files to",
-		"\tbe passed to c2init."
+		"\tbe passed to c2init.",
+		"--trace-init-file <init-file>",
+		"\tAppend <init-file> to the list of `.init' files to",
+		"\tbe passed to c2init when tracing is enabled."
 		
 		% The --shared-library-extension,
 		% --library-extension, --executable-file-extension
Index: doc/user_guide.texi
===================================================================
RCS file: /home/mercury1/repository/mercury/doc/user_guide.texi,v
retrieving revision 1.305
diff -u -u -r1.305 user_guide.texi
--- doc/user_guide.texi	15 Apr 2002 05:04:16 -0000	1.305
+++ doc/user_guide.texi	17 Apr 2002 08:21:55 -0000
@@ -5859,11 +5859,15 @@
 Link with the specified Mercury library.  @xref{Using libraries}.
 
 @item --mercury-standard-library-directory @var{directory}
+ at itemx --mercury-stdlib-dir @var{directory}
 @findex --mercury-standard-library-directory
+ at findex --mercury-stdlib-dir
 Search @var{directory} for the Mercury standard library.
 
 @item --no-mercury-standard-library-directory
+ at itemx --no-mercury-stdlib-dir
 @findex --no-mercury-standard-library-directory
+ at findex --no-mercury-stdlib-dir
 Don't use the Mercury standard library.
 
 @item --init-file-directory @var{directory}
@@ -5876,6 +5880,11 @@
 Append @var{file} to the list of @samp{.init} files
 to be passed to @samp{c2init}.
 
+ at item --trace-init-file @var{file}
+ at findex --trace-init-file
+Append @var{file} to the list of @samp{.init} files
+to be passed to @samp{c2init} when tracing is enabled.
+
 @end table
 
 @c ----------------------------------------------------------------------------
@@ -5897,15 +5906,12 @@
 @vindex MERCURY_DEFAULT_GRADE
 The default grade to use if no @samp{--grade} option is specified.
 
- at sp 1
- at item MERCURY_C_INCL_DIR
- at vindex MERCURY_C_INCL_DIR
-Directory for the C header files for the Mercury runtime system (@file{*.h}).
-This environment variable is used
-only to define the default values of MERCURY_ALL_C_INCL_DIRS
-and MERCURY_ALL_MC_INCL_DIRS,
-so if you define those environment variables separately,
-the value of MERCURY_C_INCL_DIR is ignored.
+ at item MERCURY_STDLIB_DIR
+ at vindex MERCURY_STDLIB_DIR
+The directory containing the installed Mercury standard library.
+If the MERCURY_ALL_C_INCL_DIRS, MERCURY_ALL_MC_C_INCL_DIRS,
+MERCURY_INT_DIR, MERCURY_MOD_LIB_MODS and MERCURY_TRACE_LIB_MODS
+variables are set the value of MERCURY_STDLIB_DIR will be ignored.
 
 @sp 1
 @item MERCURY_ALL_C_INCL_DIRS
@@ -5913,7 +5919,7 @@
 A list of options for the C compiler that specifies
 all the directories the C compiler should search for the C header files
 of the Mercury runtime system and garbage collector.
-The default value of this option is @samp{-I$MERCURY_C_INCL_DIR},
+The default value of this variable is @samp{-I$MERCURY_STDLIB_DIR/inc},
 since usually all these header files are installed in one directory.
 This environment variable is used by @samp{mgnuc};
 it should generally be kept in sync with
@@ -5925,8 +5931,8 @@
 A list of options for mmc that specifies
 all the directories it should search for the C header files
 of the Mercury runtime system and garbage collector.
-The default value of this option is
- at samp{--c-include-directory $MERCURY_C_INCL_DIR},
+The default value of this variable is
+ at samp{--c-include-directory $MERCURY_STDLIB_DIR/inc},
 since usually all these header files are installed in one directory.
 This environment variable is used by @samp{mmc};
 it should generally be kept in sync with
@@ -5939,11 +5945,6 @@
 files (@file{*.int}, @file{*.int2}, @file{*.int3} and @file{*.opt}).
 
 @sp 1
- at item MERCURY_NC_BUILTIN
- at vindex MERCURY_NC_BUILTIN
-Filename of the Mercury `nc'-compatibility file (nc_builtin.nl).
-
- at sp 1
 @item MERCURY_C_LIB_DIR
 @vindex MERCURY_C_LIB_DIR
 Base directory containing the Mercury libraries (@file{libmer_*.a} and
@@ -5959,16 +5960,14 @@
 @samp{-mno-abicalls}.  See the file @samp{README.IRIX-5} in the Mercury
 source distribution.
 
- at sp 1
- at item MERCURY_MOD_LIB_DIR
- at vindex MERCURY_MOD_LIB_DIR
-The directory containing the .init files in the Mercury library.
-They are used to create the initialization file @file{*_init.c}.
-
- at sp 1
 @item MERCURY_MOD_LIB_MODS
 @vindex MERCURY_MOD_LIB_MODS
 The names of the .init files in the Mercury library.
+
+ at item MERCURY_TRACE_LIB_MODS
+ at vindex MERCURY_TRACE_LIB_MODS
+The names of the .init files in the Mercury library which should
+only be used when tracing is enabled.
 
 @sp 1
 @item MERCURY_COMPILER
Index: scripts/c2init.in
===================================================================
RCS file: /home/mercury1/repository/mercury/scripts/c2init.in,v
retrieving revision 1.35
diff -u -u -r1.35 c2init.in
--- scripts/c2init.in	13 Jan 2002 10:13:12 -0000	1.35
+++ scripts/c2init.in	17 Apr 2002 06:28:37 -0000
@@ -33,8 +33,6 @@
 TRACE_LIB_NAME=mer_trace
 BROWSER_LIB_NAME=mer_browser
 
-MERCURY_MOD_LIB_DIR=${MERCURY_MOD_LIB_DIR=@LIBDIR@/modules}
-MERCURY_TRACE_LIB_DIR=${MERCURY_TRACE_LIB_DIR=@LIBDIR@/modules}
 MKINIT=${MERCURY_MKINIT=mkinit}
 
 case $require_tracing in
@@ -47,12 +45,15 @@
 		init_opt="-i" ;;
 esac
 
-MERCURY_MOD_LIB_MODS=${MERCURY_MOD_LIB_MODS="\
-		$MERCURY_MOD_LIB_DIR/$RT_LIB_NAME.init \
-		$MERCURY_MOD_LIB_DIR/$STD_LIB_NAME.init"}
-
-MERCURY_TRACE_LIB_MODS=${MERCURY_TRACE_LIB_MODS="\
-		$MERCURY_TRACE_LIB_DIR/$BROWSER_LIB_NAME.init"}
+if [ "$mercury_stdlib_dir" != "" ]
+then
+	MERCURY_MOD_LIB_MODS=${MERCURY_MOD_LIB_MODS="\
+			$mercury_stdlib_dir/modules/$RT_LIB_NAME.init \
+			$mercury_stdlib_dir/modules/$STD_LIB_NAME.init"}
+	MERCURY_TRACE_LIB_MODS=${MERCURY_TRACE_LIB_MODS="\
+			$mercury_stdlib_dir/modules/$BROWSER_LIB_NAME.init"}
+fi
+MERCURY_TRACE_LIB_MODS="$MERCURY_TRACE_LIB_MODS $trace_init_files"
 
 case "$trace_opt" in
 	-t)
@@ -69,11 +70,13 @@
 	0) exec $MKINIT $aditi_opt -c"$maxcalls" $init_opt $trace_opt \
 		$library_opt $defentry_opt $extra_inits_opt \
 		-g "$GRADE" -o "$init_c_file" \
-		$extra_init_dirs $EXTRA_INIT_FILES $MERCURY_ALL_LIB_MODS
+		$extra_init_dirs $EXTRA_INIT_FILES $TRACE_INIT_FILES \
+		$MERCURY_ALL_LIB_MODS
 	   ;;
 	*) exec $MKINIT $aditi_opt -c"$maxcalls" $init_opt $trace_opt \
 		$library_opt $defentry_opt $extra_inits_opt \
 		-g "$GRADE" -o "$init_c_file" -r "$runtime_flags" \
-		$extra_init_dirs "$@" $EXTRA_INIT_FILES $MERCURY_ALL_LIB_MODS
+		$extra_init_dirs "$@" $EXTRA_INIT_FILES $TRACE_INIT_FILES \
+		$MERCURY_ALL_LIB_MODS
 	   ;;
 esac
Index: scripts/mgnuc.in
===================================================================
RCS file: /home/mercury1/repository/mercury/scripts/mgnuc.in,v
retrieving revision 1.85
diff -u -u -r1.85 mgnuc.in
--- scripts/mgnuc.in	23 Feb 2002 03:47:23 -0000	1.85
+++ scripts/mgnuc.in	17 Apr 2002 06:38:51 -0000
@@ -17,10 +17,6 @@
 
 FULLARCH=@FULLARCH@
 NONSHARED_LIB_DIR=${MERCURY_NONSHARED_LIB_DIR=@NONSHARED_LIB_DIR@}
-MERC_C_INCL_DIR=${MERCURY_C_INCL_DIR=@LIBDIR@/inc}
-MERC_ALL_C_INCL_DIRS=${MERCURY_ALL_C_INCL_DIRS=-I$MERC_C_INCL_DIR}
-LOCAL_C_INCL_DIR=${MERCURY_LOCAL_C_INCL_DIR=/usr/local/include}
-ALL_LOCAL_C_INCL_DIRS=${MERCURY_ALL_LOCAL_C_INCL_DIRS=-I$LOCAL_C_INCL_DIR}
 
 DEFAULT_GRADE=${MERCURY_DEFAULT_GRADE=@DEFAULT_GRADE@}
 CC=${MERCURY_C_COMPILER="@CC@"}
@@ -88,6 +84,7 @@
 c_optimize=true
 use_activation_counts=false
 preserve_tail_recursion=true
+mercury_stdlib_dir=${MERCURY_STDLIB_DIR=@LIBDIR@}
 
 # include the file `init_grade_options.sh-subr'
 @INIT_GRADE_OPTIONS@
@@ -117,6 +114,12 @@
 	--split-c-files
 		This option must be specified if the argument C files were
 		generated by the Mercury compiler with --split-c-files.
+	--mercury-standard-library-directory <directory>
+	--mercury-stdlib-dir <directory>
+		The directory containing the installed Mercury standard
+		library.
+	--no-mercury-standard-library-directory, --no-mercury-stdlib-dir
+		Don't use an installed Mercury standard library.
 
 $grade_usage
 		
@@ -127,7 +130,7 @@
 	but this can be changed using the \`--no-ansi' or \`--no-check'
 	options.
 Environment variables:
-	MERCURY_C_INCL_DIR, MERCURY_ALL_C_INCL_DIRS, MERCURY_DEFAULT_GRADE.
+	MERCURY_ALL_C_INCL_DIRS, MERCURY_DEFAULT_GRADE.
 "
 
 while : ; do
@@ -192,6 +195,13 @@
 	--no-preserve-tail-recursion)
 		preserve_tail_recursion=false ;;
 
+	--mercury-standard-library-directory|--mercury-stdlib-dir)
+		mercury_stdlib_dir="$2"
+		shift
+		;;
+	--no-mercury-standard-library-directory|--no-mercury-stdlib-dir)
+		unset mercury_stdlib_dir ;;
+
 	# include the file `parse_grade_options.sh-subr'
 	@PARSE_GRADE_OPTIONS@
 
@@ -208,6 +218,14 @@
 
 # include the file `final_grade_options.sh-subr'
 @FINAL_GRADE_OPTIONS@
+
+case "$mercury_stdlib_dir" in
+    "")	MERC_ALL_C_INCL_DIRS=$MERCURY_ALL_C_INCL_DIRS ;;
+    *)	MERC_ALL_C_INCL_DIRS=${MERCURY_ALL_C_INCL_DIRS="-I$mercury_stdlib_dir/inc"} ;;
+esac
+
+LOCAL_C_INCL_DIR=${MERCURY_LOCAL_C_INCL_DIR=/usr/local/include}
+ALL_LOCAL_C_INCL_DIRS=${MERCURY_ALL_LOCAL_C_INCL_DIRS=-I$LOCAL_C_INCL_DIR}
 
 #
 # convert non-grade mgnuc options into gcc options
Index: scripts/ml.in
===================================================================
RCS file: /home/mercury1/repository/mercury/scripts/ml.in,v
retrieving revision 1.94
diff -u -u -r1.94 ml.in
--- scripts/ml.in	7 Feb 2002 03:11:00 -0000	1.94
+++ scripts/ml.in	17 Apr 2002 06:33:08 -0000
@@ -26,9 +26,6 @@
 
 
 NONSHARED_LIB_DIR=${MERCURY_NONSHARED_LIB_DIR=@NONSHARED_LIB_DIR@}
-DEFAULT_LIBDIR=@LIBDIR@/lib
-LIBDIR=${MERCURY_C_LIB_DIR=$DEFAULT_LIBDIR}
-# DEMANGLER=${MERCURY_DEMANGLER=@LIBDIR@/bin/@FULLARCH@/mdemangle}
 DEMANGLER=${MERCURY_DEMANGLER=mdemangle}
 CC=${MERCURY_C_COMPILER="@CC@"}
 MKFIFO=${MERCURY_MKFIFO="@MKFIFO@"}
@@ -97,6 +94,11 @@
 case $require_tracing in
 	true)	trace=true ;;
 	false)	;;
+esac
+
+case "$mercury_stdlib_dir" in
+    "")	LIBDIR=$MERCURY_C_LIB_DIR ;;
+    *)	LIBDIR=${MERCURY_C_LIB_DIR=$mercury_stdlib_dir/lib} ;;
 esac
 
 # If you haven't set mercury_libs, set it to the default value
Index: scripts/mmc.in
===================================================================
RCS file: /home/mercury1/repository/mercury/scripts/mmc.in,v
retrieving revision 1.23
diff -u -u -r1.23 mmc.in
--- scripts/mmc.in	7 Apr 2002 13:41:49 -0000	1.23
+++ scripts/mmc.in	17 Apr 2002 08:25:12 -0000
@@ -10,15 +10,22 @@
 #
 # Use `mmc -h' for help.
 #
-# Environment variables: MERCURY_INT_DIR, MERCURY_C_INCL_DIR,
-# MERCURY_ALL_MC_C_INCL_DIRS,
-# MERCURY_COMPILER, MERCURY_C_COMPILER,
+# Environment variables: MERCURY_STDLIB_DIR, MERCURY_INT_DIR,
+# MERCURY_ALL_MC_C_INCL_DIRS, MERCURY_COMPILER, MERCURY_C_COMPILER,
 # MERCURY_DEFAULT_GRADE, MERCURY_DEFAULT_OPT_LEVEL.
 
-MERC_C_INCL_DIR=${MERCURY_C_INCL_DIR=@LIBDIR@/inc}
-MERC_ALL_MC_C_INCL_DIRS=${MERCURY_ALL_MC_C_INCL_DIRS="--c-include-directory $MERC_C_INCL_DIR"}
 MC=${MERCURY_COMPILER="@LIBDIR@/bin/@FULLARCH@/mercury_compile"}
-INTDIR=${MERCURY_INT_DIR=@LIBDIR@/ints}
+case "$MERCURY_INT_DIR" in
+    "")
+	INT_DIR_OPT=
+	STDLIB_DIR=${MERCURY_STDLIB_DIR=@LIBDIR@}
+	STDLIB_DIR_OPT="--mercury-standard-library-directory \"${STDLIB_DIR}\""
+	;;
+    *)
+	INT_DIR_OPT="-I $MERCURY_INT_DIR"
+	STDLIB_DIR_OPT=--no-mercury-standard-library-directory
+	;;
+esac
 
 # The default options settings are passed in the DEFAULT_MCFLAGS enviroment
 # variable, rather than on the command line, so that they can be overridden
@@ -27,7 +34,7 @@
 # The default optimization level should be after
 # all the options that describe the machine configuration.
 DEFAULT_MCFLAGS="\
-		$MERC_ALL_MC_C_INCL_DIRS \
+		$MERCURY_ALL_MC_C_INCL_DIRS \
 		--cc \"${MERCURY_C_COMPILER=@CC@}\" \
 		--grade \"${MERCURY_DEFAULT_GRADE=@DEFAULT_GRADE@}\" \
 		--cflags-for-threads \"@CFLAGS_FOR_THREADS@\" \
@@ -46,11 +53,12 @@
 		@HAVE_DELAY_SLOT@ \
 		@HAVE_BOXED_FLOATS@ \
 		${MERCURY_DEFAULT_OPT_LEVEL=-O2} \
+		$STDLIB_DIR_OPT
 		"
 export DEFAULT_MCFLAGS
 
 case $# in
-	0) exec $MC -I "$INTDIR" ;;
-	*) exec $MC "$@" -I "$INTDIR" ;;
+	0) exec $MC $INT_DIR_OPT ;;
+	*) exec $MC "$@" $INT_DIR_OPT ;;
 esac
 
Index: scripts/parse_ml_options.sh-subr.in
===================================================================
RCS file: /home/mercury1/repository/mercury/scripts/parse_ml_options.sh-subr.in,v
retrieving revision 1.4
diff -u -u -r1.4 parse_ml_options.sh-subr.in
--- scripts/parse_ml_options.sh-subr.in	7 Feb 2002 03:11:00 -0000	1.4
+++ scripts/parse_ml_options.sh-subr.in	17 Apr 2002 08:25:30 -0000
@@ -16,6 +16,9 @@
 # The invoking script must also define FULLARCH and DEFAULT_GRADE.
 #---------------------------------------------------------------------------#
 
+# initialize common options
+mercury_stdlib_dir=${MERCURY_STDLIB_DIR=@LIBDIR@}
+
 # initialize ml options
 verbose=false
 allow_undef=false
@@ -55,6 +58,7 @@
 extra_inits_opt=""
 aditi_opt=""
 extra_init_dirs=""
+trace_init_files=""
 init_c_file="-"
 runtime_flags=""
 
@@ -115,6 +119,11 @@
 		Produce a shared library, rather than an executable.
 
 Directory options:
+	--mercury-standard-library-directory <directory>
+	--mercury-stdlib-dir <directory>
+		The directory in which to find the Mercury standard library.
+	--no-mercury-standard-library-directory, --no-mercury-stdlib-dir
+		Same as \`--mercury-libs none'.
 	-L <directory>, --lib-dir <directory>
 		Include <directory> in the list of directories that the
 		linker will use to search for libraries.
@@ -191,8 +200,7 @@
 Environment variables:
 		MERCURY_DEFAULT_GRADE, MERCURY_C_COMPILER,
 		MERCURY_C_LIB_DIR, MERCURY_NONSHARED_LIB_DIR,
-		MERCURY_MOD_LIB_DIR, MERCURY_MOD_LIB_MODS,
-		MERCURY_TRACE_LIB_DIR, MERCURY_TRACE_LIB_MODS,
+		MERCURY_MOD_LIB_MODS, MERCURY_TRACE_LIB_MODS,
 		MERCURY_MKINIT."
 
 # The following options are not generally useful, so they are not documented:
@@ -270,9 +278,13 @@
 		;;
 	--mercury-libs)
 		case "$2" in
-			shared|static|none|default)
+			shared|static|default)
 				mercury_libs="$2"
 				shift ;;
+			none)
+				mercury_libs=none
+				unset mercury_stdlib_dir
+				shift ;;
 			*)
 				progname=`basename $0`
 				cat 1>&2 << EOF
@@ -296,6 +308,16 @@
 			mercury_libs=static ;;
 		esac
 		;;
+
+	--mercury-standard-library-directory|--mercury-stdlib-dir)
+		mercury_stdlib_dir="$2"
+		shift
+		;;
+	--no-mercury-standard-library-directory|--no-mercury-stdlib-dir)
+		mercury_libs=none
+		unset mercury_stdlib_dir
+		;;
+
 	-L|--lib-dir)
 		dir="$2"
 		user_libdir_opts="$user_libdir_opts @LIB_LIBPATH@$dir"
@@ -387,9 +409,12 @@
 
 	-I|--init-file-directory)
 		extra_init_dirs="$extra_init_dirs -I $2"; shift;;
-	
+
 	--init-c-file)
 		init_c_file="$2"; shift;;
+
+	--trace-init-file)
+		trace_init_files="$trace_init_files $2"; shift;;
 
 	--runtime-flags)
 		runtime_flags="$runtime_flags $2"; shift;;
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list