diff options
author | rillig <rillig@pkgsrc.org> | 2006-07-11 05:03:11 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2006-07-11 05:03:11 +0000 |
commit | a60185601f07929dc2cd54dbefc31ac7afee6950 (patch) | |
tree | 6dac73484c7c4a3c3003b4ad5cc8350c3957a33c /regress/compiler | |
parent | dd7c830ba9b56cafe6c865afbfbf9e904dffee43 (diff) | |
download | pkgsrc-a60185601f07929dc2cd54dbefc31ac7afee6950.tar.gz |
Added a testcase for the pkgsrc compilers.
Diffstat (limited to 'regress/compiler')
-rw-r--r-- | regress/compiler/Makefile | 25 | ||||
-rw-r--r-- | regress/compiler/spec | 21 |
2 files changed, 46 insertions, 0 deletions
diff --git a/regress/compiler/Makefile b/regress/compiler/Makefile new file mode 100644 index 00000000000..431f486721a --- /dev/null +++ b/regress/compiler/Makefile @@ -0,0 +1,25 @@ +# $NetBSD: Makefile,v 1.1 2006/07/11 05:03:11 rillig Exp $ +# + +DISTNAME= compiler-1.0 +CATEGORIES= regress +MASTER_SITES= # none +DISTFILES= # none + +MAINTAINER= rillig@NetBSD.org +COMMENT= Tests whether the pkgsrc compilers work as expected + +NO_CHECKSUM= yes +WRKSRC= ${WRKDIR} +USE_TOOLS+= printf + +SRC_CMD= ${PRINTF} '\#if defined(__cplusplus)\nLANG: Cplus\n\#else\nLANG: Cplain\n\#endif\n' + +do-build: + # Test whether CPP is a C preprocessor. + ${SRC_CMD} | ${CPP} -DLANG=Cplain + # Test whether CXXCPP is a C++ preprocessor. + # CXXCPP is not (yet)? defined. + #${SRC_CMD} | ${CXXCPP} -DLANG=Cplus + +.include "../../mk/bsd.pkg.mk" diff --git a/regress/compiler/spec b/regress/compiler/spec new file mode 100644 index 00000000000..00c555f0d35 --- /dev/null +++ b/regress/compiler/spec @@ -0,0 +1,21 @@ +# $NetBSD: spec,v 1.1 2006/07/11 05:03:11 rillig Exp $ +# + +do_cleanup() { + + ${TEST_MAKE} "clean" +} + +do_test() { + + do_cleanup + + ${TEST_MAKE} 1>"${TEST_OUTFILE}" 2>&1 +} + +check_result() { + + exit_status "0" + output_require "^Cplain.*:.*Cplain" + #output_require "^Cplus.*:.*Cplus" +} |