svn commit: r276050 - stable/10/share/mk
Garrett Cooper
ngie at FreeBSD.org
Mon Dec 22 00:50:09 UTC 2014
Author: ngie
Date: Mon Dec 22 00:50:08 2014
New Revision: 276050
URL: https://svnweb.freebsd.org/changeset/base/276050
Log:
MFC r273803,r273810:
r273803:
Filter out TESTS_SUBDIRS already added to SUBDIR instead of blindly
appending the TESTS_SUBDIRS variable to SUBDIR
Duplicate directory entries can cause unexpected side effects, like
installing the same files multiple times. This can be easily
reproduced via the following testcase prior to this commit:
SUBDIR= dir
TESTS_SUBDIRS+= dir
.include <bsd.test.mk>
Sponsored by: EMC / Isilon Storage Division
r273810:
Fix the logic inversion in the previous commit by ensuring that the matched
expression (:M) is empty, not the not matched (:N) is empty. The former case
means we have not found the TEST_SUBDIR value in SUBDIR
Reported by: rodrigc
Pointyhat to: me (did not use a clean install root)
Sponsored by: EMC / Isilon Storage Division
Modified:
stable/10/share/mk/bsd.test.mk
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/share/mk/bsd.test.mk
==============================================================================
--- stable/10/share/mk/bsd.test.mk Mon Dec 22 00:50:01 2014 (r276049)
+++ stable/10/share/mk/bsd.test.mk Mon Dec 22 00:50:08 2014 (r276050)
@@ -54,9 +54,11 @@ _TESTS=
.include <plain.test.mk>
.include <tap.test.mk>
-.if !empty(TESTS_SUBDIRS)
-SUBDIR+= ${TESTS_SUBDIRS}
+.for ts in ${TESTS_SUBDIRS}
+.if empty(SUBDIR:M${ts})
+SUBDIR+= ${ts}
.endif
+.endfor
# it is rare for test cases to have man pages
.if !defined(MAN)
More information about the svn-src-all
mailing list