svn commit: r262849 - in stable/10: . contrib/atf contrib/atf/atf-c contrib/atf/atf-c++ contrib/atf/atf-c++/detail contrib/atf/atf-sh etc/mtree lib/atf lib/atf/libatf-c lib/atf/libatf-c++ lib/atf/l...

Julio Merino jmmv at FreeBSD.org
Thu Mar 6 13:20:43 UTC 2014


Author: jmmv
Date: Thu Mar  6 13:20:38 2014
New Revision: 262849
URL: http://svnweb.freebsd.org/changeset/base/262849

Log:
  MFC various fixes for the ATF tests.
  
  - r260505 Allow tests to provide a Kyuafile when they relied on auto-generation.
  - r260525 Respect the original layout of the atf-{c,c++} tests.
  - r260526 Fix path to the process_helpers for the libatf-c++ tests.
  - r260576 Generate and install pkg-config files for atf.
  - r260577 Add atf pkg-config files from the vendor branch.
  - r260584 Prevent misc_helpers from running as a test.

Added:
  stable/10/contrib/atf/atf-c++/atf-c++.pc.in
     - copied unchanged from r260577, head/contrib/atf/atf-c++/atf-c++.pc.in
  stable/10/contrib/atf/atf-c/atf-c.pc.in
     - copied unchanged from r260577, head/contrib/atf/atf-c/atf-c.pc.in
  stable/10/contrib/atf/atf-sh/atf-sh.pc.in
     - copied unchanged from r260577, head/contrib/atf/atf-sh/atf-sh.pc.in
  stable/10/lib/atf/common.mk
     - copied unchanged from r260576, head/lib/atf/common.mk
  stable/10/lib/atf/libatf-c++/tests/Makefile.inc
     - copied unchanged from r260525, head/lib/atf/libatf-c++/tests/Makefile.inc
  stable/10/lib/atf/libatf-c++/tests/detail/
     - copied from r260525, head/lib/atf/libatf-c++/tests/detail/
  stable/10/lib/atf/libatf-c/tests/Makefile.inc
     - copied unchanged from r260525, head/lib/atf/libatf-c/tests/Makefile.inc
  stable/10/lib/atf/libatf-c/tests/detail/
     - copied from r260525, head/lib/atf/libatf-c/tests/detail/
Modified:
  stable/10/UPDATING
  stable/10/contrib/atf/FREEBSD-Xlist
  stable/10/contrib/atf/atf-c++/detail/test_helpers.cpp
  stable/10/etc/mtree/BSD.tests.dist
  stable/10/lib/atf/Makefile.inc
  stable/10/lib/atf/libatf-c++/Makefile
  stable/10/lib/atf/libatf-c++/tests/Makefile
  stable/10/lib/atf/libatf-c/Makefile
  stable/10/lib/atf/libatf-c/tests/Makefile
  stable/10/share/mk/bsd.test.mk
  stable/10/tools/build/mk/OptionalObsoleteFiles.inc
  stable/10/usr.bin/atf/atf-sh/Makefile
  stable/10/usr.bin/atf/atf-sh/tests/Makefile
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/UPDATING
==============================================================================
--- stable/10/UPDATING	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/UPDATING	Thu Mar  6 13:20:38 2014	(r262849)
@@ -17,6 +17,14 @@ stable/10, and then rebuild without this
 older version of current is a bit fragile.
 
 
+20140306:
+	If a Makefile in a tests/ directory was auto-generating a Kyuafile
+	instead of providing an explicit one, this would prevent such
+	Makefile from providing its own Kyuafile in the future during
+	NO_CLEAN builds.  This has been fixed in the Makefiles but manual
+	intervention is needed to clean an objdir if you use NO_CLEAN:
+	  # find /usr/obj -name Kyuafile | xargs rm -f
+
 20140303:
 	OpenSSH will now ignore errors caused by kernel lacking of Capsicum
 	capability mode support.  Please note that enabling the feature in

