From 394171ace4720ffdfa7ab5b47413aa564fa03478 Mon Sep 17 00:00:00 2001 From: Fred Fish Date: Mon, 30 Nov 1992 20:07:35 +0000 Subject: [PATCH] * tm-sun4sol2.h: Add CPLUS_MARKER. Solaris 2.0 requires '.' rather than '$'. This particular piece of braindamage is spreading like ooze. It's now infected libiberty, deja-gnu, gdb, and gcc. * values.c (baseclass_addr): Use CPLUS_MARKER rather than hardwired '$' character. --- gdb/ChangeLog | 9 +++++++++ gdb/tm-sun4sol2.h | 5 +++++ gdb/values.c | 2 +- 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index c764d583d7a..9a51cf2e69f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,12 @@ +Mon Nov 30 12:00:25 1992 Fred Fish (fnf@cygnus.com) + + * tm-sun4sol2.h: Add CPLUS_MARKER. Solaris 2.0 requires '.' + rather than '$'. This particular piece of braindamage is + spreading like ooze. It's now infected libiberty, deja-gnu, + gdb, and gcc. + * values.c (baseclass_addr): Use CPLUS_MARKER rather than + hardwired '$' character. + Sun Nov 29 15:22:42 1992 Fred Fish (fnf@cygnus.com) (Changes to break incredibly ugly, unmaintainable 750 line diff --git a/gdb/tm-sun4sol2.h b/gdb/tm-sun4sol2.h index dbf9ffbb383..f785dd18ec2 100644 --- a/gdb/tm-sun4sol2.h +++ b/gdb/tm-sun4sol2.h @@ -37,6 +37,11 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #define SUN_FIXED_LBRAC_BUG +/* Assembler doesn't grok dollar signs in identifiers, so we use dots instead. + This item must be coordinated with G++. */ +#undef CPLUS_MARKER +#define CPLUS_MARKER '.' + #if 0 /* Setjmp/longjmp are not as well doc'd in SunOS 5.x yet */ /* Offsets into jmp_buf. Not defined by Sun, but at least documented in a diff --git a/gdb/values.c b/gdb/values.c index 61a16143e32..14ecccbd384 100644 --- a/gdb/values.c +++ b/gdb/values.c @@ -1215,7 +1215,7 @@ baseclass_addr (type, index, valaddr, valuep, errp) char *vbase_name, *type_name = type_name_no_tag (basetype); vbase_name = (char *)alloca (strlen (type_name) + 8); - sprintf (vbase_name, "_vb$%s", type_name); + sprintf (vbase_name, "_vb%c%s", CPLUS_MARKER, type_name); /* First look for the virtual baseclass pointer in the fields. */ for (i = n_baseclasses; i < len; i++) -- 2.30.2