This is the mail archive of the
automake@gnu.org
mailing list for the automake project.
"set -e" in subshell is now reliable
- To: Akim Demaille <akim at epita dot fr>, <automake at gnu dot org>
- Subject: "set -e" in subshell is now reliable
- From: Pavel Roskin <proski at gnu dot org>
- Date: Thu, 22 Feb 2001 00:28:21 -0500 (EST)
- List-Id: Discussion list for automake <automake.gnu.org>
Hello, Akim!
You recently applied a patch to tests/target-cflags.test without
mentioning it in ChangeLog. Maybe you didn't mean to commit that change?
If you did, then two small fixes are needed:
1) You should run ./foo instead /foo
2) bash could not detect it because "set -e" doesn't propagate to the
subshell. I only could catch it on FreeBSD 4.0.
I think it's better to stay on the safe side and eliminate the subshell. I
tried "set -e" in subshell but it didn't work as it should (with
bash-1.14.7).
ChangeLog:
* tests/target-cflags.test: Don't use subshell to configure in
subdirectory. Typo fix - run `./foo', not `/foo'.
_____________________________
--- tests/target-cflags.test
+++ tests/target-cflags.test
@@ -52,13 +52,14 @@
$AUTOCONF
$AUTOMAKE -a
mkdir obj
-(
- cd obj
- ../configure
- $MAKE
- /foo
- ./bar
-)
+
+cd obj
+../configure
+$MAKE
+./foo
+./bar
+cd ..
+
./configure
$MAKE
./foo
_____________________________
Regards,
Pavel Roskin