]> xenbits.xensource.com Git - people/julieng/freebsd.git/commitdiff
Fix regression from using .USEBEFORE in _SUBDIR in r289705.
authorbdrewery <bdrewery@FreeBSD.org>
Thu, 29 Oct 2015 00:41:03 +0000 (00:41 +0000)
committerbdrewery <bdrewery@FreeBSD.org>
Thu, 29 Oct 2015 00:41:03 +0000 (00:41 +0000)
Using .USEBEFORE had the unintended side-effect of changing the directory for
the real target ran in the current directory.  For example this meant that
the 'make clean' would run in one of the SUBDIR.

Sponsored by: EMC / Isilon Storage Division
Pointyhat to: bdrewery

share/mk/bsd.subdir.mk

index 0a22fbec74a5b3006dadb5ada3cc366da7ef8a20..f9b9e979c2a694c583467d58e4af4b58c6c70630 100644 (file)
@@ -83,7 +83,7 @@ _SUBDIR_SH=   \
 _SUBDIR: .USEBEFORE
 .if defined(SUBDIR) && !empty(SUBDIR) && !defined(NO_SUBDIR)
        @${_+_}target=${.TARGET:S,realinstall,install,}; \
-           for dir in ${SUBDIR:N.WAIT}; do ${_SUBDIR_SH}; done
+           for dir in ${SUBDIR:N.WAIT}; do ( ${_SUBDIR_SH} ); done
 .endif
 
 ${SUBDIR:N.WAIT}: .PHONY .MAKE