Modified: stable/10/contrib/atf/FREEBSD-Xlist
==============================================================================
--- stable/10/contrib/atf/FREEBSD-Xlist	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/contrib/atf/FREEBSD-Xlist	Thu Mar  6 13:20:38 2014	(r262849)
@@ -8,7 +8,6 @@ Makefile*
 aclocal.m4
 admin/
 atf-*/atf-*.m4
-atf-*/atf-*.pc.in
 atf-config/
 atf-report/
 atf-run/

Copied: stable/10/contrib/atf/atf-c++/atf-c++.pc.in (from r260577, head/contrib/atf/atf-c++/atf-c++.pc.in)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/contrib/atf/atf-c++/atf-c++.pc.in	Thu Mar  6 13:20:38 2014	(r262849, copy of r260577, head/contrib/atf/atf-c++/atf-c++.pc.in)
@@ -0,0 +1,11 @@
+# ATF pkg-config file
+
+cxx=__CXX__
+includedir=__INCLUDEDIR__
+libdir=__LIBDIR__
+
+Name: atf-c++
+Description: Automated Testing Framework (C++ binding)
+Version: __ATF_VERSION__
+Cflags: -I${includedir}
+Libs: -L${libdir} -latf-c++ -latf-c

Modified: stable/10/contrib/atf/atf-c++/detail/test_helpers.cpp
==============================================================================
--- stable/10/contrib/atf/atf-c++/detail/test_helpers.cpp	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/contrib/atf/atf-c++/detail/test_helpers.cpp	Thu Mar  6 13:20:38 2014	(r262849)
@@ -40,6 +40,18 @@
 #include "process.hpp"
 #include "test_helpers.hpp"
 
+// Path to the directory containing the libatf-c tests, used to locate the
+// process_helpers program.  If NULL (the default), the code will use a
+// relative path.  Otherwise, the provided path will be used; this is so
+// that we can locate the helpers binary if the installation uses a
+// different layout than the one we provide (as is the case in FreeBSD).
+#if defined(ATF_C_TESTS_BASE)
+static const char* atf_c_tests_base = ATF_C_TESTS_BASE;
+#else
+static const char* atf_c_tests_base = NULL;
+#endif
+#undef ATF_C_TESTS_BASE
+
 void
 build_check_cxx_o_aux(const atf::fs::path& sfile, const char* failmsg,
                       const bool expect_pass)
@@ -80,12 +92,17 @@ header_check(const char *hdrname)
 atf::fs::path
 get_process_helpers_path(const atf::tests::tc& tc, bool is_detail)
 {
-    if (is_detail)
-        return atf::fs::path(tc.get_config_var("srcdir")) /
-               ".." / ".." / "atf-c" / "detail" / "process_helpers";
-    else
-        return atf::fs::path(tc.get_config_var("srcdir")) /
-               ".." / "atf-c" / "detail" / "process_helpers";
+    const char* helper = "detail/process_helpers";
+    if (atf_c_tests_base == NULL) {
+        if (is_detail)
+            return atf::fs::path(tc.get_config_var("srcdir")) /
+                   ".." / ".." / "atf-c" / helper;
+        else
+            return atf::fs::path(tc.get_config_var("srcdir")) /
+                   ".." / "atf-c" / helper;
+    } else {
+        return atf::fs::path(atf_c_tests_base) / helper;
+    }
 }
 
 void

Copied: stable/10/contrib/atf/atf-c/atf-c.pc.in (from r260577, head/contrib/atf/atf-c/atf-c.pc.in)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/contrib/atf/atf-c/atf-c.pc.in	Thu Mar  6 13:20:38 2014	(r262849, copy of r260577, head/contrib/atf/atf-c/atf-c.pc.in)
@@ -0,0 +1,11 @@
+# ATF pkg-config file
+
+cc=__CC__
+includedir=__INCLUDEDIR__
+libdir=__LIBDIR__
+
+Name: atf-c
+Description: Automated Testing Framework (C binding)
+Version: __ATF_VERSION__
+Cflags: -I${includedir}
+Libs: -L${libdir} -latf-c

