From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13337 invoked by alias); 23 Feb 2002 20:39:05 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 13077 invoked from network); 23 Feb 2002 20:38:58 -0000 Received: from unknown (HELO localhost.redhat.com) (24.112.135.44) by sources.redhat.com with SMTP; 23 Feb 2002 20:38:58 -0000 Received: from cygnus.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 9DACF3D44; Sat, 23 Feb 2002 15:38:56 -0500 (EST) Message-ID: <3C77FDE0.9040500@cygnus.com> Date: Sat, 23 Feb 2002 12:39:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:0.9.8) Gecko/20020210 X-Accept-Language: en-us MIME-Version: 1.0 To: Paul Eggert Cc: gdb-patches@sources.redhat.com Subject: Re: GDB 5.1.1 porting patches for POSIX 1003.1-2001 hosts References: <200202200439.g1K4dr724225@sic.twinsun.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-02/txt/msg00640.txt.bz2 > The new POSIX standard is now official (IEEE Std 1003.1-2001), and it > has removed support for some obsolete utility options that the GDB > build procedure uses in a few places. Here is a proposed patch, > relative to GDB 5.1.1, to help ensure that GDB still will build on > POSIX 1003.1-2001 hosts. The patch shouldn't break GDB builds on > older hosts, as it avoids POSIX features that are not available in > pre-POSIX platforms. > > I've done this patch by code inspection; I don't actually have a fully > conforming POSIX 1003.1-2001 host yet, though I do have some > experimental commands that insist on the -2001 behavior if you set the > right environment variables. Thanks. I've committed this. Is the POSIX spec available online? Andrew > 2002-02-19 Paul Eggert > > * Makefile.in (VER): Change "head -1" to "sed q", since POSIX > 1003.1-2001 no longer allows "head -1". > * gdb/Makefile.in (version.c): Likewise. > * gdb/doc/Makefile.in (GDBvn.texi): Likewise. > > * gdb/CONTRIBUTE: Change "diff -c3" to "diff -c", which is > equivalent. POSIX 1003.1-2001 no longer allows "diff -c3". > > =================================================================== > RCS file: Makefile.in,v > retrieving revision 5.1.1.0 > retrieving revision 5.1.1.1 > diff -pu -r5.1.1.0 -r5.1.1.1 > --- Makefile.in 2002/01/24 03:52:59 5.1.1.0 > +++ Makefile.in 2002/02/20 04:28:34 5.1.1.1 > @@ -1762,7 +1762,7 @@ VER = ` if grep 'AM_INIT_AUTOMAKE.*BFD_V > elif grep AM_INIT_AUTOMAKE $(TOOL)/configure.in >/dev/null 2>&1; then \ > sed < $(TOOL)/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'; \ > elif test -f $(TOOL)/version.in; then \ > - head -1 $(TOOL)/version.in; \ > + sed q $(TOOL)/version.in; \ > elif grep VERSION $(TOOL)/Makefile.in > /dev/null 2>&1; then \ > sed < $(TOOL)/Makefile.in -n 's/^VERSION *= *//p'; \ > else \ > =================================================================== > RCS file: gdb/Makefile.in,v > retrieving revision 5.1.1.0 > retrieving revision 5.1.1.1 > diff -pu -r5.1.1.0 -r5.1.1.1 > --- gdb/Makefile.in 2001/11/18 05:08:36 5.1.1.0 > +++ gdb/Makefile.in 2002/02/20 04:28:34 5.1.1.1 > @@ -1024,7 +1024,7 @@ $(srcdir)/copying.c: @MAINTAINER_MODE_TR > version.c: Makefile version.in > rm -f version.c-tmp version.c > echo '#include "version.h"' >> version.c-tmp > - echo 'const char version[] = "'"`head -1 ${srcdir}/version.in`"'";' >> version.c-tmp > + echo 'const char version[] = "'"`sed q ${srcdir}/version.in`"'";' >> version.c-tmp > echo 'const char host_name[] = "$(host_alias)";' >> version.c-tmp > echo 'const char target_name[] = "$(target_alias)";' >> version.c-tmp > mv version.c-tmp version.c > =================================================================== > RCS file: gdb/doc/Makefile.in,v > retrieving revision 5.1.1.0 > retrieving revision 5.1.1.1 > diff -pu -r5.1.1.0 -r5.1.1.1 > --- gdb/doc/Makefile.in 2002/01/21 03:54:43 5.1.1.0 > +++ gdb/doc/Makefile.in 2002/02/20 04:28:34 5.1.1.1 > @@ -215,7 +215,7 @@ refcard.ps : refcard.dvi > > # File to record current GDB version number (copied from main dir version.in) > GDBvn.texi : ${gdbdir}/version.in > - echo "@set GDBVN `head -1 $(srcdir)/../version.in`" > ./GDBvn.new > + echo "@set GDBVN `sed q $(srcdir)/../version.in`" > ./GDBvn.new > mv GDBvn.new GDBvn.texi > > # Updated atomically > =================================================================== > RCS file: gdb/CONTRIBUTE,v > retrieving revision 5.1.1.0 > retrieving revision 5.1.1.1 > diff -pu -r5.1.1.0 -r5.1.1.1 > --- gdb/CONTRIBUTE 2001/09/26 20:53:27 5.1.1.0 > +++ gdb/CONTRIBUTE 2002/02/20 04:28:34 5.1.1.1 > @@ -70,7 +70,7 @@ o Submitting Patches > documentation (i.e., .texi files). > > The patch itself. If you are accessing the CVS repository use > - "cvs update; cvs diff -c3p"; else, use "diff -c3p OLD NEW" or > + "cvs update; cvs diff -cp"; else, use "diff -cp OLD NEW" or > "diff -up OLD NEW". If your version of diff does not support > these options, then get the latest version of GNU diff. > > >