[m-dev.] for review: be more lenient on pathnames.
Fergus Henderson
fjh at cs.mu.OZ.AU
Sat May 23 17:44:24 AEST 1998
On 23-May-1998, Tyson Dowd <trd at cs.mu.OZ.AU> wrote:
>
> I made this change, and then realized it wasn't actually causing
> a big problem (libc5/libc6 differences were causing the problem
> I was experiencing), but since I've made the change, perhaps
> it is worthwhile committing anyway.
>
> ===
>
> mercury has /bin/mkfifo
> hydra (and cyclone, and cat and munta) have /usr/bin/mkfifo
>
> I don't think there is any *really* good reason to have absolute
> pathnames for mkfifo (et al) unless they are in non-standard
> locations, so here's a fix.
I think this may be out of the frying pan into the fire.
The problem with *not* using absolute path names is that
the installed programs may not work if the user's PATH is different
to the PATH of the person doing the installation.
For example, the system may not come with `mktemp', and so
`mktemp' may have been installed in /usr/local/bin.
If the user doesn't have /usr/local/bin in their path,
then Mercury won't work.
With the way things are currently done, it is a bit
inconsistent. For `mktemp', `mkfifo', and `mknod'
we use the absolute pathname. For `gcc' and `make',
we use the user's PATH. We have had a lot of people
report problems due to their PATH not including the
right version of `gcc' and `make' -- this is compounded
by the fact that the error messages they get are very
obscure.
Thus I would prefer that we change the current behaviour
in the other direction -- use absolute pathnames for
gcc and make.
If the issue is about sharing distributions via NFS
between systems that have executables in different
places, then I would say
(a) this is arguably not a good idea anyway,
since if the systems have executables in
different places then they are likely
to be subtly incompatible in other ways too
(b) if you do want to share distributions
between such systems, you can still do it,
for example by adding links. For example,
you can link /usr/bin/mkfifo -> /bin/mkfifo
on one machine. Or, if you're not root
but you have write access to /usr/local/bin,
then you can link /usr/local/bin/mkfifo to
/usr/bin/mkfifo on one machine and to
/bin/mkfifo on the other, and put
/usr/local/bin first in your path before
installing.
Cheers,
Fergus.
--
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.
More information about the developers
mailing list