[m-dev.] for review: Use default extensions
Fergus Henderson
fjh at cs.mu.OZ.AU
Thu Jun 22 06:11:16 AEST 2000
On 21-Jun-2000, Peter Ross <petdr at cs.mu.OZ.AU> wrote:
> compiler/modules.m:
> When generating the '.dv' and '.dep' files use '.$O' and '.$A'
> instead of '.o' and '.a'.
...
> Index: compiler/modules.m
...
> @@ -604,10 +604,10 @@
> ; Ext = ""
> ; Ext = ".split"
> % library files
> - ; Ext = ".a"
> + ; Ext = ".$A"
> ; Ext = ".so"
> ; Ext = ".$(EXT_FOR_SHARED_LIB)"
> - ; Ext = ".split.a"
> + ; Ext = ".split.$A"
> ; Ext = ".split.so"
> ; Ext = ".split.$(EXT_FOR_SHARED_LIB)"
> ; Ext = ".init"
I think you should leave the old code there,
and add the new code without deleting the old code,
so that it will match both `.a' and `.$A',
the same way it matches both `.so' and `.$(EXT_FOR_SHARED_LIB)'.
Probably you should also add lines for `.obj' and `.lib'.
That way, this code is more robust: it will do the right
thing regardless of whether you pass it the expanded name
for the extension or the unexpanded variable reference.
> @@ -643,21 +643,21 @@
> % we need to handle a few cases specially
> %
> {
> - Ext = ".dir/*.o"
> + Ext = ".dir/*.$O"
> ->
> SubDirName = "dirs"
Likewise here.
> ;
> - % .o and .pic_o files need to go in the
> + % .$O and .pic_o files need to go in the
> % same directory, so that using
> % .$(EXT_FOR_PIC_OBJECTS) will work.
> - ( Ext = ".o"
> + ( Ext = ".$O"
> ; Ext = ".pic_o"
> ; Ext = "$(EXT_FOR_PIC_OBJECTS)"
> )
And here.
Apart from that, this change looks fine.
--
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