From owner-svn-src-head@freebsd.org Tue Jan 19 22:42:08 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 852AAA872E2; Tue, 19 Jan 2016 22:42:08 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 600701B2B; Tue, 19 Jan 2016 22:42:08 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u0JMg7RI064663; Tue, 19 Jan 2016 22:42:07 GMT (envelope-from bdrewery@FreeBSD.org) Received: (from bdrewery@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u0JMg78k064662; Tue, 19 Jan 2016 22:42:07 GMT (envelope-from bdrewery@FreeBSD.org) Message-Id: <201601192242.u0JMg78k064662@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bdrewery set sender to bdrewery@FreeBSD.org using -f From: Bryan Drewery Date: Tue, 19 Jan 2016 22:42:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r294354 - head/share/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Jan 2016 22:42:08 -0000 Author: bdrewery Date: Tue Jan 19 22:42:07 2016 New Revision: 294354 URL: https://svnweb.freebsd.org/changeset/base/294354 Log: bsd.subdir.mk: Allow easier modification of [STANDALONE_]SUBDIR_TARGETS. This reworks r289254 and removes ALL_SUBDIR_TARGETS. Because there is an include guard in this file there is no need for LOCAL_ or ?= on SUBDIR_TARGETS or STANDALONE_SUBDIR_TARGETS. These can just be set via src.conf. By the time bsd.subdir.mk is included it will just append the values to the existing value and work fine. This allows a consistent way to append to these variables without introducing a LOCAL_ var for STANDALONE_SUBDIR_TARGETS or renaming the historical SUBDIR_TARGETS. Sponsored by: EMC / Isilon Storage Division Modified: head/share/mk/bsd.subdir.mk Modified: head/share/mk/bsd.subdir.mk ============================================================================== --- head/share/mk/bsd.subdir.mk Tue Jan 19 22:42:04 2016 (r294353) +++ head/share/mk/bsd.subdir.mk Tue Jan 19 22:42:07 2016 (r294354) @@ -25,27 +25,30 @@ # This is a variant of install, which will # put the stuff into the right "distribution". # -# See ALL_SUBDIR_TARGETS for list of targets that will recurse. -# Custom targets can be added to SUBDIR_TARGETS in src.conf. +# See SUBDIR_TARGETS for list of targets that will recurse. # # Targets defined in STANDALONE_SUBDIR_TARGETS will always be ran # with SUBDIR_PARALLEL and will not respect .WAIT or SUBDIR_DEPEND_ # values. # +# SUBDIR_TARGETS and STANDALONE_SUBDIR_TARGETS can be appended to +# via make.conf or src.conf. +# .if !target(____) ____: -ALL_SUBDIR_TARGETS= all all-man buildconfig buildfiles buildincludes \ - checkdpadd clean cleandepend cleandir cleanilinks \ - cleanobj depend distribute files includes installconfig \ - installfiles installincludes realinstall lint maninstall \ - manlint obj objlink regress tags \ - ${SUBDIR_TARGETS} +SUBDIR_TARGETS+= \ + all all-man buildconfig buildfiles buildincludes \ + checkdpadd clean cleandepend cleandir cleanilinks \ + cleanobj depend distribute files includes installconfig \ + installfiles installincludes realinstall lint maninstall \ + manlint obj objlink regress tags \ # Described above. -STANDALONE_SUBDIR_TARGETS?= obj checkdpadd clean cleandepend cleandir \ - cleanilinks cleanobj installconfig +STANDALONE_SUBDIR_TARGETS+= \ + obj checkdpadd clean cleandepend cleandir \ + cleanilinks cleanobj installconfig \ .include @@ -115,7 +118,7 @@ ${SUBDIR:N.WAIT}: .PHONY .MAKE dir=${.TARGET}; \ ${_SUBDIR_SH}; -.for __target in ${ALL_SUBDIR_TARGETS} +.for __target in ${SUBDIR_TARGETS} # Only recurse on directly-called targets. I.e., don't recurse on dependencies # such as 'install' becoming {before,real,after}install, just recurse # 'install'. Despite that, 'realinstall' is special due to ordering issues @@ -154,12 +157,12 @@ ${__target}: ${__subdir_targets} ${__target}: _SUBDIR .endif # SUBDIR_PARALLEL || _is_standalone_target .endif # make(${__target}) -.endfor # __target in ${ALL_SUBDIR_TARGETS} +.endfor # __target in ${SUBDIR_TARGETS} .endif # !target(_SUBDIR) # Ensure all targets exist -.for __target in ${ALL_SUBDIR_TARGETS} +.for __target in ${SUBDIR_TARGETS} .if !target(${__target}) ${__target}: .endif