Subject: Adding a "make regress" target
To: None <tech-toolchain@netbsd.org>
From: Alan Barrett <apb@cequrux.com>
List: tech-toolchain
Date: 10/02/2006 20:06:41
Does it make sense to add a "regress" target to src/foo/bar/Makefile
that runs the regression tests from src/regress/foo/bar?  Perhaps
it could be generalised to some magic in share/mk/*, but the
non-generalised version looks like this:

Index: src/bin/ps/Makefile
--- Makefile	19 Jun 2002 08:11:55 -0000	1.28
+++ Makefile	2 Oct 2006 18:01:15 -0000
@@ -8,4 +8,9 @@
 
 CWARNFLAGS+=	-Wno-format-y2k
 
+TEST_PS?=	${.OBJDIR}/ps
+regress:
+	cd ${.CURDIR}/../../regress/bin/ps \
+	&& TEST_PS=${TEST_PS:Q} ${MAKE} regress
+
 .include <bsd.prog.mk>

--apb (Alan Barrett)