From: "Rodney Brown" <rbrown@bravurasolutions.com.au>
To: <gdb-patches@sources.redhat.com>
Cc: <binutils@sources.redhat.com>
Subject: Patch to bfd/aix5ppc-core.c for gdb-6.3 with gcc 4 on AIX5.1
Date: Fri, 15 Jul 2005 09:17:00 -0000 [thread overview]
Message-ID: <4F3B985B8E683C45B8C5F76B7AAB5AE5215F70@EXCHANGE.bravurasolutions.local> (raw)
powerpc-ibm-aix5.1.0.0 gcc version 4.0.1
/bin/sh ./libtool --mode=compile gcc -DHAVE_CONFIG_H -I.
-I../../gdb-6.3/bfd \
-I. -D_GNU_SOURCE -DAIX_5_CORE -DAIX_CORE_DUMPX_CORE -DAIX_CORE \
-DAIX_WEAK_SUPPORT -I. -I../../gdb-6.3/bfd
-I../../gdb-6.3/bfd/../include \
-I../../gdb-6.3/bfd/../intl -I../intl -W -Wall -Wstrict-prototypes \
-Wmissing-prototypes -g -O2 -c -o aix5ppc-core.lo \
../../gdb-6.3/bfd/aix5ppc-core.c
gcc -DHAVE_CONFIG_H -I. -I../../gdb-6.3/bfd -I. -D_GNU_SOURCE
-DAIX_5_CORE \
-DAIX_CORE_DUMPX_CORE -DAIX_CORE -DAIX_WEAK_SUPPORT -I.
-I../../gdb-6.3/bfd \
-I../../gdb-6.3/bfd/../include -I../../gdb-6.3/bfd/../intl -I../intl
-W \
-Wall -Wstrict-prototypes -Wmissing-prototypes -g -O2 -c \
../../gdb-6.3/bfd/aix5ppc-core.c -o aix5ppc-core.o
../../gdb-6.3/bfd/aix5ppc-core.c: In function 'xcoff64_core_p':
../../gdb-6.3/bfd/aix5ppc-core.c:120: error: invalid lvalue in
assignment
../../gdb-6.3/bfd/aix5ppc-core.c:223: warning: \
assignment discards qualifiers from pointer target type
From a look at aix5ppc-core.c with the CVSWeb interface, the patch for
the return_value warning conflicts with the latest delta.
Since xcoff64_core_p returns a const bfd_target *, I'd prefer declaring
return_value as const.
Diff for /src/bfd/aix5ppc-core.c between version 1.7 and 1.8
version 1.7, 2005/03/03 11:40:55 version 1.8, 2005/04/18 12:10:57
- return_value = abfd->xvec; /* This is garbage for now. */
+ return_value = (bfd_target *) abfd->xvec; /* This is garbage for
now. */
No current employer disclaimer.
No testsuite run.
2005-07-12 Rodney Brown <rbrown@bravurasolutions.com.au>
* aix5ppc-core.c (core_hdr): #define as LHS varient.
(xcoff64_core_p): Constify return_value variable.
--- bfd/aix5ppc-core.c.orig Thu Jun 24 14:46:14 2004
+++ bfd/aix5ppc-core.c Tue Jul 12 00:37:16 2005
@@ -1,5 +1,5 @@
/* IBM RS/6000 "XCOFF" back-end for BFD.
- Copyright 2001, 2002, 2004
+ Copyright 2001, 2002, 2004, 2005
Free Software Foundation, Inc.
Written by Tom Rix
Contributed by Redhat.
@@ -44,7 +44,7 @@ int xcoff64_core_file_failing_signal
#include <sys/ldr.h>
#include <core.h>
-#define core_hdr(abfd) ((struct core_dumpxx *)
abfd->tdata.any)
+#define core_hdr(abfd) (abfd->tdata.any) /* gcc 4
support */
#define CHECK_FILE_OFFSET(s, v) \
((bfd_signed_vma)(v) < 0 || (bfd_signed_vma)(v) >
(bfd_signed_vma)(s).st_size)
@@ -60,7 +60,7 @@ xcoff64_core_p (abfd)
bfd_vma ld_offset;
bfd_size_type i;
struct vm_infox vminfo;
- bfd_target *return_value = NULL;
+ const bfd_target *return_value = NULL;
/* Get the header. */
if (bfd_seek (abfd, 0, SEEK_SET) != 0)
@@ -228,6 +228,9 @@ xcoff64_core_p (abfd)
return return_value;
}
+
+#undef core_hdr /* gcc 4.0 support */
+#define core_hdr(abfd) ((struct core_dumpxx *)
abfd->tdata.any)
/* Return `TRUE' if given core is from the given executable. */
next reply other threads:[~2005-07-15 9:17 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-15 9:17 Rodney Brown [this message]
2005-08-02 10:59 ` Nick Clifton
2005-08-03 2:25 Rodney Brown
2005-08-08 12:28 ` Nick Clifton
2005-08-09 8:59 Rodney Brown
2005-08-09 16:37 ` Nick Clifton
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=4F3B985B8E683C45B8C5F76B7AAB5AE5215F70@EXCHANGE.bravurasolutions.local \
--to=rbrown@bravurasolutions.com.au \
--cc=binutils@sources.redhat.com \
--cc=gdb-patches@sources.redhat.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