public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: ak03@gte.com
To: gcc-gnats@gcc.gnu.org
Cc: feifer@dbai.tuwien.ac.at, rittle@latour.rsch.comm.mot.com,
	obrien@FreeBSD.ORG
Subject: bootstrap/10452: Make gengtype-yacc.y buildable with FreeBSD yacc
Date: Tue, 22 Apr 2003 14:16:00 -0000	[thread overview]
Message-ID: <200304221412.h3MECqoo055862@ork.gte.com> (raw)


>Number:         10452
>Category:       bootstrap
>Synopsis:       Make gengtype-yacc.y compatible with stock FreeBSD yacc
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Tue Apr 22 14:16:01 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Alexander N. Kabaev
>Release:        3.3 20030421 (prerelease)
>Organization:
FreeBSD Project
>Environment:
System: FreeBSD ork.gte.com 4.8-RC FreeBSD 4.8-RC #2: Mon Mar 24 11:00:40 EST 2003 ak03@ork.gte.com:/usr/src/sys/compile/KAN i386

FreeBSD kanpc.gte.com 5.0-CURRENT FreeBSD 5.0-CURRENT #4: Wed Apr 16 18:23:28 EDT 2003     ak03@kanpc.gte.com:/usr/src/sys/i386/compile/KANPC  i386

	
host: i386-portbld-freebsd4.8
build: i386-portbld-freebsd4.8
target: i386-portbld-freebsd4.8
configured with: ./..//gcc-20030421/configure --disable-nls --with-gnu-as --with-gnu-ld --with-gxx-include-dir=/usr/local/lib/gcc-lib/i386-portbld-freebsd4.8/3.3/include/g++-v3 --with-system-zlib --disable-shared --prefix=/usr/local i386-portbld-freebsd4.8
>Description:
	gengtype-yacc.y grammar definition file contains token definition
	lines which appear to be bison specific. The string values after the
	token are not supported by the stock FreeBSD yacc and they are not
	required for the parser to work anyway. Attached patch removes
	these string identifiers to facilitate easier integration of the
	upcoming GCC 3.3 release into FreeBSD source tree.

	Also, add defines for malloc and realloc to change them into
	xmalloc and xrealloc respectively. This takes care of yacc
	programs whose genererated code contains invocations of any
	of these functions.
>How-To-Repeat:
	N/A
>Fix:
	
Index: gengtype-yacc.y
===================================================================
RCS file: /usr/ncvs2/src/contrib/gcc/gengtype-yacc.y,v
retrieving revision 1.1.1.1
diff -u -c -r1.1.1.1 gengtype-yacc.y
*** gengtype-yacc.y	3 Apr 2003 01:50:40 -0000	1.1.1.1
--- gengtype-yacc.y	22 Apr 2003 14:00:48 -0000
***************
*** 24,29 ****
--- 24,32 ----
  #include "system.h"
  #include "gengtype.h"
  #define YYERROR_VERBOSE
+ 
+ #define malloc xmalloc
+ #define realloc xrealloc
  %}
  
  %union {
***************
*** 37,47 ****
  %token <t>ENT_STRUCT
  %token ENT_EXTERNSTATIC
  %token ENT_YACCUNION
! %token GTY_TOKEN "GTY"
! %token UNION "union"
! %token STRUCT "struct"
! %token ENUM "enum"
! %token ALIAS "ptr_alias"
  %token <s>PARAM_IS
  %token NUM
  %token PERCENTPERCENT "%%"
--- 40,50 ----
  %token <t>ENT_STRUCT
  %token ENT_EXTERNSTATIC
  %token ENT_YACCUNION
! %token GTY_TOKEN
! %token UNION
! %token STRUCT
! %token ENUM
! %token ALIAS
  %token <s>PARAM_IS
  %token NUM
  %token PERCENTPERCENT "%%"
>Release-Note:
>Audit-Trail:
>Unformatted:


                 reply	other threads:[~2003-04-22 14:16 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200304221412.h3MECqoo055862@ork.gte.com \
    --to=ak03@gte.com \
    --cc=feifer@dbai.tuwien.ac.at \
    --cc=gcc-gnats@gcc.gnu.org \
    --cc=obrien@FreeBSD.ORG \
    --cc=rittle@latour.rsch.comm.mot.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).