[m-rev.] diff: fix mmc --make and shared libraries on darwin

Julien Fischer juliensf at cs.mu.OZ.AU
Wed Feb 8 15:10:10 AEDT 2006


On Tue, 7 Feb 2006, Ian MacLarty wrote:

> On 7 Feb 2006, at 18:44, Julien Fischer wrote:
>
> >
> > Estimated hours taken: 3.5
> > Branches: main
> >
> > Fix a bug with mmc --make and shared libraries on Darwin.  The problem was
> > that the install_name for the library was being incorrectly set was
> >
>
> delete "was".
>

Done.

> > compiler/modules.m:
> > 	Set the value of the install-name path correctly.  If the user doesn't
> > 	specify a value then generate one based on the current value of
> > 	INSTALL_PREFIX.
> >
> > compiler/options.m:
> > 	Delete the bogus default value for the shlib-linker-install-name-path
> > 	option.
> >
>
> Why is $(INSTALL_MERC_LIB_DIR) a bogus default value?  Is that because it
> gets set by mmake and so is blank when mmc is called outside of mmake?

Yes, furthermore mmake doesn't seem to use it anyway - it also works
perfectly well with it blank.

> Does this mean that when you build shared libraries with
> mmc --make you must either set INSTALL_PREFIX in the environment or pass
> --shlib-linker-install-name-path?  Or is that value of INSTALL_PREFIX coming
> from the runtime (i.e runtime/mercury_conf*.h)?

I think you mean scripts/Mercury.config there, and no, you could also put
INSTALL_PREFIX in your Mercury.options file which is where I expect most users
of mmc --make will put it.  If you don't specify it then it will use the
default value from Mercury.config *unless* you have overridden the default
value of --shlib-linker-install-name-path.

> Also if I build a library, but don't install it, can I still link with
> the library?

Yes (in as much as you could do that anyway).

> Also I assume everything still works with mmake :-)

Yes.

Cheers,
Julien.
--------------------------------------------------------------------------
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