Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 May 2006 16:58:14 +0200
From:      Erik Trulsson <ertr1013@student.uu.se>
To:        Jim Pirzyk <pirzyk@freebsd.org>
Cc:        ports@freebsd.org
Subject:   Re: Setting a KNOB/OPTION in BUILD_DEPENDS
Message-ID:  <20060522145814.GA31267@owl.midgard.homeip.net>
In-Reply-To: <D13E0E41-26E1-4DCE-A34B-5B7C67FD99A6@freebsd.org>
References:  <D13E0E41-26E1-4DCE-A34B-5B7C67FD99A6@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, May 22, 2006 at 09:43:20AM -0500, Jim Pirzyk wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> I am trying to write a Makefile for a software package that needs
> another package built with a non default OPTION set.  How do I
> do this?  Specifically, I need krb5 built with the KRB5_KRB4_COMPAT
> set to YES (it is defaulted to NO).  I currently have this:
> 
> .if defined(WITH_SNK)
> KRB5_KRB4_COMPAT=	YES
> BUILD_DEPENDS= ${LOCALBASE}/include/kerberosIV/des.h:${PORTSDIR}/ 
> security/krb5
> .endif
> 
> But when krb5 gets installed, the KRB5_KRB4_COMPAT is not set
> to yes, and des.h does not get installed.
> 
> How is this to be done?  the Porters handbook is unclear in this.
> I also have tried to set the ':target' part of BUILD_DEPENDS to
> - -DKRB5_KRB4_COMPAT=YES, but that did not work either.

I don't think there is any way to do that, especially not if the port you
depend on already is installed without the non-default option set, since the
options used for building a port is usually not stored anywhere, so it is
normally not possible to determine if the installed port was compiled with
the necessary options set or not.


The only way I can think of to handle this situation is to create
a slave-port for the port you depend on that has the desired options set,
and then depend on this slave-port instead.



-- 
<Insert your favourite quote here.>
Erik Trulsson
ertr1013@student.uu.se



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060522145814.GA31267>