This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
3.4 PATCH: Fix Solaris 8 Ada bootstrap failure
- From: Rainer Orth <ro at TechFak dot Uni-Bielefeld dot DE>
- To: gcc-patches at gcc dot gnu dot org
- Cc: Arnaud Charlet <charlet at ACT-Europe dot FR>
- Date: Tue, 21 Oct 2003 20:06:34 +0200 (MEST)
- Subject: 3.4 PATCH: Fix Solaris 8 Ada bootstrap failure
This patch originally submitted in
http://gcc.gnu.org/ml/gcc/2003-07/msg01388.html
is necessary after the recent Ada merge to allow bootstrap on
sparc-sun-solaris2.8. Bootstrap is into stage2 now, where it failed
previously as described in the message above.
Ok for mainline?
Rainer
-----------------------------------------------------------------------------
Rainer Orth, Faculty of Technology, Bielefeld University
Thu Jul 17 22:23:43 2003 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
* tracebak.c (MAX): Avoid redefinition warning.
* init.c (__gnat_error_handler): Change msg to const char *.
Index: gcc/ada/init.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/ada/init.c,v
retrieving revision 1.16
diff -u -p -r1.16 init.c
--- gcc/ada/init.c 21 Oct 2003 13:42:09 -0000 1.16
+++ gcc/ada/init.c 21 Oct 2003 18:05:11 -0000
@@ -1194,7 +1194,7 @@ __gnat_error_handler (sig, sip)
{
struct Exception_Data *exception;
static int recurse = 0;
- char *msg;
+ const char *msg;
/* If this was an explicit signal from a "kill", just resignal it. */
if (SI_FROMUSER (sip))
Index: gcc/ada/tracebak.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/ada/tracebak.c,v
retrieving revision 1.6
diff -u -p -r1.6 tracebak.c
--- gcc/ada/tracebak.c 21 Oct 2003 13:42:23 -0000 1.6
+++ gcc/ada/tracebak.c 21 Oct 2003 18:05:11 -0000
@@ -327,7 +327,9 @@ extern unsigned int _image_base__;
#define VALID_STACK_FRAME(ptr) 1
#endif
+#ifndef MAX
#define MAX(x,y) ((x) > (y) ? (x) : (y))
+#endif
/* Define a dummy function to call if FORCE_CALL is defined. Don't
define it otherwise, as this could lead to "defined but not used"