Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Jeffrey A Law <law@redhat.com>
To: binutils@sources.redhat.com, gdb-patches@sources.redhat.com
Subject: PA64 bugfix
Date: Mon, 11 Dec 2000 09:58:00 -0000	[thread overview]
Message-ID: <30286.976557446@upchuck> (raw)

The value of DT_LOOS was changed about a year ago in include/elf/common.h
to conform to the latest ELF standard.  Several PA64 specific entries are
defined relative to DT_LOOS.

Thus, gnu-ld would create binaries which would have the new values for
stuff like DT_HP_LOAD_MAP, DT_HP_DLD_FLAGS, etc.  This caused some problems
for HP's dynamic linker as well as gdb.

gdb choked because it used HP's system include files which had the old
values.  Thus, when it tried to read the .dynamic section, gdb didn't know
how to interpret the new values for DT_HP_LOAD_MAP and friends it found.
This caused gdb to fail rather miserably.

This patch defines the PA64 specific .dynamic entries to be relative to the
old value of DT_LOOS (OLD_DT_LOOS).  And not surprisingly gdb and HP's dynamic
linker are much happier now.

Installed.


	* hppa.h (DT_HP_*): Define relative to OLD_DT_LOOS to be
	compatible with HP's tools.

Index: hppa.h
===================================================================
RCS file: /cvs/cvsfiles/devo/include/elf/hppa.h,v
retrieving revision 1.14
diff -c -3 -p -r1.14 hppa.h
*** hppa.h	2000/07/29 20:21:12	1.14
--- hppa.h	2000/12/11 17:09:57
*************** typedef enum elf_hppa_reloc_type elf_hpp
*** 491,509 ****
  \f
  /* Processor specific dynamic array tags.  */
  
! #define DT_HP_LOAD_MAP		(DT_LOOS + 0x0)
! #define DT_HP_DLD_FLAGS		(DT_LOOS + 0x1)
! #define DT_HP_DLD_HOOK		(DT_LOOS + 0x2)
! #define DT_HP_UX10_INIT		(DT_LOOS + 0x3)
! #define DT_HP_UX10_INITSZ	(DT_LOOS + 0x4)
! #define DT_HP_PREINIT		(DT_LOOS + 0x5)
! #define DT_HP_PREINITSZ		(DT_LOOS + 0x6)
! #define DT_HP_NEEDED		(DT_LOOS + 0x7)
! #define DT_HP_TIME_STAMP	(DT_LOOS + 0x8)
! #define DT_HP_CHECKSUM		(DT_LOOS + 0x9)
! #define DT_HP_GST_SIZE		(DT_LOOS + 0xa)
! #define DT_HP_GST_VERSION	(DT_LOOS + 0xb)
! #define DT_HP_GST_HASHVAL	(DT_LOOS + 0xc)
  
  /* Values for DT_HP_DLD_FLAGS.  */
  #define DT_HP_DEBUG_PRIVATE		0x0001 /* Map text private */
--- 491,512 ----
  \f
  /* Processor specific dynamic array tags.  */
  
! /* Arggh.  HP's tools define these symbols based on the
!    old value of DT_LOOS.  So we must do the same to be
!    compatible.  */
! #define DT_HP_LOAD_MAP		(OLD_DT_LOOS + 0x0)
! #define DT_HP_DLD_FLAGS		(OLD_DT_LOOS + 0x1)
! #define DT_HP_DLD_HOOK		(OLD_DT_LOOS + 0x2)
! #define DT_HP_UX10_INIT		(OLD_DT_LOOS + 0x3)
! #define DT_HP_UX10_INITSZ	(OLD_DT_LOOS + 0x4)
! #define DT_HP_PREINIT		(OLD_DT_LOOS + 0x5)
! #define DT_HP_PREINITSZ		(OLD_DT_LOOS + 0x6)
! #define DT_HP_NEEDED		(OLD_DT_LOOS + 0x7)
! #define DT_HP_TIME_STAMP	(OLD_DT_LOOS + 0x8)
! #define DT_HP_CHECKSUM		(OLD_DT_LOOS + 0x9)
! #define DT_HP_GST_SIZE		(OLD_DT_LOOS + 0xa)
! #define DT_HP_GST_VERSION	(OLD_DT_LOOS + 0xb)
! #define DT_HP_GST_HASHVAL	(OLD_DT_LOOS + 0xc)
  
  /* Values for DT_HP_DLD_FLAGS.  */
  #define DT_HP_DEBUG_PRIVATE		0x0001 /* Map text private */



                 reply	other threads:[~2000-12-11  9:58 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=30286.976557446@upchuck \
    --to=law@redhat.com \
    --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