From owner-freebsd-ports@FreeBSD.ORG Wed Oct 17 12:36:20 2007 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 270AF16A420 for ; Wed, 17 Oct 2007 12:36:20 +0000 (UTC) (envelope-from tijl@ulyssis.org) Received: from thumbler.kulnet.kuleuven.ac.be (thumbler.kulnet.kuleuven.ac.be [134.58.240.45]) by mx1.freebsd.org (Postfix) with ESMTP id 816E713C457 for ; Wed, 17 Oct 2007 12:36:19 +0000 (UTC) (envelope-from tijl@ulyssis.org) Received: from localhost (localhost [127.0.0.1]) by thumbler.kulnet.kuleuven.ac.be (Postfix) with ESMTP id AA131138416; Wed, 17 Oct 2007 14:36:16 +0200 (CEST) Received: from smtps02.kuleuven.be (smtpshost02.kulnet.kuleuven.be [134.58.240.75]) by thumbler.kulnet.kuleuven.ac.be (Postfix) with ESMTP id 1CE7213830A; Wed, 17 Oct 2007 14:36:15 +0200 (CEST) Received: from kalimero.kotnet.org (kalimero.kotnet.org [10.4.16.222]) by smtps02.kuleuven.be (Postfix) with ESMTP id B88ACF3862; Wed, 17 Oct 2007 14:36:14 +0200 (CEST) Received: from kalimero.kotnet.org (kalimero.kotnet.org [127.0.0.1]) by kalimero.kotnet.org (8.14.1/8.14.1) with ESMTP id l9HCa94B002728; Wed, 17 Oct 2007 14:36:10 +0200 (CEST) (envelope-from tijl@ulyssis.org) X-Kuleuven: This mail passed the K.U.Leuven mailcluster From: Tijl Coosemans To: Dmitry Marakasov Date: Wed, 17 Oct 2007 14:36:07 +0200 User-Agent: KMail/1.9.7 References: <20071015163024.GA55552@hades.panopticon> In-Reply-To: <20071015163024.GA55552@hades.panopticon> MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-r" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200710171436.09021.tijl@ulyssis.org> X-Virus-Scanned: by KULeuven Antivirus Cluster Cc: freebsd-ports@freebsd.org Subject: Re: DATADIR question X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Oct 2007 12:36:20 -0000 On Monday 15 October 2007 18:30:24 Dmitry Marakasov wrote: > I'm porting silvertree game (from creators of wesnoth), and I have > some issues with it's DATADIR. > > The problem is that port is named silvertree, but it installs data > under ${PREFIX}/share/silvertree-rpg. What do I do with DATADIR in > this case? > > 1. Rename the port: > Not a best solution, as I'll have to introduce additional variables > like DISTNAME, which are overwise correct with their default values. > Also, this -rpg suffix may change in future. > > 2. Leave it as it is: > * Will install data to ${PREFIX}/share/silvertree-rpg > * Plist: share/silvertree-rpg/somefile > * portlint complaints, DATADIR is not used at all > > 3. Force configure to use DATADIR with adding --datadir to > CONFIGURE_ARGS > * Will install data to ${PREFIX}/share/silvertree/silvertree-rpg > * Plist: %%DATADIR%%/silvertree-rpg/somefile > > 4. Change DATADIR in port > * Will install data to ${PREFIX}/share/silvertree-rpg > * Plist: %%DATADIR%%/somefile > * DATADIR=${PREFIX}/share/silvertree-rpg > > I think the correct way is 3 or 4, but I didn't find enough data on > DATADIR meaning: should it be user-changeable (i.e. user can install > a port without touching PREFIX but changing DATADIR), or is more like > a shortcut to sync port's Makefile and plist, so port could change it > to actual value and plist should only use %%DATADIR%%? > > Seems that DATADIR user-changeable is not the case, as it's not even > passed to configure by default. So correct way is more like #4, am I > right? Actually I'd like to see this clarified as well, because none of the port maintainers I've ever spoken to knows this. Is DATADIR supposed to be user changeable or not? Does it need to be passed to configure or not?