From owner-freebsd-ports@FreeBSD.ORG Mon May 22 14:58:21 2006 Return-Path: X-Original-To: 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 3600F16B0EB for ; Mon, 22 May 2006 14:58:21 +0000 (UTC) (envelope-from erikt@owl.midgard.homeip.net) Received: from pne-smtpout1-sn1.fre.skanova.net (pne-smtpout1-sn1.fre.skanova.net [81.228.11.98]) by mx1.FreeBSD.org (Postfix) with ESMTP id A9BE243D6D for ; Mon, 22 May 2006 14:58:18 +0000 (GMT) (envelope-from erikt@owl.midgard.homeip.net) Received: from falcon.midgard.homeip.net (83.253.29.241) by pne-smtpout1-sn1.fre.skanova.net (7.2.072.1) id 446E043B0008D9EB for ports@freebsd.org; Mon, 22 May 2006 16:58:17 +0200 Received: (qmail 70401 invoked from network); 22 May 2006 16:58:14 +0200 Received: from owl.midgard.homeip.net (10.1.5.7) by falcon.midgard.homeip.net with SMTP; 22 May 2006 16:58:14 +0200 Received: (qmail 31300 invoked by uid 1001); 22 May 2006 16:58:14 +0200 Date: Mon, 22 May 2006 16:58:14 +0200 From: Erik Trulsson To: Jim Pirzyk Message-ID: <20060522145814.GA31267@owl.midgard.homeip.net> Mail-Followup-To: Jim Pirzyk , ports@freebsd.org References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.11 Cc: ports@freebsd.org Subject: Re: Setting a KNOB/OPTION in BUILD_DEPENDS 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: Mon, 22 May 2006 14:58:26 -0000 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. -- Erik Trulsson ertr1013@student.uu.se