Greg A Woods <[EMAIL PROTECTED]> writes:
> [ On , September 6, 2000 at 21:57:04 (-0700), Russ Allbery wrote: ]
>> You need both;
> Actually no, as I tried to explain earlier you do not want to be able to
> adjust $(prefix) during any "make" execution, at least not the way many
> people use $(prefix) in existing packages -- as we've seen this is very
> bad for dependency maintenance (i.e. it makes it impossible with any
> portable makefile that can be written today).
*sigh*
Greg, we *just* talked about this, on this list, with you, and you ended
up agreeing with me. So now I have to argue you around again? :/
DESTDIR is not usable for the general case of installing a package in a
different location than it will be in when it runs, because it requires
that you replicate your entire runtime directory structure under the
DESTDIR directory. We've never had to do this in the past and I don't
want to start having to do this now.
./configure --prefix=/usr/pubsw
make
make install prefix=/afs/.ir/pubsw/Development/gcc-2.95.2/@sys
is a well-defined sequence of commands that's worked on nearly all GNU
packages for well over half a decade now; a prefix of /usr/pubsw is
compiled into the software package and then the software package is
installed in the location that we need it to be installed in AFS for
automatic linking into /usr/pubsw using other tools.
> However you are correct in stating that $(prefix) and ${DESTDIR} are
> very different in what they do. Indeed it should be possible to adjust
> ${DESTDIR} during "make install" (and it would only have effect during
> "make install").
It certainly should, since DESTDIR is not a configure or build-time option
and should have no effect on anything except the installation.
> $(prefix) specifies the *run-time* location of installed files, not
> necessarily the location they are installed to.
No, $(prefix) specifies the root of the package for whatever step you're
performing. --prefix as an argument to configure says to configure the
package with that root, $(prefix) in make says to build the package with
that root (and you should generally always configure and build with the
same root), and $(prefix) in make install says to install the package with
that root, which doesn't have to match the root it was built with provided
that this will be taken care of later (by, e.g., volume releases or
automatic linking tools like many of us use).
> The problem with this is that it it is extremely confusing to developers
> and users alike (as can be demonstrated by analysis of many existing
> packages).
I'm sorry to disagree with you so bluntly, but this is false. I set
prefix at make install time for basically every package I build, hundreds
of them, and have been doing so for years, and it works exactly as
intended 99% of the time. And when it doesn't, it's easy enough to send
in patches.
> Clearly separating the intent of variables that specify installation
> locations and run-time locations is far more productive than their
> current overloaded state.
This horse has already left the barn, found a race track, and won the
Kentucky Derby.
--
Russ Allbery ([EMAIL PROTECTED]) <http://www.eyrie.org/~eagle/>