From mboxrd@z Thu Jan 1 00:00:00 1970
X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-14) on finch.gentoo.org
X-Spam-Level:
X-Spam-Status: No, score=-0.1 required=5.0 tests=DATE_IN_PAST_24_48,
DMARC_MISSING,INVALID_DATE,MAILING_LIST_MULTI autolearn=unavailable
autolearn_force=no version=4.0.0
Received: from tadpol.dsl.visi.com ([208.42.95.172] helo=sunspot.tilstra.com)
by cvs.gentoo.org with esmtp (Exim 3.30 #1)
id 15PDDR-0007wy-00
for gentoo-dev@cvs.gentoo.org; Tue, 24 Jul 2001 19:11:58 -0600
Received: from tadpol by sunspot.tilstra.com with local (Exim 3.12 #1 (Debian))
id 15PDD4-0000CC-00; Tue, 24 Jul 2001 20:11:34 -0500
From: tadpol@tadpol.org
To: gentoo-dev@cvs.gentoo.org
Subject: Re: [gentoo-dev] destdir vs prefix
Message-ID: <20010724201132.B727@tadpol.org>
References: <63159.63.204.248.117.996018287.squirrel@www.portablehole.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
User-Agent: Mutt/1.0.1i
In-Reply-To: <63159.63.204.248.117.996018287.squirrel@www.portablehole.net>; from jano@portablehole.net on Tue, Jul 24, 2001 at 04:44:47PM -0700
X-Face: #SH"AGfFc8u[OW5Rp;V;WNnT
X-Copyright: 2001 by Michael Conrad Tilstra
X-URL:
Sender: gentoo-dev-admin@cvs.gentoo.org
Errors-To: gentoo-dev-admin@cvs.gentoo.org
X-BeenThere: gentoo-dev@cvs.gentoo.org
X-Mailman-Version: 2.0
Precedence: bulk
Reply-To: gentoo-dev@cvs.gentoo.org
X-Reply-To: tadpol@gentoo.org
List-Help:
List-Post:
List-Subscribe: ,
List-Id: Gentoo Linux development list
List-Unsubscribe: ,
List-Archive:
Date: Tue Jul 24 19:12:02 2001
X-Original-Date: Tue, 24 Jul 2001 20:11:33 -0500
X-Archives-Salt: 1f1fba3b-03d7-49ba-84d8-daceb3d470a3
X-Archives-Hash: bf3614fc501b25cba2f911f498cf0352
On Tue, Jul 24, 2001 at 04:44:47PM -0700, jano wrote:
> i've had this explained to me a few times already, but for some reason,
> I'm still having problems grasping the idea.
>
> program is typical autoconf tarball.. ./configure, make, make install.
>
> So when doing the "try make install" command within an .ebuild file,
> how do you know whether to use DESTDIR or PREFIX, or both? I check out
> the makefile for this particular program, which has the files depend on
> ${prefix} (e.g. mandir=${prefix}/man), and a sole line with "DESTDIR = "
>
> This particular program installs the biaries, docs, etc fine either
> way. If I do:
> try make PREFIX=${D} install
probably should have been: try make prefix=${D} install
case is very important.
> however, when reading the /var/db/pkg/blah/CONTENTS file, i see only
> those files which I explicitly do a dodoc, dobin, doman, etc. So an
> unmerge/uninstall will not remove the whole program as it should. I
> tried to change it to PREFIX=${D}/usr as I've seen in some ebuilds, no
> worky worky. But when I do:
> try make DESTDIR=${D} install
> everything shows up the right way, including CONTENTS and stuff.
>
> I'm rendered confused. Why does it work this way?
why not? ^_^
when you look in a Make file to see if you should use prefix or DESTDIR,
you really need to look at the install rule. (Search for 'install:')
Following that should be a list of commands that are executed. You should
be able to tell from that, though sometimes you have to look and see how
various variables are defined. (It would hurt to have a basic
understanding of how make works. (hmmm i see no makefile howto. that
sucks))
You need to use which ever works. Which works? Depends on the makefile.
Since there is not any standard way to doing makefiles and install rules,
There isn't any concrete answer. Sorry. (Look on the bright side,
atleast one worked for you. I've a couple of ebuilds I had to patch the
makefile so it would install correctly.)
Hope I helped thin the confusion, and not added to it.
--
Michael Tilstra tadpol@tadpol.org
My employer thinks my opinions are crap.