From 95f1a32d27eef91a8a037522467d7060e7da2624 Mon Sep 17 00:00:00 2001 From: Paul Smith Date: Wed, 28 Jul 2010 05:39:50 +0000 Subject: Release GNU make 3.82 - Update tests for Solaris bizarre-ness - Update files for release --- tests/scripts/variables/SHELL | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) (limited to 'tests/scripts/variables') diff --git a/tests/scripts/variables/SHELL b/tests/scripts/variables/SHELL index 0028d9f..7b7e7fe 100644 --- a/tests/scripts/variables/SHELL +++ b/tests/scripts/variables/SHELL @@ -58,27 +58,29 @@ one two:;@echo "$@: $(SHELL) $$SHELL" # Test .SHELLFLAGS -# We can't assume the value here: on Solaris for example, every line printed +# We don't know the output here: on Solaris for example, every line printed # by the shell in -x mode has a trailing space (!!) -my $script = 'true'; -my $out = `/bin/sh -xc '$script' 2>&1`; +my $script = 'true; true'; +my $flags = '-xc'; +my $out = `/bin/sh $flags '$script' 2>&1`; run_make_test(qq! -.SHELLFLAGS = -xc +.SHELLFLAGS = $flags all: ; \@$script !, '', $out); # We can't just use "false" because on different systems it provides a -# different exit code. - -my $script = 'r() { return 1; }; true; r; true'; -my $out = `/bin/sh -xec '$script' 2>&1`; +# different exit code--once again Solaris: false exits with 255 not 1 +$script = 'true; false; true'; +$flags = '-xec'; +$out = `/bin/sh $flags '$script' 2>&1`; +my $err = $? >> 8; run_make_test(qq! -.SHELLFLAGS = -xec +.SHELLFLAGS = $flags all: ; \@$script !, - '', "$out#MAKE#: *** [all] Error 1\n", 512); + '', "$out#MAKE#: *** [all] Error $err\n", 512); 1; -- cgit v1.2.3