Date: Mon, 8 Oct 2001 12:03:47 +1000 (EST) From: Edwin Groothuis <edwin@mavetju.org> To: FreeBSD-gnats-submit@freebsd.org Subject: ports/31113: bsd.ports.subdir.mk: remove NOCLEANDEPENDS from the /etc/make.conf Message-ID: <20011008020347.F07F12AA@k7.mavetju.org>
next in thread | raw e-mail | index | archive | help
>Number: 31113 >Category: ports >Synopsis: bsd.ports.subdir.mk: remove NOCLEANDEPENDS from the /etc/make.conf >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sun Oct 07 19:10:01 PDT 2001 >Closed-Date: >Last-Modified: >Originator: Edwin Groothuis >Release: FreeBSD 4.4-RELEASE i386 >Organization: - >Environment: System: FreeBSD k7.mavetju.org 4.4-RELEASE FreeBSD 4.4-RELEASE #0: Thu Oct 4 08:49:05 EST 2001 edwin@k7.mavetju.org:/usr/src/sys/compile/k7 i386 >Description: When using "make clean" in a directory below /usr/ports/*, default is to do a make clean for the dependant ports also. This is nice. When using "make clean" in /usr/ports or in a directory of /usr/ports/*, default is to do a make clean for the dependant ports also. This is not nice, because a lot of ports have the same dependencies, causing a *lot* of extra calls for "make clean"s which are not needed. The solution for this is to add NOCLEANDEPENDS=yes in /etc/make.conf. But then next time when you run "make clean" in a freshly cleaned ports-directory, it will not clean the dependencies (which is exactly what is wanted with putting it in /etc/make.conf). There is a problem here with the fact that /etc/make.conf is used for both the ports-directory makefile and the port-makefile. >How-To-Repeat: run "make clean" in /usr/ports >Fix: The solution for this "make clean" problem, possible together with other problems, is to be able to pass a variable from the bsd.ports.subdir.mk to the new port: --- bsd.port.subdir.mk.orig Mon Oct 8 11:29:20 2001 +++ bsd.port.subdir.mk Mon Oct 8 11:42:30 2001 @@ -21,6 +21,12 @@ # Each of the targets will execute the same target in the # subdirectories. # +# PORTARGS A variable for local arguments which are passed to the +# targets one directory below this. This is to be +# used when you have a variable in /etc/make.conf +# which is only used in the directories with the +# ports, not in the subdirectories above it. For +# example NOCLEANDEPENDS. # # +++ targets +++ # @@ -94,6 +100,10 @@ TARGETS+= reinstall TARGETS+= tags +.if make(clean) +PORTARGS+= NOCLEANDEPENDS=yes +.endif + .for __target in ${TARGETS} .if !target(${__target}) ${__target}: ${SUBDIR:S/$/.${__target}/} @@ -123,7 +133,7 @@ if [ "$$OK" = "" ]; then \ ${ECHO_MSG} "===> ${DIRPRFX}$${edir}"; \ cd ${.CURDIR}/$${edir}; \ - ${MAKE} -B ${.TARGET:E:realinstall=install} \ + ${MAKE} -B ${PORTARGS} ${.TARGET:E:realinstall=install} \ DIRPRFX=${DIRPRFX}$$edir/; \ fi This patch will introduce the possibility to add environment variables from the ports-directories-makefile towards the ports-makefile. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011008020347.F07F12AA>