autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] Shell selection refinement


From: Eric Sunshine
Subject: [PATCH] Shell selection refinement
Date: Mon, 19 Apr 2004 03:45:22 -0400

Hello,

This Autoconf patch refines the way Autoconf chooses a usable shell, and  
should help to avoid incompatibilites in various packages, like the one which  
the Autoconf CVS code uncovered in Automake, as discussed in this thread:

http://mail.gnu.org/archive/html/automake/2004-04/msg00095.html

-- ES


2004-04-19  Eric Sunshine  <address@hidden>

        * lib/m4sugar/m4sh.m4 (_AS_DETECT_BETTER_SHELL): Consult $SHELL as a
        possible candidate only after all others fail, rather than consulting
        it first.  This improves backward compatibility by better reflecting
        the way shell selection occurred in previous versions of Autoconf, and
        should help to avoid triggering latent problems in other packages, such
        as the one in Automake where zsh is not handled robustly:
            http://mail.gnu.org/archive/html/automake/2004-04/msg00095.html
        Although it is not Autoconf's responsibility to work around problems in
        Automake, it nevertheless makes sense to avoid introducing unnecessary
        incompatibilites.


--- m4sh.m4-orig        Mon Apr 19 02:48:42 2004
+++ m4sh.m4     Mon Apr 19 02:49:05 2004
@@ -215,7 +215,7 @@
   AS_IF([test $as_have_required = yes && dnl
         _AS_RUN([_AS_DETECT_SUGGESTED_BODY]) 2> /dev/null],
     [],
-    [as_candidate_shells="$SHELL"
+    [as_candidate_shells=''
     _AS_PATH_WALK([/bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH],
       [case $as_dir in
         /*)
@@ -223,6 +223,7 @@
             as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
           done
        esac])
+      as_candidate_shells="$as_candidate_shells $SHELL"

       for as_shell in $as_candidate_shells; do
         AS_IF([_AS_RUN([_AS_DETECT_REQUIRED_BODY], [$as_shell 2> /dev/null])],




reply via email to

[Prev in Thread] Current Thread [Next in Thread]