This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Coreutils head and tail problems
- From: "Andrew Walrond" <andrew at walrond dot org>
- To: <gcc at gcc dot gnu dot org>
- Date: Tue, 26 Aug 2003 13:33:27 +0100
- Subject: Coreutils head and tail problems
As I'm sure you know, head -1, tail -1 have been deprecated in favour of
head -n1 and tail -n1 in recent gnu coreutils, and indeed no longer works in
the latest releases.
But, a quick grep of 3.3.1 or mainline sources shows lots of instances of
the old usage:
rubyx@atlas gcc $ grep -r 'head -' *
boehm-gc/config.guess: UNAME_RELEASE=`(head -1 /etc/motd | awk '{print
substr($5,1,3)}') 2>/dev/null`
boehm-gc/config.guess: IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S
available | head -1 | awk '{ print $1 }'`
config.guess: # types through head -n 1, so we only detect the type of CPU
0.
config.guess: ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The
alpha \(.*\) processor.*$/\1/p' | head -n 1`
gcc/configure: ld_ver=`$gcc_cv_ld --version 2>/dev/null | head -1`
gcc/configure: as_ver=`$gcc_cv_as --version 2>/dev/null | head -1`
gcc/configure.in: ld_ver=`$gcc_cv_ld --version 2>/dev/null | head -1`
gcc/configure.in: as_ver=`$gcc_cv_as --version 2>/dev/null | head -1`
gcc/ada/a-textio.adb: -- Look_Ahead --
gcc/ada/a-witeio.adb: -- Look_Ahead --
gcc/ada/xeinfo.adb: -- Sethead --
libjava/acinclude.m4:LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -1 | cut -d
'.' -f 1 | cut -d ' ' -f 4`
libjava/acinclude.m4:LD_VERSION_MINOR=`echo "$LD_VERSION" | head -1 | cut -d
'.' -f 2`
libjava/aclocal.m4:LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -1 | cut -d
'.' -f 1 | cut -d ' ' -f 4`
libjava/aclocal.m4:LD_VERSION_MINOR=`echo "$LD_VERSION" | head -1 | cut -d
'.' -f 2`
libjava/configure:LD_VERSION_MAJOR=`echo "$LD_VERSION" | head -1 | cut -d
'.' -f 1 | cut -d ' ' -f 4`
libjava/configure:LD_VERSION_MINOR=`echo "$LD_VERSION" | head -1 | cut -d
'.' -f 2`
libjava/java/lang/k_rem_pio2.c: * r_tail = w - (r_head - t);
libstdc++-v3/acinclude.m4: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/aclocal.m4: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/configure: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/configure: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/configure: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/configure: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/configure: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/configure: ldver=`$LD --version 2>/dev/null | head -1 | \
libstdc++-v3/configure: ldver=`$LD --version 2>/dev/null | head -1 | \
ltcf-c.sh: archive_expsym_cmds='if test "x`head -1 $export_symbols`" =
xEXPORTS; then
ltcf-gcj.sh: archive_expsym_cmds='if test "x`head -1 $export_symbols`" =
xEXPORTS; then
rubyx@atlas gcc $ grep -r 'tail -' *
contrib/test_summary: system("tail -1 " srcdir "/LAST_UPDATED");
gcc/configure: | tail -3 > conftest.got \
gcc/configure.in: | tail -3 > conftest.got \
libstdc++-v3/scripts/check_survey.in: TEXT) TEXT=$(size -B $EXENAME
| tail -1 | awk '{print $1}') ;;
libstdc++-v3/scripts/check_survey.in: DATA) DATA=$(size -B $EXENAME
| tail -1 | awk '{print $2}') ;;
libstdc++-v3/scripts/check_survey.in: SIZE) SIZE=$(size -B $EXENAME
| tail -1 | awk '{print $4}') ;;
rubyx@atlas gcc $
Is this a consequence of the version of autoconfig used? Can anything be
done about it?
Andrew Walrond