From owner-freebsd-ports@FreeBSD.ORG Wed Sep 27 14:29:23 2006 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 97C8B16A412 for ; Wed, 27 Sep 2006 14:29:23 +0000 (UTC) (envelope-from swhetzel@gmail.com) Received: from hu-out-0506.google.com (hu-out-0506.google.com [72.14.214.227]) by mx1.FreeBSD.org (Postfix) with ESMTP id E61AD43D5F for ; Wed, 27 Sep 2006 14:29:22 +0000 (GMT) (envelope-from swhetzel@gmail.com) Received: by hu-out-0506.google.com with SMTP id 34so648292hui for ; Wed, 27 Sep 2006 07:29:21 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=hntyFqLFG7NU6qSXXqV20ux/sI8/AAHHjwUDW/XIFCtCSXhOuiVosRvviIC/GHtzJc4PzLvm96W8C28dzqHK4nKSPfnrfxGix+pccaWl3Tyc4OQvS+/Wt+KidX2XEpQ6Cg2QLuDaVrU0pp545R7SiJycxIkgEn77/rH+J/kTQO0= Received: by 10.66.242.20 with SMTP id p20mr582436ugh; Wed, 27 Sep 2006 07:29:20 -0700 (PDT) Received: by 10.67.86.15 with HTTP; Wed, 27 Sep 2006 07:29:20 -0700 (PDT) Message-ID: <790a9fff0609270729y2c8c90d8q1b07daa68b46b00a@mail.gmail.com> Date: Wed, 27 Sep 2006 09:29:20 -0500 From: "Scot Hetzel" To: "Steve Watt" In-Reply-To: <200609270659.k8R6xKke008040@wattres.watt.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <200609270659.k8R6xKke008040@wattres.watt.com> Cc: "Philip M. Gollucci" , freebsd-ports@freebsd.org Subject: Re: p5-Apache-DBI 'make package' dependency strangeness 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, 27 Sep 2006 14:29:23 -0000 > I know there's magic that almost gets it right, because it was finding > my apache-2.2.3 dependency before (when I didn't specify APACHE_PORT), > but was trying to add an apache20 or apache13 dependency as well. > > Speaking of APACHE_PORT... Is it documented somewhere that that's the > variable needed for this stuff? It's not in the hints in > /usr/ports/Mk/bsd.apache.mk, and what I do see implies that > setting APACHE_VERSION to 22 should DTRT. > The reason why Apache 2.0 port is appearing in your dependancy list is because of the way the p5-Apache-DBI Makefile is written. If you look at bsd.apache.mk, and look at this section of code: .elif ${USE_APACHE:C/\.//:C/\+//:M[12][3210]} != "" AP_PORT_IS_MODULE= YES #### for backward compatibility .elif ${USE_APACHE:L} == yes . if defined(WITH_APACHE2) APACHE_PORT?= www/apache20 . else APACHE_PORT?= www/apache13 . endif APXS?= ${LOCALBASE}/sbin/apxs .if !defined(APACHE_COMPAT) BUILD_DEPENDS+= ${APXS}:${PORTSDIR}/${APACHE_PORT} RUN_DEPENDS+= ${APXS}:${PORTSDIR}/${APACHE_PORT} .endif #### End of backward compatibility When WITH_APACHE2 is defined, it sets the dependancy to the www/apache20 port, because it has defined APACHE_PORT, even though the APACHE_PORT variable gets overriden latter in bsd.apache.mk by the check for the currently installed apache port. To solve the problem in the p5-APACHE-DBI, you need to take a hint from the mod_perl2 port to define USE_APACHE=2.0+. If the current code in the p5-Apache-DBI port is changed to: .if defined(WITH_MODPERL2) USE_APACHE= 2.0+ RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/mod_perl2.pm:${PORTSDIR}/www/mod_perl2 .else USE_APACHE= yes RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/mod_perl.pm:${PORTSDIR}/www/mod_perl .endif .include Then to build the port for mod_perl2, you just build it as: make -DWITH_MODPERL2 Also setting APACHE_VERSION=22 does nothing, as it gets overriden in bsd.apache.mk. Scot