Copied: stable/10/contrib/atf/atf-sh/atf-sh.pc.in (from r260577, head/contrib/atf/atf-sh/atf-sh.pc.in)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/contrib/atf/atf-sh/atf-sh.pc.in	Thu Mar  6 13:20:38 2014	(r262849, copy of r260577, head/contrib/atf/atf-sh/atf-sh.pc.in)
@@ -0,0 +1,8 @@
+# ATF pkg-config file
+
+exec_prefix=__EXEC_PREFIX__
+interpreter=${exec_prefix}/bin/atf-sh
+
+Name: atf-sh
+Description: Automated Testing Framework (POSIX shell binding)
+Version: __ATF_VERSION__

Modified: stable/10/etc/mtree/BSD.tests.dist
==============================================================================
--- stable/10/etc/mtree/BSD.tests.dist	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/etc/mtree/BSD.tests.dist	Thu Mar  6 13:20:38 2014	(r262849)
@@ -23,8 +23,12 @@
         lib
             atf
                 libatf-c
+                    detail
+                    ..
                 ..
                 libatf-c++
+                    detail
+                    ..
                 ..
                 test-programs
                 ..

Modified: stable/10/lib/atf/Makefile.inc
==============================================================================
--- stable/10/lib/atf/Makefile.inc	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/lib/atf/Makefile.inc	Thu Mar  6 13:20:38 2014	(r262849)
@@ -38,6 +38,7 @@ CFLAGS+=	-DATF_BUILD_CPPFLAGS='"${_CPPFL
 CFLAGS+=	-DATF_BUILD_CXX='"${CXX}"'
 CFLAGS+=	-DATF_BUILD_CXXFLAGS='"${_CXXFLAGS}"'
 CFLAGS+=	-DATF_CONFDIR='"${CONFDIR}/atf"'
+CFLAGS+=	-DATF_C_TESTS_BASE='"${TESTSBASE}/lib/atf/libatf-c"'
 CFLAGS+=	-DATF_INCLUDEDIR='"${INCLUDEDIR}"'
 CFLAGS+=	-DATF_LIBDIR='"${LIBDIR}"'
 CFLAGS+=	-DATF_LIBEXECDIR='"${LIBEXECDIR}"'

Copied: stable/10/lib/atf/common.mk (from r260576, head/lib/atf/common.mk)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/lib/atf/common.mk	Thu Mar  6 13:20:38 2014	(r262849, copy of r260576, head/lib/atf/common.mk)
@@ -0,0 +1,19 @@
+# $FreeBSD$
+#
+# Common Makefile code for all components of ATF.
+#
+
+.if !defined(ATF)
+.error "ATF must be defined and point to the contrib/atf directory"
+.endif
+
+# Depend on the atf-version target to generate a file that contains the
+# version number of the currently imported ATF release and that only
+# changes on new imports.
+atf-version: atf-version-real
+	@cmp -s atf-version atf-version-real \
+	    || cp atf-version-real atf-version
+atf-version-real: .PHONY
+	@grep 'define VERSION' ${ATF}/bconfig.h \
+	    | cut -d '"' -f 2 >atf-version-real
+CLEANFILES+= atf-version atf-version-real

Modified: stable/10/lib/atf/libatf-c++/Makefile
==============================================================================
--- stable/10/lib/atf/libatf-c++/Makefile	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/lib/atf/libatf-c++/Makefile	Thu Mar  6 13:20:38 2014	(r262849)
@@ -76,8 +76,21 @@ INCSDIR_atf-c++.hpp= ${INCLUDEDIR}
 
 MAN=		atf-c++-api.3
 
