svn commit: r289705 - head/share/mk

Bryan Drewery bdrewery at FreeBSD.org
Wed Oct 21 16:24:45 UTC 2015


Author: bdrewery
Date: Wed Oct 21 16:24:44 2015
New Revision: 289705
URL: https://svnweb.freebsd.org/changeset/base/289705

Log:
  Remove indirection of _sub target for using _SUBDIR.
  
  This reverts r266473 as the need for it, working around .MAKE and '+'
  issues, is no longer needed after r289460.  This avoids extra log
  output in -j builds of '-- _sub.TARGET --' that are redundant with the
  '-- TARGET --' and '-- TARGET_subdir_DIR --' entries already showing.
  
  r266473 also made a subtle change in the ordering of _SUBDIR handling.  Before
  the change, SUBDIRS were recursed into after building the TARGET due to the
  .USE of _SUBDIR *appending* the commands onto the TARGET.  After the change
  though the indirection caused TARGET to depend on _sub.TARGET which had the
  _SUBDIR handling in it.  This TARGET would run after recursing.  However, the
  SUBDIR_PARALLEL handling from r263778 has this ordering as well.  Since
  this has so far not been a problem, for now make this behavior for
  non-SUBDIR_PARALLEL use of _SUBDIR explicit by using .USEBEFORE.
  Further research may change this back to .USE as well as the
  SUBDIR_PARALLEL handling and bsd.progs.mk recursing.
  
  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	Wed Oct 21 15:41:16 2015	(r289704)
+++ head/share/mk/bsd.subdir.mk	Wed Oct 21 16:24:44 2015	(r289705)
@@ -72,9 +72,9 @@ _SUBDIR_SH=	\
 		cd ${.CURDIR}/$${dir}; \
 		${MAKE} $${target} DIRPRFX=${DIRPRFX}$${dir}/
 
-_SUBDIR: .USE .MAKE
+_SUBDIR: .USEBEFORE
 .if defined(SUBDIR) && !empty(SUBDIR) && !defined(NO_SUBDIR)
-	@${_+_}target=${.TARGET:S,realinstall,install,:S,^_sub.,,}; \
+	@${_+_}target=${.TARGET:S,realinstall,install,}; \
 	    for dir in ${SUBDIR:N.WAIT}; do ${_SUBDIR_SH}; done
 .endif
 
@@ -107,8 +107,7 @@ ${__target}_subdir_${__dir}: .PHONY .MAK
 .endfor
 ${__target}: ${__subdir_targets}
 .else
-${__target}: _sub.${__target}
-_sub.${__target}: _SUBDIR
+${__target}: _SUBDIR
 .endif
 .endfor
 
@@ -119,8 +118,7 @@ _sub.${__target}: _SUBDIR
 .for __stage in build install
 ${__stage}${__target}:
 .if make(${__stage}${__target})
-${__stage}${__target}: _sub.${__stage}${__target}
-_sub.${__stage}${__target}: _SUBDIR
+${__stage}${__target}: _SUBDIR
 .endif
 .endfor
 .if !target(${__target})


More information about the svn-src-all mailing list