diff options
-rw-r--r-- | regress/Makefile | 3 | ||||
-rw-r--r-- | regress/subst/Makefile | 31 | ||||
-rw-r--r-- | regress/subst/vars.mk | 5 |
3 files changed, 38 insertions, 1 deletions
diff --git a/regress/Makefile b/regress/Makefile index 7d9cd79bba7..d159a02a4d0 100644 --- a/regress/Makefile +++ b/regress/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.15 2006/09/06 03:37:54 ben Exp $ +# $NetBSD: Makefile,v 1.16 2007/03/07 21:22:20 rillig Exp $ # COMMENT= Regression tests for pkgsrc infrastructure @@ -15,6 +15,7 @@ SUBDIR+= make-quoting SUBDIR+= pkg-options SUBDIR+= pkgfail SUBDIR+= print-plist +SUBDIR+= subst SUBDIR+= tools .include "../mk/bsd.pkg.subdir.mk" diff --git a/regress/subst/Makefile b/regress/subst/Makefile new file mode 100644 index 00000000000..5fdc24e9ebd --- /dev/null +++ b/regress/subst/Makefile @@ -0,0 +1,31 @@ +# $NetBSD: Makefile,v 1.1 2007/03/07 21:22:20 rillig Exp $ +# + +DISTNAME= subst-1.0 +CATEGORIES= regress +DISTFILES= # none + +MAINTAINER= rillig@NetBSD.org +COMMENT= Test the SUBST framework + +NO_CHECKSUM= yes +WRKSRC= ${WRKDIR} +USE_TOOLS+= diff + +SUBST_CLASSES+= vars +SUBST_STAGE.vars= do-build +SUBST_FILES.vars= vars +SUBST_VARS.vars= PLAIN DQUOT SQUOT DELIM EVIL1 + +.include "${.PARSEDIR}/vars.mk" + +pre-build: + for v in ${SUBST_VARS.vars}; do echo "$$v=@$$v@"; done > ${WRKSRC}/vars + +do-build: + @${DO_NADA} + +post-build: + diff vars.mk ${WRKSRC}/vars + +.include "../../mk/bsd.pkg.mk" diff --git a/regress/subst/vars.mk b/regress/subst/vars.mk new file mode 100644 index 00000000000..739e6d7ce0a --- /dev/null +++ b/regress/subst/vars.mk @@ -0,0 +1,5 @@ +PLAIN=hello_world +DQUOT="hello world" +SQUOT='hello world' +DELIM=hello, world +EVIL1=h\ello \0\0\0 \\\"\' foo && bar |