diff options
author | jlam <jlam> | 2004-08-28 06:26:41 +0000 |
---|---|---|
committer | jlam <jlam> | 2004-08-28 06:26:41 +0000 |
commit | e5ea9abc4b79034b8660704905727b5821d65453 (patch) | |
tree | 4e8ef1698604d94f04d9317b6477d5a59503ed49 /regress | |
parent | e0a4221295081531342739dbff426a9cfc6c17d0 (diff) | |
download | pkgsrc-e5ea9abc4b79034b8660704905727b5821d65453.tar.gz |
Add some more tests for "l" and "rm" BUILDLINK_TRANSFORM commands.
Diffstat (limited to 'regress')
-rw-r--r-- | regress/buildlink-transform/Makefile | 17 | ||||
-rw-r--r-- | regress/buildlink-transform/tests/lib-expand.mk | 8 | ||||
-rw-r--r-- | regress/buildlink-transform/tests/preserve-option.mk | 8 | ||||
-rw-r--r-- | regress/buildlink-transform/tests/remove-option.mk | 8 |
4 files changed, 38 insertions, 3 deletions
diff --git a/regress/buildlink-transform/Makefile b/regress/buildlink-transform/Makefile index f998e076595..aa2eb9158ff 100644 --- a/regress/buildlink-transform/Makefile +++ b/regress/buildlink-transform/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.5 2004/08/28 02:35:41 jlam Exp $ +# $NetBSD: Makefile,v 1.6 2004/08/28 06:26:41 jlam Exp $ # # Run many buildlink transform tests in a single regression test to avoid # having to keep creating the wrapper scripts over and over again. @@ -20,6 +20,12 @@ NO_BUILD= yes NO_INSTALL= yes NO_PACKAGE= yes +# Remove GCC optimization options. +BUILDLINK_TRANSFORM+= rm:-O[0-9]* + +# Convert "-lreadline" into "-ledit -ltermcap -lm". +BUILDLINK_TRANSFORM+= l:readline:edit:termcap:m + REGRESS_ENV= PATH=${PATH} #REGRESS_ENV+= WRAPPER_DEBUG=yes @@ -46,8 +52,13 @@ TEST_RESULT= runtest=`${SETENV} ${REGRESS_ENV} regress $$test`; \ ${ECHO} "(${.TARGET}) got: $$runtest"; \ ${ECHO} "(${.TARGET}) expected: $$expected"; \ case $$runtest in \ - $$expected) ;; \ - *) exit 1 ;; \ + $$expected) \ + ${ECHO} "(${.TARGET}) result: PASS"; \ + ;; \ + *) \ + ${ECHO} "(${.TARGET}) result: FAIL"; \ + exit 1; \ + ;; \ esac TEST_DIR= ${.CURDIR}/tests diff --git a/regress/buildlink-transform/tests/lib-expand.mk b/regress/buildlink-transform/tests/lib-expand.mk new file mode 100644 index 00000000000..2c9dea8f9de --- /dev/null +++ b/regress/buildlink-transform/tests/lib-expand.mk @@ -0,0 +1,8 @@ +# $NetBSD: lib-expand.mk,v 1.1 2004/08/28 06:26:41 jlam Exp $ + +.PHONY: lib-expand +do-regress: lib-expand +lib-expand: + @test="-lreadline"; \ + expected="-ledit -ltermcap -lm"; \ + ${TEST_RESULT} diff --git a/regress/buildlink-transform/tests/preserve-option.mk b/regress/buildlink-transform/tests/preserve-option.mk new file mode 100644 index 00000000000..330aed69a25 --- /dev/null +++ b/regress/buildlink-transform/tests/preserve-option.mk @@ -0,0 +1,8 @@ +# $NetBSD: preserve-option.mk,v 1.1 2004/08/28 06:26:41 jlam Exp $ + +.PHONY: preserve-option +do-regress: preserve-option +preserve-option: + @test="-O2ABC"; \ + expected="-O2ABC"; \ + ${TEST_RESULT} diff --git a/regress/buildlink-transform/tests/remove-option.mk b/regress/buildlink-transform/tests/remove-option.mk new file mode 100644 index 00000000000..338f48550a9 --- /dev/null +++ b/regress/buildlink-transform/tests/remove-option.mk @@ -0,0 +1,8 @@ +# $NetBSD: remove-option.mk,v 1.1 2004/08/28 06:26:41 jlam Exp $ + +.PHONY: remove-option +do-regress: remove-option +remove-option: + @test="-O2 -O5 -O9"; \ + expected=""; \ + ${TEST_RESULT} |