From: David Edelsohn <dje@watson.ibm.com>
To: Kevin Buettner <kevinb@redhat.com>, Nicholas Duffek <nsd@redhat.com>
Cc: gdb-patches@sources.redhat.com,
Albert Chin-A-Young <china@thewrittenword.com>
Subject: [PATCH] bfd/rs6000-core.c
Date: Sat, 23 Jun 2001 22:23:00 -0000 [thread overview]
Message-ID: <200106240523.BAA24138@makai.watson.ibm.com> (raw)
The new AIX 4.3+ core support assumes a field in the core_dumpx
structure defined in /usr/include/sys/core.h that only exists in AIX 4.3.3
and not earlier releases. This prevents binutils from building on AIX
4.3.2. Albert and I have worked out the appended patch.
David
* rs6000-core.c: Use autoconf variable HAVE_ST_C_IMPL to guard use
of c_impl field.
* configure.in: Auto-configure HAVE_ST_C_IMPL.
* configure.in: Likewise.
--- bfd/configure.in.orig Fri Jun 22 13:09:23 2001
+++ bfd/configure.in Fri Jun 22 13:18:11 2001
@@ -301,6 +301,15 @@
changequote([,])dnl
COREFILE=rs6000-core.lo
COREFLAG="$COREFLAG -DAIX_CORE_DUMPX_CORE"
+
+ # Not all versions of AIX with -DAIX_CORE_DUMPX_CORE
+ # have c_impl as a member of struct core_dumpx
+ AC_MSG_CHECKING([for c_impl in struct core_dumpx])
+ AC_TRY_COMPILE([#include <core.h>],
+ [struct core_dumpx c; c.c_impl = 0;],
+ [AC_DEFINE(HAVE_ST_C_IMPL, 1,
+ [Define if struct core_dumpx has member c_impl])
+ AC_MSG_RESULT(yes)],[AC_MSG_RESULT(no)])
;;
rs6000-*-aix4*) COREFILE=rs6000-core.lo ;;
rs6000-*-*) COREFILE=rs6000-core.lo ;;
--- bfd/config.in.orig Fri Jun 22 13:17:50 2001
+++ bfd/config.in Fri Jun 22 13:18:31 2001
@@ -208,6 +208,9 @@
/* Define if getenv is not declared in system header files. */
#undef NEED_DECLARATION_GETENV
+/* Define if struct core_dumpx has member c_impl */
+#undef HAVE_ST_C_IMPL
+
/* Define if <sys/procfs.h> has prstatus_t. */
#undef HAVE_PRSTATUS_T
--- bfd/rs6000-core.c.orig Fri Jun 22 13:11:09 2001
+++ bfd/rs6000-core.c Fri Jun 22 13:11:26 2001
@@ -182,7 +182,7 @@
/* Return the c_impl field from struct core_dumpx C. */
-#ifdef AIX_CORE_DUMPX_CORE
+#ifdef HAVE_ST_C_IMPL
# define CNEW_IMPL(c) (c).c_impl
#else
# define CNEW_IMPL(c) 0
next reply other threads:[~2001-06-23 22:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-06-23 22:23 David Edelsohn [this message]
2001-06-26 7:33 ` Nick Duffek
2001-06-26 9:21 ` Kevin Buettner
2001-06-26 9:39 ` David Edelsohn
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=200106240523.BAA24138@makai.watson.ibm.com \
--to=dje@watson.ibm.com \
--cc=china@thewrittenword.com \
--cc=gdb-patches@sources.redhat.com \
--cc=kevinb@redhat.com \
--cc=nsd@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