[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: base directory spec

On Thu, Dec 05, 2002 at 12:17:48AM +0100, Waldo Bastian wrote:
> On Wednesday 04 December 2002 23:01, Mike Hearn wrote:
> > I'm very sorry but it's late and I've just rebuilt the same tarball 14
> > times, so i'm feeling a little weary and slow.
> >
> >         $DESKTOP_DIR defines the base directory relative to which
> >         applications should install files. If $DESKTOP_DIR is not
> >         defined a default value equal to /usr/share should be used.
> >         Binary packages should ignore $DESKTOP_DIR and assume
> >         /usr/share. Source tarballs using a "configure" script should
> >         use the standard install locations for configure (--prefix,
> >         --datadir, and so forth).
> >
> > Hmmm, if binary packages ignore it (why??) and source tarballs do their
> > own thing relative to the prefix anyway, what is this variable for when
> > installing things?
> Yes, for the sake of clearity it is probably better to drop $DESKTOP_DIR 
> completely and just replace it with /usr/share.

Why not just get rid of it completely? Non-relocatable binary packages
should install to whereever the distribution likes to put things
(typically /usr/share), but that's for the packagers to worry about.

Everything else should offer a choice of any directory in DESKTOP_DIRS
(eg, using --prefix to configure). I don't see why configure scripts
should default to /usr/local, and other source packages to DESKTOP_DIR.

Finally, the first element of DESKTOP_DIRS is required to be equal to
DESKTOP_HOME. Therefore, DESKTOP_HOME seems rather pointless (since it can
be trivially extracted from DESKTOP_DIRS), and just increases the chance
of them getting out-of-sync (eg, my preferences get saved in one place,
but nothing looks for them there).

Although this change seems to make it slightly harder to set DESKTOP_HOME
(since you need to include the other directories), in fact it's easier,
because you might have to update both DESKTOP_DIRS and DESKTOP_HOME in the
current system.

I think including a snippet of a sh script to work out DESKTOP_HOME would
be a good idea (otherwise people will use bashisms and cause portability
problems). Or, say that $DESKTOP_HOME:$DESKTOP_DIRS should be searched.

And I still prefer PREFIX_PATH as a name, to be consistant with configure

Thanks, though. It's good to have this up at last!

Thomas Leonard			http://rox.sourceforge.net
tal00r ecs soton ac uk		tal197 users sourceforge net
GPG: 9242 9807 C985 3C07 44A6  8B9A AE07 8280 59A5 3CC1

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]