2006-12-30 Paul Eggert <eggert@cs.ucla.edu>
+ * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
+ Rewrite so as not to assume GNU sort. Also, don't assume
+ the C locale, and avoid an "eval" that could cause trouble.
+
* lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
Define. Trivial patch from Henning Nielsen Lund, originally
sent to bug-grep@gnu.org today.
progname=$0
package=gnulib
-cvsdatestamp='$Date: 2006-12-26 18:42:09 $'
+cvsdatestamp='$Date: 2006-12-31 06:29:50 $'
last_checkin_date=`echo "$cvsdatestamp" | sed -e 's,^\$[D]ate: ,,'`
version=`echo "$last_checkin_date" | sed -e 's/ .*$//' -e 's,/,-,g'`
nl='
AUTOPOINT="${GETTEXTPATH}autopoint"
fi
-# GNU sort is needed. Set SORT to its location (not needed if it's called
-# 'sort' and already in the PATH).
-if test -z "$SORT"; then
- SORT=sort
-fi
-
# When using GNU sed, turn off as many GNU extensions as possible,
# to minimize the risk of accidentally using non-portable features.
# However, do this only for gnulib-tool itself, not for the code that
s,^dnl .*$,,
s, dnl .*$,,
/AC_PREREQ/ {
- s,^.*AC_PREREQ([[ ]*\([^])]*\).*$,prereqs="$prereqs \1",p
+ s,^.*AC_PREREQ([[ ]*\([^])]*\).*$,\1,p
}'
- eval `sed -n -e "$my_sed_traces" < "$configure_ac"`
+ prereqs=`sed -n -e "$my_sed_traces" < "$configure_ac"`
if test -n "$prereqs"; then
- autoconf_minversion=`for version in $prereqs; do echo $version; done | $SORT -g -u | tail -1`
+ autoconf_minversion=`
+ for version in $prereqs; do echo $version; done |
+ LC_ALL=C sort -nu | sed 1q
+ `
fi
fi
if test -z "$autoconf_minversion"; then