[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
HEAD: pass environment to new test suite
From: |
Ralf Wildenhues |
Subject: |
HEAD: pass environment to new test suite |
Date: |
Sun, 14 May 2006 15:23:17 +0200 |
User-agent: |
Mutt/1.5.11+cvs20060403 |
It's actually advantageous if `./testsuite' knows about the environment
variables we set for it: that way, issuing
./tests/testsuite.dir/09/run -x CFLAGS=-g
works as intended: overrides CFLAGS, but uses the same other variables.
So, let's have TESTSUITE_ENVIRONMENT as command line arguments, instead
of setting it beforehand. And let's get rid of that ugly workaround in
LT_AT_TAG that we used before we passed all compilers anyway, so that CC
and CXX etc. can be overridden, too.
OTOH, there is an exception: we want to set $CONFIG_SHELL, because
that is what we start testsuite with.
Any reasons against this?
Cheers,
Ralf
* Makefile.am (check-local): Move `$(TESTS_ENVIRONMENT)' and
`$(BUILDCHECK_ENVIRONMENT)' to be arguments of `testsuite', so
that reruns will remember it; set enviroment variable
`CONFIG_SHELL' so the suite will know which shell it was started
with.
(installcheck-local): Likewise, for `$(TESTS_ENVIRONMENT)' and
`$(INSTALLCHECK_ENVIRONMENT)'.
* tests/testsuite.at (LT_AT_TAG): Do not set the compiler
variable here.
Index: Makefile.am
===================================================================
RCS file: /cvsroot/libtool/libtool/Makefile.am,v
retrieving revision 1.193
diff -u -r1.193 Makefile.am
--- Makefile.am 20 Mar 2006 20:46:30 -0000 1.193
+++ Makefile.am 14 May 2006 12:54:29 -0000
@@ -453,12 +453,15 @@
# Hook the test suite into the check rule
check-local: tests/atconfig $(srcdir)/$(TESTSUITE)
$(CD_TESTDIR); \
- $(TESTS_ENVIRONMENT) $(BUILDCHECK_ENVIRONMENT) $(SHELL)
$$abs_srcdir/$(TESTSUITE) $(TESTSUITE_FLAGS)
+ CONFIG_SHELL="$(SHELL)" $(SHELL) $$abs_srcdir/$(TESTSUITE) \
+ $(TESTS_ENVIRONMENT) $(BUILDCHECK_ENVIRONMENT) $(TESTSUITE_FLAGS)
# Run the test suite on the *installed* tree.
installcheck-local:
$(CD_TESTDIR); \
- $(TESTS_ENVIRONMENT) $(INSTALLCHECK_ENVIRONMENT) $(SHELL)
$$abs_srcdir/$(TESTSUITE) $(TESTSUITE_FLAGS) AUTOTEST_PATH=$(exec_prefix)/bin
+ CONFIG_SHELL="$(SHELL)" $(SHELL) $$abs_srcdir/$(TESTSUITE) \
+ $(TESTS_ENVIRONMENT) $(INSTALLCHECK_ENVIRONMENT) $(TESTSUITE_FLAGS) \
+ AUTOTEST_PATH="$(exec_prefix)/bin"
# We need to remove any file droppings left behind by testsuite
clean-local: clean-local-legacy
Index: tests/testsuite.at
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/testsuite.at,v
retrieving revision 1.40
diff -u -r1.40 testsuite.at
--- tests/testsuite.at 5 Feb 2006 17:06:39 -0000 1.40
+++ tests/testsuite.at 14 May 2006 13:21:38 -0000
@@ -153,11 +153,6 @@
# --------------
m4_define([LT_AT_TAG],
[AT_KEYWORDS([$1])
-eval `$LIBTOOL --tag=$1 --config | sed -n '
- /^CC=/{
- s/CC/$1/
- p
- }'`
AT_CHECK([test -n "[$]$1" || (exit 77)])
])
- HEAD: pass environment to new test suite,
Ralf Wildenhues <=