As we discussed, it has fallen into disuse. Its main purpose was to
pave the way for the .net backend and later for the java and csharp grades.
Now that the .net backend is ancient history and the java and csharp grades
are established, that purpose is gone, and for every other purpose,
hlc is better because it is simpler and faster.
compiler/options.m:
Delete the --high-level-data option. It is no longer needed,
bacause the data representation scheme is now a direct function
of the target language.
doc/user_guide.texi:
Delete references to the --high-level-data option.
NEWS:
Mention that --high-level-data is no longer supported.
compiler/compute_grade.m:
Delete references to the hl grade component, and conform
to the deletion of the --high-level-data option.
compiler/compile_target_code.m:
Give some predicates more meaningful names, and conform to the
deletion of the --high-level-data option.
compiler/const_struct.m:
compiler/du_type_layout.m:
compiler/globals.m:
compiler/handle_options.m:
compiler/lco.m:
compiler/mercury_compile_main.m:
compiler/ml_gen_info.m:
compiler/ml_type_gen.m:
compiler/ml_unify_gen_construct.m:
compiler/mlds_to_c_data.m:
compiler/mlds_to_c_func.m:
compiler/mlds_to_c_type.m:
compiler/mlds_to_c_util.m:
Conform to the deletion of the --high-level-data option.
grade_lib/grade_spec.m:
grade_lib/grade_vars.m:
Delete the datarep solver variable, since the data representation
is now a direct function of the target language.
Delete the requirements involving the deleted solver variable.
grade_lib/grade_structure.m:
Delete the datarep component of the representation of MLDS C grades,
since its value would now be fixed.
grade_lib/grade_solver.m:
grade_lib/grade_string.m:
grade_lib/try_all_grade_structs.m:
grade_lib/var_value_names.m:
Conform to the changes above.
grade_lib/Mmakefile:
Link the grade library's test programs statically, like we do
the executables in the other directories.
library/io.m:
library/robdd.m:
library/rtti_implementation.m:
runtime/mercury_conf_param.h:
runtime/mercury_grade.h:
runtime/mercury_hlc_types.h:
Remove references to MR_HIGHLEVEL_DATA, as well as any code
that was guarded by #ifdef MR_HIGHLEVEL_DATA.
scripts/Mmake.vars.in:
scripts/canonical_grade.sh-subr:
scripts/final_grade_options.sh-subr:
scripts/init_grade_options.sh-subr:
scripts/mgnuc.in:
scripts/mgnuc_file_opts.sh-subr:
scripts/mmake.in:
scripts/mmc.in:
scripts/mtc:
scripts/parse_grade_options.sh-subr:
scripts/parse_ml_options.sh-subr.in:
Remove references to --high-level-data options.
In canonical_grade.sh-subr, compute the base grade more directly.
Remove a few left-over references to the assembler backend.
Add or fix vim modelines where relevant.
Fix inconsistent indentation.
Add missing ;;s in case statements.
Switch to using ${var} references instead of just $var.
tests/invalid/Mercury.options:
Make the test_feature_set test case run in grade java instead of hl.gc.
tests/invalid/test_feature_set.err_exp:
Update the expected out for the grade change.
Specifically, when the environment variable is nonempty, pass the debugging
flag -d to make.
Also, bring this script up to date with our current programming style,
including 4-space indentation.
Estimated hours taken: 0.3
Branches: main
scripts/mmake.in:
Fix a bug introduced by Peter where the command `mmake <target>' just
hangs if there is no Mmakefile. The problem was that cat was being
called with no arguments, causing it to wait for input from stdin.
Estimated hours taken: 0.1
Branches: main
scripts/mmake.in:
Move the dvs back to their original position before
the Mmakefile as the Mmakefiles in the compiler depend on this.
"Recursive make considered harmful".
This consists of two parts, giving mmake the optional ability to ignore
the .d files in the current directory. The second part is adding
support to the compiler to write out just the .d file.
We may need to ignore the .d files in the current directory because we
may have included that file from another directory and we don't want to
define rules twice.
scripts/mmake.in:
scripts/Mmake.vars.in:
If the mmake variable MMAKE_AUTO_INCLUDE_DS is set to no then
don't include the rules defined in the .d files in the current
directory.
compiler/mercury_compile.m:
Add support for the --generate-dependency-file flag which just
writes out the .d file for a module and then stops.
compiler/options.m:
Add the generate_dependency_file option.
compiler/mercury_compile.m:
compiler/add_type.m:
compiler/handle_options.m:
Make sure that generate_dependency_file implies that we don't
need to build/link anything.
doc/user_guide.texi:
Document the --generate-dependency-file flag.
Estimated hours taken: 2
Fix the -f mmake option. Previously `mmake install' would ignore this option
when compiling different grades in the temporary directory.
scripts/mmake.in:
Export a MMAKEFILE variable which stores the Mmakefile being used.
This causes child calls to mmake to use the same Mmakefile if no
-f option is given to the child calls.
Estimated hours taken: 3
Branches: main
Fix linking error for hlc.par.gc grade on Darwin. The problem was that the
"-undefined suppress" option is not allowed with two level namespaces.
The solution is to use "-undefined dynamic_lookup" instead.
However this means the MACOSX_DEPLOYMENT_TARGET environment variable must be
set to 10.3 since this feature will not work on Mac OS < 10.3. To allow
hlc.gc.par to be built on Mac 10.3, but targetted for Mac OS 10.0 - 10.2 add
a configuration option to force the use of flat namespaces (the
"-undefined suppress" option may be used with flat namespaces).
configure.in
Add --enable-darwin-flat-namespace option. This is the default
for Mac OS < 10.3. For Mac OS 10.3 two level namespaces are used
unless this option is given.
Set a variable to cause the MACOSX_DEPLOYMENT_TARGET environment
variable to be set if two level namespaces are being used.
scripts/mmake.in
scripts/ml.in
scripts/mmc.in
Set the MACOSX_DEPLOYMENT_TARGET environment variable wherever the
linker may be called.
Estimated hours taken: 1
Branches: main
Add the option `--file' to mmake. This allows the user
to specify the name of the file that mmake uses as the Mmakefile.
This can be useful when porting programs between systems
and experimenting with different configurations, particularly
when the programs are not under the control of autoconf.
The option `--file' may be abbreviated to `-f'. If a file
is specified via `--file' then it will be used in preference to
any file in the current directory named Mmakefile or Mmake.
Unlike GNU make using multiple instances of `--file' will
not cause mmake to jointly use all of the specified files.
Instead it will use the last one specified and ignore the
others.
scripts/mmake.in:
Add the `--file' option to mmake.
Estimated hours taken: 20
Branches: main
Allow reconfiguration of existing installations, for example
to use a different C compiler. The reconfiguration works
by making a new copy of the scripts and mercury_conf.h,
and storing them in a partial installation directory tree
which uses the libraries and executables from the existing
installation.
Use this method to configure binary distributions, rather
than using a cut down version of the configuration script,
to avoid code duplication and to handle the case where the
C compiler in use on the installation machine is different
than that used to build the binary distribution.
This is more robust than the previous method of using a different
C compiler, which was to set the MERCURY_C_COMPILER variable and
hope the different C compilers were compatible enough.
Mmakefile:
runtime/Mmakefile:
scripts/Mmakefile:
Modify the `install' targets to store files needed to create
a new configuration in $INSTALL_LIBDIR/reconf.
runtime/Mmakefile:
Install mercury_conf.h in $INSTALL_LIBDIR/conf, rather than
$INSTALL_LIBDIR/inc, so that it can be overridden by a
different configuration.
scripts/mercury_config.in:
Create a new configuration, by creating part of a Mercury
source tree from the files stored in $INSTALL_LIBDIR/reconf,
running configure, then copying the files into a partial
installation tree.
scripts/Mmake.vars.in:
Define ENABLE_DEEP_PROFILER, for use by bindist/bindist.Makefile.
Define variables INSTALL_CONF_DIR (contains the files describing
the configuration) and INSTALL_RECONF_DIR (contains files needed
to reconfigure an installation).
configure.in:
Add an option `--enable-reconfigure', for use by
mercury_config.in.
Don't look for runtime/mercury_wrapper.c when checking
for the sources -- it isn't present when reconfiguring.
Look for scripts/mmc.in instead.
Look for the runtime headers in the installation hierarchy
rather than the `runtime/' and `trace/' directories when
reconfiguring.
Output the help message for the `configure' script to
`configure.help'. This is included in the help message
for `mercury_config'.
Add new configuration variables CONFIG_PREFIX and CONFIG_LIBDIR,
which are like PREFIX and LIBDIR except that they point
to the configuration files, not the library files.
In the normal case PREFIX and CONFIG_PREFIX will be the same.
bindist/bindist.INSTALL.in:
bindist/bindist.Makefile.in:
Use mercury_config to configure binary distributions.
bindist/Mmakefile:
bindist/bindist.configure.in:
bindist/bindist.build_vars.in:
Remove bindist.configure.in and bindist.build_vars.in.
compiler/options.m:
scripts/parse_ml_options.sh-subr.in:
scripts/mgnuc.in:
doc/user_guide.texi:
Add an option `--mercury-config-dir', and an environment
variable MERCURY_CONFIG_DIR, which tell the compiler and
scripts where to find the configuration files for the
installation.
MERCURY_CONFIG_DIR is not documented because it should
only be used by the scripts.
compiler/compile_target_code.m:
Pass `--mercury-config-dir' to the scripts.
compiler/handle_options.m:
Add `--c-include-directory $MERCURY_CONFIG_DIR/conf'.
library/getopt.m:
Handle `maybe_string_special' options.
doc/user_guide.texi:
Update the "Using a different C compiler" chapter.
NEWS:
Document the changes.
Estimated hours taken: 2.5
Branches: main
Allow `mmc --make' to be used with Mmake.
scripts/mmake.in:
Add an option `--use-mmc-make', which tells mmake
to use `mmc --make' to build Mercury targets.
scripts/Mmake.vars.in:
Add a variable MC_MAKE_FILES, which should contain
files (e.g. generated header files) which should be
build with `mmc --make'.
Add a variable MERCURY_MAIN_MODULES which should
contain the top-level module names of the programs
or libraries in the directory. The targets for
the modules appearing in MERCURY_MAIN_MODULES
are added to MC_MAKE_FILES.
Add a variable MC_MAKE_FLAGS, which is like
MCFLAGS, but is only passed to `mmc --make'.
scripts/Mmake.rules:
Disable Mercury-specific rules when `--use-mmc-make'
is passed to mmake.
Use `mmc --make' for targets for which there are no
rules, or for targets appearing in MC_MAKE_FILES.
Estimated hours taken: 0.1
Branches: main
Fix bugs in my change to improve the handling of linking
with a non-installed standard library.
scripts/mmake.in:
Export MERCURY_STDLIB_DIR.
scripts/Mmake.rules:
Always set MERC_INT_DIR to avoid undefined variable warnings.
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:
scripts/mmake.in:
scripts/Mmake.vars.in:
scripts/Mmake.rules:
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'.
tools/lmc:
Use options rather than environment variables.
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.
Estimated hours taken: 1.5
Branches: main
Avoid problems with very long command lines by using xargs.
compiler/modules.m:
Use xargs to rm all the files for the clean and realclean targets.
scripts/mmake.in:
Use xargs to cat the .d and .dv files.
Estimated hours taken: 0.25
Branches: main
scripts/mmake.in:
Delete some accidentally duplicated code.
The code for handling `--no-use-subdirs' was there twice.
Estimated hours taken: 40
(to do this merge... 100s of hours on the HAL branch
itself by myself and Warwick Harvey though).
Merge the changes from the HAL branch onto the main branch. With the recent
changes made to the HAL implementation, this means adding just one grade,
`.rt' or --reserve-tag, which reserves one tag (zero) in each type for
use by HAL's Herbrand constraint solver. This disables no-tag types and
enumerations.
This grade will now bootstrap, and passes all tests, except for a few failing
cases in the debugger and tabling directories.
compiler/options.m:
compiler/handle_options.m:
Add the `.rt' or --reserve-tag grade option.
runtime/mercury_conf_param.h:
Document the macro MR_RESERVE_TAG
doc/user_guide.texi:
Document the `.rt' grade.
compiler/make_hlds.m:
Don't record any types as no-tag types if we are in a .rt grade.
compiler/make_tags.m:
compiler/type_ctor_info.m:
Allocate tags starting from `1' in .rt grades.
compiler/rtti_out.m:
In .rt grades, output a dummy ptag definition for tag `0'.
compiler/type_util.m:
Add predicates `type_util__constructors_are_dummy_argument_type' and
`type_constructors_are_type_info' for use when allocating tags to
ensure that type infos and dummy types (io__state/0 and store__store/1)
are still treated as no-tag types in .rt grades.
library/sparse_bitset.m:
When allocating a sparse bitset element, use tag `1' if we are in a
.rt grade.
runtime/mercury_tags.h:
Define a macro `MR_UNIV_TAG' which is `1' is we in a .rt grade and
`0' otherwise. (Now that univ is a user defined type, it is a also
assigned a `var' tag).
Also make the definitions of MR_RAW_TAG_NIL and MR_RAW_TAG_CONS take the
.rt grade into account.
runtime/mercury_type_info.h:
Define `MR_unravel_univ' and
`MR_initialise_univ' for taking apart and putting together univs.
Add a new secondary tag alternative: MR_SECTAG_VARIABLE, used to
represent Herbrand variables.
library/std_util.m:
Use MR_UNIV_TAG, MR_unravel_univ and MR_initialise_univ when
manipulating univs.
Handle the new MR_SECTAG_VARIABLE secondary tag by aborting.
runtime/mercury_deep_copy_body.h:
runtime/mercury_tabling.c:
runtime/mercury_unify_compare_body.h:
Handle the new MR_SECTAG_VARIABLE secondary tag by aborting.
library/std_util.m:
Add a constant for MR_SECTAG_VARIABLE in the MC++ back end.
scripts/canonical_grade.sh-subr:
scripts/init_grade_options.sh-subr:
scripts/mgnuc.in:
scripts/parse_grade_options.sh-subr:
Process the new grade.
scripts/mmake.in:
Add an option `--include-makefile', which includes a Makefile given
as a command line argument into the Makefile generated by mmake.
This is used to implement `halmake', a make program for HAL which
just passes a bunch of extra rules and variable definitions onto
mmake.
tests/debugger/existential_type_classes.m:
tests/hard_coded/existential_types_test.m:
trace/mercury_trace_declarative.c:
trace/mercury_trace_external.c:
trace/mercury_trace_internal.c:
Use MR_UNIV_TAG.
TODO:
- The declarative debugger falls over in .rt grades. This is possibly
because compiler/static_term.m assumes that the generated code uses
the same data representation as the compiler itself. This should be
fixed, although it is not critical; the declarative debugger won't
work with trailing as is, and the .rt grade is only ever used in
conjunction with trailing (.tr) at this stage.
Estimated hours taken: 0.25
scripts/mmake.in:
Add some comments explaining that the `--target il' option is
not supported. Issue a warning if it is used.
Estimated hours taken: 0.5
Fix a problem where the test cases were sometimes failing
if old /tmp/mmake* directories were left lying around.
scripts/ml.in:
scripts/mmake.in:
When creating the temporary directory, if mkdir fails (e.g.
because that directory already exists), then try again with a
different directory name. Only report an error if it fails 20
times in a row.
Estimated hours taken: 15
Split the automatically generated `.dep' file into two files. The new `.dv'
file contains all the variable definitions which used to be in the `.dep'
file, which now contains just the rules. With mmake including the `.dv'
files before the user's Mmakefile and the `.dep' files after, this allows
user-defined Mmakefiles to refer to the automatically-generated variables
and automatically-generated rules to refer to variables defined in the
user's Mmakefile. This was possible before to a limited extent, but in
particular dependency lists for automatically-generated rules could not
refer to user-defined variables.
Also introduced `C2INITARGS' as part of an illustration of how this change
is useful (though probably this should be a separate change). `C2INITARGS'
should be used to specify extra files to be passed to `c2init', rather than
the currently-used `C2INITFLAGS' (which should only be used for option
flags). The `_init.c' target should depend on these extra arguments, but it
was not possible to do this automatically prior to this change (at least,
not if one wanted to support per-program specification of `C2INITARGS').
compiler/modules.m:
Generate the new `.dv' files and revised `.dep' files.
Update the `change_clean' and `real_clean' targets to delete the
`.dv' files.
Update the `_init.c' rule to refer to `$(ALL_C2INITARGS)' as well as
`$(ALL_C2INITFLAGS)', and add a dependency on `$(ALL_C2INITARGS)'.
scripts/Mmake.rules:
Add appropriate rules and dependencies for `.dv' files.
scripts/Mmake.vars.in:
Add definitions for implementing `C2INITARGS'.
scripts/mmake.in:
Add code for using `.dv' files (while maintaining backward
compatibility for when they don't exist).
doc/user_guide.texi:
Document the new `.dv' files.
Document the new `C2INITARGS' variables and the dependencies they
imply.
../clpr/Mmakefile:
../clpr/samples/Mmakefile:
extras/complex_numbers/samples/Mmakefile:
extras/complex_numbers/tests/Mmakefile:
extras/graphics/mercury_opengl/Mmakefile:
extras/references/samples/Mmakefile:
extras/references/tests/Mmakefile:
extras/trailed_update/samples/Mmakefile:
extras/trailed_update/tests/Mmakefile:
Update to use `C2INITARGS' instead of `C2INITFLAGS', where
appropriate, and remove any now-obsolete `%_init.c' dependencies
(which wouldn't have worked anyway since GNU Make ignores pattern
dependencies with no commands).
Estimated hours taken: 3
Add Mmake support for target-specific MCFLAGS flags (MCFLAGS-foo, etc.)
using some tricky GNU Make hackery that avoids warning about undefined
variables.
Also define ALL_MCFLAGS = $(MCFLAGS) $(TARGET_MCFLAGS) $(EXTRA_MCFLAGS)
and use $(ALL_MCFLAGS) instead of $(MCFLAGS). This allows user Mmakefiles
to override MCFLAGS without suppressing the use of the TARGET_MCFLAGS
and EXTRA_MCFLAGS.
Similarly for the other *FLAGS variables.
scripts/Mmake.vars.in:
Define ALL_*FLAGS and TARGET_*FLAGS.
scripts/Mmake.rules:
Use ALL_*FLAGS instead of *FLAGS.
scripts/mmake.in:
Re-enable the warnings about undefined variables,
since we won't get too many spurious warnings now.
Mmake.common.in:
Delete `$(MCFLAGS-$*)' from the definition of `MCFLAGS', since this
is now done automatically by Mmake.
tests/Mmake.common:
Delete the definitions of MCFLAGS and GRADEFLAGS, since this stuff
is now done automatically by Mmake.
doc/user_guide.texi:
NEWS:
Document these changes.
Estimated hours taken: 0.5
scripts/mmake.in:
scripts/ml.in:
Ensure that the scripts clean up properly if interrupted --
avoid a small timing window during which an interrupt signal
could cause the scripts to leave temporary directories lying
around in /tmp.
Estimated hours taken: 0.5
Make another small fix to mmake.in and add more empty definitions for various
Mmake variables to avoid spurious warnings.
scripts/mmake.in:
Add `*clean*' to the patterns for which we do not
pass `--warn-undefined-variables'.
scripts/Mmake.rules:
When invoking make recursively, pass $(MFLAGS) rather than
$(MAKEOVERRIDES). This avoids a warning, and is probably the
right thing to do anyway (I'm not sure why I used MAKEOVERRIDES
in the first place).
boehm_gc/Mmakefile:
tests/hard_coded/Mmakefile:
Add empty definition for `MMAKEFLAGS'.
Estimated hours taken: 1
Fix some Mmakefile errors that were diagnosed by `--warn-undefined-variables'.
Also, make a small fix to mmake.in and add empty definitions for various
Mmake variables to avoid spurious warnings.
scripts/mmake.in:
Add ` dep*' to the patterns for which we do not
pass `--warn-undefined-variables'; previously it
matched "$@" against `dep*', which did not catch the
case of `mmake -k depend'.
^^^
scripts/Mmake.vars.in:
Add definition for `ds_subdir'.
Define `MLLIBS' as `$(EXTRA_MLLIBS)' rather than empty,
and add empty definition for `EXTRA_MLLIBS'.
Add empty definition for `MAIN_TARGET'.
Mmakefile:
Fix misspelling: `deps_subdir' not `dep_subdir'.
Add empty definitions for `PREINSTALL_HACK', `POSTINSTALL_HACK',
and `MMAKEFLAGS'.
boehm_gc/Mmakefile:
Add empty definition for `PROF'.
runtime/Mmakefile:
Add empty definition for `DLL_CFLAGS'.
library/Mmakefile:
Add empty definition for `CHECK_TERM_OPTS'.
compiler/Mmakefile:
Add empty definition for `MTAGSFLAGS'.
Estimated hours taken: 0.05
scripts/mmake.in:
Bugfix for previous change, mmake wasn't working on murlibobo.
"if ! mkdir... " seems to be a bash-ism. Use mkdir ...., then
check $? instead.
Estimated hours taken: 1
Fix two security holes in the way temporary files in /tmp are handled.
configure.in:
Look for mktemp.
scripts/ml.in:
Previously, if a file /tmp/ml$$ existed, linker errors would
be missed (or fake linker errors could be provided).
Use
mkdir /tmp/ml.$$ || exit 1
approach to create a directory, then use a file in that
directory as the fifo for linker errors.
scripts/mmake.in:
Previously, if a file /tmp/mmake.$$ existed, it would stop
the generation of a mmake file, and the system would invoke
gmake on the existing file (possibly executing arbitrary
commands).
Use mktemp (if available) to create the file, and exit if
it is not possible to create the file.
If mktemp is not available, use mkdir || exit 1 technique.
Estimated hours taken: 0.75
scripts/mmake.in:
Pass `--warn-undefined-variables', except when making dependencies.
runtime/Mmakefile:
scripts/Mmake.vars.in:
Add empty definitions of a few variables, to avoid warnings with
`--warn-undefined-variables'.
Estimated hours taken: 11
Finish off the centralization of the file name handling code, and
add support for generating intermediate files in subdirectories.
scripts/mmake.in:
Add a new boolean option `--use-subdirs';
if enabled, it just sets the environment variable MMAKE_USE_SUBDIRS
to `yes' before invoking Make.
Also add negative versions of the various options
(`--no-use-subdirs', `--no-verbose', `--no-save-makefile').
scripts/Mmake.rules:
Add code to handle generating intermediate file names
in subdirectories. If MMAKE_USE_SUBDIRS=yes, we add
`--use-subdirs' to MCFLAGS, and most of the pattern rules
are changed to use subdirectories.
Note that getting this to work required a bit of a hack:
due to what seem to be bugs in GNU Make, `mmake depend'
needs to do `mmc --make-short-interface *.m' to get things
started. But once the int3s are there, the dependencies
seem to work OK.
compiler/options.m:
Add a new boolean option `--use-subdirs'.
compiler/modules.m:
Add new predicate `fact_table_file_name'.
Add an extra argument to `module_name_to_file_name',
specifying whether or not to create any directories
needed for the file name.
Change all the file-name-creating predicates here
to go through a single new predicate `choose_file_name',
and add code in that predicate to handle the `--use-subdirs'
option.
Also if the `--use-subdirs' option is set, don't use the
compact dependencies format, since it can't work in that case.
compiler/fact_table.m:
Call `fact_table_file_name' rather than using `string__append'.
compiler/mercury_compile.m:
Change `link_module_list' and `join_module_list'
so that they create file names by calling `module_name_to_file_name'.
compiler/export.m:
compiler/intermod.m:
compiler/llds_out.m:
compiler/mercury_compile.m:
compiler/module_qual.m:
compiler/modules.m:
compiler/termination.m:
compiler/trans_opt.m:
compiler/unused_args.m:
Change all calls to `module_name_to_file_name' to pass
the extra argument specifying whether or not to make
any directories needed for the file name.
library/Mmakefile:
Change the rule for `mmake install_ints' so that it
creates a `Mercury' subdirectory with symbolic links
`ints', `int2s', `int3s', `opts', and `trans_opts'
which just point to `..'. This is needed for the
`--use-subdirs' option to work, because Mmake currently
does not support mixing libraries compiled with and
without `--use-subdirs'.
doc/user_guide.texi:
Document the above changes.
Estimated hours taken: 0.25
scripts/mmake.in:
Undo my previous change to use `exec', since that causes
problems because the temporary files never get removed.
Instead, I've just added a comment saying why `exec' can't
be used.
Estimated hours taken: 0.25
scripts/mmake.in:
Change the code so that it uses `exec' to run make,
rather than just invoking it as a sub-process. This
should be a little more efficient.
scripts/c2init.in:
scripts/mmake.in:
scripts/msc.in:
Small changes to the help messages to make them come out
better when converted to man pages.
scripts/mgnuc.in:
Add a `--help' option.
Estimated hours taken: 0.25
scripts/mmake.in:
Check for `Mmakefile' as an alternative to `Mmake'.
(This change is so I can rename scripts/Mmake as Mmakefile
to avoid a conflict with scripts/mmake on systems with
case-insensitive file systems, e.g. Windows 95.)
Estimated hours taken: 1
Ensure that mmake does not attempt to remake the `.c' file if it is up-to-date.
(This change should hopefully fix a problem with the source distribution not
being able to bootstrap itself.)
Also a couple of minor tidy-ups.
scripts/mmake.in:
Export new variable MMAKE_MAKE_CMD, for use by Mmake.rules.
scripts/Mmake.rules:
In the rule for `.m' -> `.o', use a recursive invocatino of
make (via the MMAKE_MAKE_CMD variable) to build the `.c' file,
rather than unconditionally invoking `$(MCG)'.
scripts/.cvsignore:
Add Mmake.vars, since it is now automatically-generated.
scripts/ml.in:
Some stylistic changes: make sure that autoconf @var@ variables occur
only in assignments to shell variables at the start of the script,
not scattered throughout the body of the script.
scripts/*.in:
Replace all uses of
... "$@" ...
with
case $# in
0) ... ...
*) ... "$@" ...
esac
since on ULTRIX and OSF, "$@" does the wrong thing if $# is 0.