Bootstrap: don't search perl in $PATH.
authorStefano Lattarini <stefano.lattarini@gmail.com>
Tue, 27 Jul 2010 20:50:38 +0000 (22:50 +0200)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Tue, 10 Aug 2010 17:39:21 +0000 (19:39 +0200)
* bootstrap: Do not explicitly search perl in $PATH anymore.
($PATH_SEPARATOR): Removed, it's no more needed.

ChangeLog
bootstrap

index e424d30eedbe8c9f18a752f8ad11cd46c0a8621d..815f467da747462325e22e5d0674723b55ce8c9a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2010-08-08  Stefano Lattarini  <stefano.lattarini@gmail.com>
 
+       Bootstrap: don't search perl in $PATH.
+       * bootstrap: Do not explicitly search perl in $PATH anymore.
+       ($PATH_SEPARATOR): Removed, it's no more needed.
+
        Bootstrap: let the user choose which autoconf to use.
        * bootstrap ($AUTOCONF): New variable, from the environment.
        ($AUTOM4TE): Likewise, for clarity.
index ebcedbe834cbaa9e122743e09ae7d1b78e3ba760..f72346f799c0a992b9c4f1a803a48c21aa51e6f8 100755 (executable)
--- a/bootstrap
+++ b/bootstrap
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# Find the path separator.
-# (Snippet copied from configure's initialization in Autoconf 2.65)
-if test "${PATH_SEPARATOR+set}" != set; then
-  PATH_SEPARATOR=:
-  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
-    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
-      PATH_SEPARATOR=';'
-  }
-fi
-
 # Don't ignore failures.
 set -e
 
 # Set program basename.
 me=`echo "$0" | sed 's,^.*/,,'`
 
-# Let user choose which version of autoconf and autom4te to use.
+# Let user choose which version of autoconf, autom4te and perl to use.
 : ${AUTOCONF=autoconf}
 export AUTOCONF  # might be used by aclocal and/or automake
 : ${AUTOM4TE=autom4te}
 export AUTOM4TE  # ditto
-
-# Find perl.  Code based on Autoconf, but without non-POSIX support.
-if test -z "$PERL"; then
-  save_IFS=$IFS
-  IFS=$PATH_SEPARATOR
-  for dir in $PATH; do
-    IFS=$save_IFS
-    test -z "$dir" && dir=.
-    if test -x "$dir/perl" && test ! -d "$dir/perl"; then
-      PERL="$dir/perl"
-      break
-    fi
-  done
-fi
-
-if test -z "$PERL"; then
-  echo "$me: cannot find perl" >&2
-  exit 1
-fi
+: ${PERL=perl}
 
 # Variables to substitute.
 VERSION=`sed -ne '/AC_INIT/s/^[^[]*\[[^[]*\[\([^]]*\)\].*$/\1/p' configure.ac`