+all: atf-c++.pc
+atf-c++.pc: atf-c++.pc.in atf-version
+	sed -e 's,__CXX__,${CXX},g' \
+	    -e 's,__INCLUDEDIR__,${INCLUDEDIR},g' \
+	    -e 's,__LIBDIR__,${LIBDIR},g' \
+	    -e "s,__ATF_VERSION__,$$(cat atf-version),g" \
+	    <${ATF}/atf-c++/atf-c++.pc.in >atf-c++.pc
+
+beforeinstall:
+	${INSTALL} -C -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \
+		atf-c++.pc ${DESTDIR}${LIBDATADIR}/pkgconfig
+
 .if ${MK_TESTS} != "no"
 SUBDIR=		tests
 .endif
 
+.include "../common.mk"
 .include <bsd.lib.mk>

Modified: stable/10/lib/atf/libatf-c++/tests/Makefile
==============================================================================
--- stable/10/lib/atf/libatf-c++/tests/Makefile	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/lib/atf/libatf-c++/tests/Makefile	Thu Mar  6 13:20:38 2014	(r262849)
@@ -3,6 +3,7 @@
 .include <bsd.init.mk>
 
 TESTSDIR=	${TESTSBASE}/lib/atf/libatf-c++
+TESTS_SUBDIRS=	detail
 
 ATF=		${.CURDIR:H:H:H:H}/contrib/atf
 .PATH:		${ATF}/atf-c++
@@ -14,7 +15,6 @@ FILESDIR=	${TESTSDIR}
 FILES=		macros_hpp_test.cpp
 FILES+=		unused_test.cpp
 
-# Tests in atf-c++.
 .for _T in	atf_c++_test \
 		build_test \
 		check_test \
@@ -28,20 +28,4 @@ SRCS.${_T}=	${_T}.cpp test_helpers.cpp
 
 ATF_TESTS_SH=	pkg_config_test
 
-# Tests in atf-c++/detail.
-
-.for _T in	application_test \
-		env_test \
-		exceptions_test \
-		expand_test \
-		fs_test \
-		parser_test \
-		process_test \
-		sanity_test \
-		text_test \
-		ui_test
-ATF_TESTS_CXX+=	${_T}
-SRCS.${_T}=	${_T}.cpp test_helpers.cpp
-.endfor
-
 .include <atf.test.mk>

Copied: stable/10/lib/atf/libatf-c++/tests/Makefile.inc (from r260525, head/lib/atf/libatf-c++/tests/Makefile.inc)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/lib/atf/libatf-c++/tests/Makefile.inc	Thu Mar  6 13:20:38 2014	(r262849, copy of r260525, head/lib/atf/libatf-c++/tests/Makefile.inc)
@@ -0,0 +1,3 @@
+# $FreeBSD$
+
+.include "../Makefile.inc"

Modified: stable/10/lib/atf/libatf-c/Makefile
==============================================================================
--- stable/10/lib/atf/libatf-c/Makefile	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/lib/atf/libatf-c/Makefile	Thu Mar  6 13:20:38 2014	(r262849)
@@ -74,8 +74,21 @@ INCSDIR_atf-c.h= ${INCLUDEDIR}
 
 MAN=		atf-c-api.3
 
+all: atf-c.pc
+atf-c.pc: atf-c.pc.in atf-version
+	sed -e 's,__CC__,${CC},g' \
+	    -e 's,__INCLUDEDIR__,${INCLUDEDIR},g' \
+	    -e 's,__LIBDIR__,${LIBDIR},g' \
+	    -e "s,__ATF_VERSION__,$$(cat atf-version),g" \
+	    <${ATF}/atf-c/atf-c.pc.in >atf-c.pc
+
+beforeinstall:
+	${INSTALL} -C -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \
+		atf-c.pc ${DESTDIR}${LIBDATADIR}/pkgconfig
+
 .if ${MK_TESTS} != "no"
 SUBDIR=		tests
 .endif
 
+.include "../common.mk"
 .include <bsd.lib.mk>

Modified: stable/10/lib/atf/libatf-c/tests/Makefile
==============================================================================
--- stable/10/lib/atf/libatf-c/tests/Makefile	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/lib/atf/libatf-c/tests/Makefile	Thu Mar  6 13:20:38 2014	(r262849)
@@ -3,6 +3,7 @@
 .include <bsd.init.mk>
 
 TESTSDIR=	${TESTSBASE}/lib/atf/libatf-c
