Re: keeping distros and admins off of each other's toes

[email protected] (Paul Jarc) Tue, 10 Feb 2004 14:20:30 -0500
Newsgroups gmane.comp.djb.package
Organization What did you have in mind? A short, blunt, human pyramid?
Message-ID <[email protected]>
Stefan Karrmann <[email protected]> wrote:
> Suppose the local admin provides /package/prog/skalibs-0.40 as default.
> But I want to use the new /package/prog/skalibs-0.41. How can I get
> this?

You can set up your own private $HOME/package hierarchy, and any
packages installed there can be customized to use
$HOME/package/prog/skalibs instead of /package/prog/skalibs.

But if you want the same path /package/prog/skalibs to mean one thing
to you while it means something else to other processes, then (unless
you're on GNU/Hurd) you need a bit of help from root, and the
technique I know only works on Solaris and Linux: if fd 63 is open to
a directory, then /proc/self/fd/63 is a symlink to that directory, and
you can refer to paths like /proc/self/fd/63/package/prog/skalibs.
/package could then be a symlink to /proc/self/fd/63/package.  The
boot system would have to ensure that fd 63 is open to the directory
containing the "systemwide" /package, and users could override that in
their own processes.  This is a bit fragile, though, since some
(poorly-written) programs may close descriptors they don't know about,
which would break their access to /package.


paul