ports/56096: setting WRKDIRPREFIX breaks dependanies recording in ports

Mike Bristow mike at urgle.com
Thu Aug 28 20:20:16 UTC 2003


>Number:         56096
>Category:       ports
>Synopsis:       setting WRKDIRPREFIX breaks dependanies recording in ports
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Aug 28 13:20:13 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator:     Mike Bristow
>Release:        FreeBSD 5.1-RELEASE-p2 i386
>Organization:
>Environment:
System: FreeBSD guylian.urgle.com 5.1-RELEASE-p2 FreeBSD 5.1-RELEASE-p2 #0: Mon Aug 11 16:07:06 BST 2003 root at guylian.urgle.com:/usr/obj/usr/src/sys/SMP i386


	
>Description:

There is a small bug in bsd.port.mk, that only affects you if you have
WRKDIRPREFIX set.  Basically, when installing the port, PKG_ARGS seems
to be used when the current working directory is
${WRKDIRPREFIX}/${.CURDIR}, which means that "make package-depends" is
run from that directory.
                                                                                
Given that there's no Makefile there, this isn't ideal :)
                                                                                

>How-To-Repeat:

Set WRKDIRPREFIX to (eg) /usr/obj, build port, observe that port has no
dependancies marked.

This patch fixes the problem:

--- bsd.port.mk.orig	Thu Aug 28 13:21:42 2003
+++ bsd.port.mk	Thu Aug 28 13:18:39 2003
@@ -1722,7 +1722,7 @@
 DISABLE_CONFLICTS=     YES
 .endif
 .if !defined(PKG_ARGS)
-PKG_ARGS=		-v -c -${COMMENT:Q} -d ${DESCR} -f ${TMPPLIST} -p ${PREFIX} -P "`${MAKE} package-depends | ${GREP} -v -E ${PKG_IGNORE_DEPENDS} | sort -u`" ${EXTRA_PKG_ARGS}
+PKG_ARGS=		-v -c -${COMMENT:Q} -d ${DESCR} -f ${TMPPLIST} -p ${PREFIX} -P "`${MAKE} -C ${.CURDIR} package-depends | ${GREP} -v -E ${PKG_IGNORE_DEPENDS} | sort -u`" ${EXTRA_PKG_ARGS}
 .if exists(${PKGINSTALL})
 PKG_ARGS+=		-i ${PKGINSTALL}
 .endif

>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list