summaryrefslogtreecommitdiff
path: root/automake.in
diff options
context:
space:
mode:
Diffstat (limited to 'automake.in')
-rw-r--r--automake.in9
1 files changed, 9 insertions, 0 deletions
diff --git a/automake.in b/automake.in
index 4776581c5..f77ab7c5c 100644
--- a/automake.in
+++ b/automake.in
@@ -32,6 +32,15 @@ BEGIN
@Automake::perl_libdirs = ('@datadir@/@PACKAGE@-@APIVERSION@')
unless @Automake::perl_libdirs;
unshift @INC, @Automake::perl_libdirs;
+
+ # Override SHELL. This is required on DJGPP so that system() uses
+ # bash, not COMMAND.COM which doesn't quote arguments properly.
+ # Other systems aren't expected to use $SHELL when Automake
+ # runs, but it should be safe to drop the "if DJGPP" guard if
+ # it turns up other systems need the same thing. After all,
+ # if SHELL is used, ./configure's SHELL is always better than
+ # the user's SHELL (which may be something like tcsh).
+ $ENV{'SHELL'} = '@SHELL@' if exists $ENV{'DJDIR'};
}
use Class::Struct ();