[m-dev.] For review: Split auto-generated dependencies
Fergus Henderson
fjh at cs.mu.OZ.AU
Thu Jul 15 16:20:30 AEST 1999
On 15-Jul-1999, Warwick Harvey <wharvey at cs.monash.edu.au> wrote:
> 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.
[...]
> Index: compiler/modules.m
> @@ -2503,10 +2558,16 @@
> list__foldl(append_to_init_list(DepStream, InitFileName), Modules),
> io__write_string(DepStream, "\n"),
>
> - io__write_strings(DepStream, [
> - InitCFileName, " : ", DepFileName, "\n",
> + % Note we have to do some ``interesting'' hacks to get
> + % `$(ALL_C2INITARGS)' to work in the dependency list (and not
> + % complain about undefined variables).
> + io__write_strings(DepStream, [
> + InitCFileName, " : ", DepFileName, " ", DvFileName,
> + " $(foreach @,undefined,$(foreach *,", MakeVarName,
> + ",$(ALL_C2INITARGS)))\n",
The hacks that rely on features specific to GNU Make
should be disabled if --no-assume-gmake was set.
To handle that situation, if --assume-gmake is not set, then you could
either just drop that dependency, or add it unconditionally.
> @section Auxiliary output options
> @table @code
> @item --no-assume-gmake
> -When generating @file{.dep} files, generate Makefile
> +When generating @file{.d} and @file{.dv} files, generate Makefile
> fragments that use only the features of standard make;
> do not assume the availability of GNU Make extensions.
Presuming you make the change suggested above, that should be
"When generating @file{.d}, @file{.dv}, and @file{.dep} files, ...".
Otherwise, that change looks fine -- thanks.
--
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.
--------------------------------------------------------------------------
mercury-developers mailing list
Post messages to: mercury-developers at cs.mu.oz.au
Administrative Queries: owner-mercury-developers at cs.mu.oz.au
Subscriptions: mercury-developers-request at cs.mu.oz.au
--------------------------------------------------------------------------
More information about the developers
mailing list