+TESTS_SUBDIRS=	detail
 
 ATF=		${.CURDIR:H:H:H:H}/contrib/atf
 .PATH:		${ATF}/atf-c
@@ -19,8 +20,6 @@ FILESDIR=	${TESTSDIR}
 FILES=		macros_h_test.c
 FILES+=		unused_test.c
 
-# Tests in atf-c.
-
 .for _T in	atf_c_test \
 		build_test \
 		check_test \
@@ -36,24 +35,4 @@ SRCS.${_T}=	${_T}.c test_helpers.c
 
 ATF_TESTS_SH=	pkg_config_test
 
-# Tests in atf-c/detail.
-
-.for _T in	dynstr_test \
-		env_test \
-		fs_test \
-		list_test \
-		map_test \
-		process_test \
-		sanity_test \
-		text_test \
-		user_test
-ATF_TESTS_C+=	${_T}
-SRCS.${_T}=	${_T}.c test_helpers.c
-.endfor
-
-PROGS+=		process_helpers
-SRCS.process_helpers=	process_helpers.c
-MAN.process_helpers=	# defined
-BINDIR.process_helpers=	${TESTSDIR}
-
 .include <atf.test.mk>

Copied: stable/10/lib/atf/libatf-c/tests/Makefile.inc (from r260525, head/lib/atf/libatf-c/tests/Makefile.inc)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ stable/10/lib/atf/libatf-c/tests/Makefile.inc	Thu Mar  6 13:20:38 2014	(r262849, copy of r260525, head/lib/atf/libatf-c/tests/Makefile.inc)
@@ -0,0 +1,3 @@
+# $FreeBSD$
+
+.include "../Makefile.inc"

Modified: stable/10/share/mk/bsd.test.mk
==============================================================================
--- stable/10/share/mk/bsd.test.mk	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/share/mk/bsd.test.mk	Thu Mar  6 13:20:38 2014	(r262849)
@@ -79,14 +79,20 @@ WITHOUT_MAN=yes
 PROG_VARS+= BINDIR
 PROGS_TARGETS+= install
 
-.if ${KYUAFILE:tl} != "no"
+.if ${KYUAFILE:tl} == "yes"
 FILES+=	Kyuafile
 FILESDIR_Kyuafile= ${TESTSDIR}
 
-.if ${KYUAFILE:tl} == "auto"
-CLEANFILES+= Kyuafile Kyuafile.tmp
+CLEANFILES+= Kyuafile.auto Kyuafile.auto.tmp
+.elif ${KYUAFILE:tl} == "auto"
+FILES+=	Kyuafile.auto
+FILESDIR_Kyuafile.auto= ${TESTSDIR}
+FILESNAME_Kyuafile.auto= Kyuafile
 
-Kyuafile: Makefile
+CLEANFILES+= Kyuafile.auto Kyuafile.auto.tmp
+
+.NOPATH: Kyuafile.auto
+Kyuafile.auto: Makefile
 	@{ \
 	    echo '-- Automatically generated by bsd.test.mk.'; \
 	    echo; \
@@ -94,16 +100,15 @@ Kyuafile: Makefile
 	    echo; \
 	    echo 'test_suite("${TESTSUITE}")'; \
             echo; \
-	} >Kyuafile.tmp
+	} >Kyuafile.auto.tmp
 .for _T in ${_TESTS}
 	@echo "${TEST_INTERFACE.${_T}}_test_program{name=\"${_T}\"}" \
-	    >>Kyuafile.tmp
+	    >>Kyuafile.auto.tmp
 .endfor
 .for _T in ${TESTS_SUBDIRS:N.WAIT}
-	@echo "include(\"${_T}/Kyuafile\")" >>Kyuafile.tmp
+	@echo "include(\"${_T}/Kyuafile\")" >>Kyuafile.auto.tmp
 .endfor
