Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 Jun 2012 12:48:29 GMT
From:      Alexander Pronin <apronin@me.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/169394: [ bsd.port.mk ] improper evaluation of config-recursive target
Message-ID:  <201206251248.q5PCmTig031209@red.freebsd.org>
Resent-Message-ID: <201206251250.q5PCo8gX077780@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         169394
>Category:       ports
>Synopsis:       [ bsd.port.mk ] improper evaluation of config-recursive target
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jun 25 12:50:08 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Alexander Pronin
>Release:        9.0
>Organization:
>Environment:
FreeBSD freebsd-STABLE 9.0-STABLE FreeBSD 9.0-STABLE #0 r234953: Fri May  4 10:53:12 MSK 2012     scher@freebsd-STABLE:/usr/obj/usr/src/sys/GENERIC  amd64
>Description:
It is assumed that if a user calls

%make config-recursive

then options of current port and all it's dependency ports will be processed, but

If this port(A) enables dependency port(Z) via options then $$(${ALL-DEPENDS-LIST}) will not include this port(Z), hence options of port(Z) will not be processed.
If dependency port(B) of port(A) enables another dependency port(X) then options of this port(X) will not be processed either.
>How-To-Repeat:

>Fix:
--- /Users/scher/tmp/config-recursive/bsd.port.mk	2012-06-21 22:53:45.000000000 +0400
+++ /Users/scher/tmp/config-recursive/bsd.port.mk-fixed	2012-06-21 22:54:35.000000000 +0400
@@ -6110,8 +6110,8 @@
 
 .if !target(config-recursive)
-config-recursive:
+config-recursive: config-conditional
 	@${ECHO_MSG} "===> Setting user-specified options for ${PKGNAME} and dependencies";
-	@for dir in ${.CURDIR} $$(${ALL-DEPENDS-LIST}); do \
-		(cd $$dir; ${MAKE} config-conditional); \
+	@for dir in $$(${MAKE} run-depends-list build-depends-list | uniq); do \
+		(cd $$dir; ${MAKE} config-recursive); \
 	done
 .endif # config-recursive

Patch attached with submission follows:

--- bsd.port.mk	2012-06-21 22:53:45.000000000 +0400
+++ bsd.port.mk-fixed	2012-06-25 16:43:58.000000000 +0400
@@ -6110,8 +6110,8 @@
 
 .if !target(config-recursive)
-config-recursive:
+config-recursive: config-conditional
 	@${ECHO_MSG} "===> Setting user-specified options for ${PKGNAME} and dependencies";
-	@for dir in ${.CURDIR} $$(${ALL-DEPENDS-LIST}); do \
-		(cd $$dir; ${MAKE} config-conditional); \
+	@for dir in $$(${MAKE} run-depends-list build-depends-list | uniq); do \
+		(cd $$dir; ${MAKE} config-recursive); \
 	done
 .endif # config-recursive


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



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