From owner-freebsd-ports@FreeBSD.ORG Fri Aug 5 07:24:14 2005 Return-Path: X-Original-To: freebsd-ports@freebsd.org Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C00A916A41F for ; Fri, 5 Aug 2005 07:24:14 +0000 (GMT) (envelope-from stijn@pcwin002.win.tue.nl) Received: from pastinakel.tue.nl (pastinakel.tue.nl [131.155.2.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 41E4143D4C for ; Fri, 5 Aug 2005 07:24:14 +0000 (GMT) (envelope-from stijn@pcwin002.win.tue.nl) Received: from localhost (localhost [127.0.0.1]) by pastinakel.tue.nl (Postfix) with ESMTP id 4C7DF14BC11; Fri, 5 Aug 2005 09:24:13 +0200 (CEST) Received: from pastinakel.tue.nl ([127.0.0.1]) by localhost (pastinakel.tue.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 15733-01; Fri, 5 Aug 2005 09:24:12 +0200 (CEST) Received: from pcwin002.win.tue.nl (pcwin002.win.tue.nl [131.155.71.72]) by pastinakel.tue.nl (Postfix) with ESMTP id 9922D14BC0F; Fri, 5 Aug 2005 09:24:12 +0200 (CEST) Received: (from stijn@localhost) by pcwin002.win.tue.nl (8.13.4/8.13.4/Submit) id j757OCt7066826; Fri, 5 Aug 2005 09:24:12 +0200 (CEST) (envelope-from stijn) Date: Fri, 5 Aug 2005 09:24:12 +0200 From: Stijn Hoop To: Adam Weinberger Message-ID: <20050805072412.GB70957@pcwin002.win.tue.nl> References: <20050805070513.GA60681@sinanica.bg.datamax> <42F310D2.7020200@magnesium.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="oFbHfjnMgUMsrGjO" Content-Disposition: inline In-Reply-To: <42F310D2.7020200@magnesium.net> User-Agent: Mutt/1.4.2.1i X-Bright-Idea: Let's abolish HTML mail! X-Virus-Scanned: amavisd-new at tue.nl Cc: vd@datamax.bg, freebsd-ports@freebsd.org Subject: Re: The right way to depend on a package's extra feature 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: Fri, 05 Aug 2005 07:24:14 -0000 --oFbHfjnMgUMsrGjO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Aug 05, 2005 at 03:10:10AM -0400, Adam Weinberger wrote: > Vasil Dimov wrote: > >Hi list, > > > >What it the right way to make a port that depends on other port, but > >that other port must be built with some extra feature? > > > >For example, imagine we have port "A" that installs > >/foo/bar/great_feature only if it is build with > >'make WITH_GREAT_FEATURE=3Dyes' > > > >Then we have port "B" that happens to depend on /foo/bar/great_feature. > > > >You see, there are two problems here: > > > >1. We cannot pass WITH_GREAT_FEATURE=3Dyes via the RUN_DEPENDS technolog= y, > > only the target may be specified: RUN_DEPENDS=3D/file:portdir:target > > needed command: make -C portdir WITH_GREAT_FEATURE=3Dyes target > > > >2. Port A may have already been installed without WITH_GREAT_FEATURE=3Dy= es > > This will cause make WITH_GREAT_FEATURE=3Dyes install in A's dir to f= ail > > with error "already installed" > > needed command: portupgrade -f -m WITH_GREAT_FEATURE=3Dyes /var/db/pk= g/A > > (huh! we used portupgrade, not very nice...) > > > >Any suggestions? Did I miss something? >=20 > I have that same problem with deskutils/gourmet. It needs a metakit=20 > built with python support, but python support is disabled by default.=20 > You can see what I've done as a kludge in deskutils/gourmet/Makefile,=20 > but the best solution would be to separate metakit into a master/slave > port thing so you can just depend on metakit-python and be done with it. This is not the _best_ thing to do though, as other ports may depend on the master port, in turn requiring both the master and the slave port to be installed. This in turn leads to a knob to select the 'right' port for a piece of software, which is not always present. I.e. I have both devel/svk and devel/subversion installed. Now, I need devel/subversion because other software depends on it, so I build it with perl bindings by myself. However, devel/svk insists on depending on devel/subversion-perl because it wants the perl bindings -> not good... I don't see a way out except extending the DEPENDS mechanism with optional flags, or at least checking of /var/db/ports/*/options (for OPTIONS enabled ports). --Stijn --=20 A "No" uttered from deepest conviction is better and greater than a "Yes" merely uttered to please, or what is worse, to avoid trouble. -- Mahatma Ghandi --oFbHfjnMgUMsrGjO Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (FreeBSD) iD8DBQFC8xQcY3r/tLQmfWcRAsDAAJ9aSlcZOqsWXcpnQl2FzeqXsY63fgCglevL mBMjK7/nT4dmGIrbitTx+jg= =7uFx -----END PGP SIGNATURE----- --oFbHfjnMgUMsrGjO--