-	@mv Kyuafile.tmp Kyuafile
-.endif
+	@mv Kyuafile.auto.tmp Kyuafile.auto
 .endif
 
 KYUA?= ${KYUA_PREFIX}/bin/kyua

Modified: stable/10/tools/build/mk/OptionalObsoleteFiles.inc
==============================================================================
--- stable/10/tools/build/mk/OptionalObsoleteFiles.inc	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/tools/build/mk/OptionalObsoleteFiles.inc	Thu Mar  6 13:20:38 2014	(r262849)
@@ -4102,6 +4102,26 @@ OLD_FILES+=usr/share/man/man8/telnetd.8.
 .if ${MK_TESTS} == yes
 OLD_FILES+=usr/tests/lib/atf/libatf-c/test_helpers_test
 OLD_FILES+=usr/tests/lib/atf/test-programs/fork_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/application_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/env_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/exceptions_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/expand_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/fs_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/parser_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/process_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/sanity_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/text_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c++/ui_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/dynstr_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/env_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/fs_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/list_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/map_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/process_helpers
+OLD_FILES+=usr/tests/lib/atf/libatf-c/process_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/sanity_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/text_test
+OLD_FILES+=usr/tests/lib/atf/libatf-c/user_test
 .else
 # ATF libraries.
 OLD_FILES+=usr/bin/atf-sh

Modified: stable/10/usr.bin/atf/atf-sh/Makefile
==============================================================================
--- stable/10/usr.bin/atf/atf-sh/Makefile	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/usr.bin/atf/atf-sh/Makefile	Thu Mar  6 13:20:38 2014	(r262849)
@@ -45,8 +45,19 @@ FILESGROUPS=	SUBR
 SUBRDIR=	${SHAREDIR}/atf
 SUBR=		libatf-sh.subr
 
+all: atf-sh.pc
+atf-sh.pc: atf-sh.pc.in atf-version
+	sed -e 's,__EXEC_PREFIX__,/usr,g' \
+	    -e "s,__ATF_VERSION__,$$(cat atf-version),g" \
+	    <${ATF}/atf-sh/atf-sh.pc.in >atf-sh.pc
+
+beforeinstall:
+	${INSTALL} -C -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \
+		atf-sh.pc ${DESTDIR}${LIBDATADIR}/pkgconfig
+
 .if ${MK_TESTS} != "no"
 SUBDIR+=	tests
 .endif
 
+.include "../../../lib/atf/common.mk"
 .include <bsd.prog.mk>

Modified: stable/10/usr.bin/atf/atf-sh/tests/Makefile
==============================================================================
--- stable/10/usr.bin/atf/atf-sh/tests/Makefile	Thu Mar  6 13:15:53 2014	(r262848)
+++ stable/10/usr.bin/atf/atf-sh/tests/Makefile	Thu Mar  6 13:20:38 2014	(r262849)
@@ -10,9 +10,17 @@ ATF=		${.CURDIR:H:H:H:H}/contrib/atf
 ATF_TESTS_SH+=	atf_check_test
 ATF_TESTS_SH+=	config_test
 ATF_TESTS_SH+=	integration_test
-ATF_TESTS_SH+=	misc_helpers
 ATF_TESTS_SH+=	normalize_test
 ATF_TESTS_SH+=	tc_test
 ATF_TESTS_SH+=	tp_test
 
+SCRIPTS+=		misc_helpers
+SCRIPTSDIR_misc_helpers=${TESTSDIR}
+CLEANFILES+=		misc_helpers misc_helpers.tmp
+misc_helpers: misc_helpers.sh
+	echo '#! /usr/bin/atf-sh' >${.TARGET}.tmp
+	cat ${.ALLSRC} >>${.TARGET}.tmp
+	chmod +x ${.TARGET}.tmp
+	mv ${.TARGET}.tmp ${.TARGET}
+
 .include <atf.test.mk>


More information about the svn-src-all mailing list