Menu-spec update (Was: [Patch] Update 'How to' to clarify computation of datadir)
Joerg.Barfurth at Sun.COM
Wed Mar 22 16:33:14 EET 2006
Jeremy White wrote:
> I'm the sysadmin for a network of computers; I've built them
> to all have a common nfs mount point at /mnt/shared;
> all systems have an XDG_DATA_DIRS of something like
> I want to install a new package, I type:
> XDG_DATA_DIRS=/mnt/shared ./install-some-software.sh
> and my software menus are automatically installed into a
> shared location. Sweet!
For install, you should typically be able to use something like
(or PREFIX=/mnt/shared ./install-some-software.sh, if you prefer).
XDG_DATA_DIRS is a list of pathes - as such it is a bad place to specify
a uniquer directory (the one to install to). With your default
XDG_DATA_DIRS, what should that installer do? Silently fall back to
installing into /usr/local, if /mnt/shared is mounted readonly? What if
the NFS server for /mnt/shared is down?
> Or maybe I don't want a particular package to be visible to
> users in a particular group; I want to do:
> XDG_DATA_DIRS=/opt/secret_software ./install-some-software.sh
Having software packages that support installing into a specific prefix
is fine. And to support your flexibility, the software really should
install only into the given prefix. Then it is your choice to include
/opt/secret_software/share into XDG_DATA_DIRS for your users or not.
XDG_DATA_DIRS is a directive for reading (and coalescing) multiple
source locations. But that should not be mixed with install-prefix
directives, which always should unambiguously name a single directory.
So whatever mechanism an installer uses to identify the prefix to
install to, it should *not* be XDG_DATA_DIRS.
Joerg Barfurth Sun Microsystems - Desktop - Hamburg
>>>>>>>>>>>>>>>>>> using std::disclaimer <<<<<<<<<<<<<<<<<<<<<<<
Software Engineer joerg.barfurth at sun.com
Thin Client Software
More information about the xdg