public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* bfd/elfxx-ia64.c patch
@ 2002-01-22 17:46 Steve Ellcey
  2002-01-25  8:46 ` Nick Clifton
  0 siblings, 1 reply; 2+ messages in thread
From: Steve Ellcey @ 2002-01-22 17:46 UTC (permalink / raw)
  To: binutils


I think elfxx-ia64.c may be unique in that it has two specialized
vectors defined at the end of it, one for AIX and one for HP-UX.  This
results in the necessity of "resetting" any macros that are defined to
AIX specific functions back to their defaults before defining the HP-UX
vector.  Without this the HP-UX vector could call some AIX functions
which is not what is desired.

I am not entirely happy with the way I am doing this but I couldn't find
a cleaner way to reset them.  I tried "saving" the old value of
elf_backend_add_symbol_hook and bfd_elfNN_bfd_link_add_symbols in
another macro before AIX reset them but that did not work.

Can someone review this and, if it is OK, check it in.  I have no write
permission but do have a copyright assignment on file.

Steve Ellcey
sje@cup.hp.com


2002-01-22  Steve Ellcey <sje@cup.hp.com>
	* bfd/elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.



*** src.orig/bfd/elfxx-ia64.c	Tue Jan 22 16:53:07 2002
--- src/bfd/elfxx-ia64.c	Tue Jan 22 16:55:47 2002
*************** elfNN_hpux_backend_section_from_bfd_sect
*** 4591,4596 ****
--- 4591,4597 ----
  
  #include "elfNN-target.h"
  
+ 
  /* HPUX-specific vectors.  */
  
  #undef  TARGET_LITTLE_SYM
*************** elfNN_hpux_backend_section_from_bfd_sect
*** 4599,4604 ****
--- 4600,4615 ----
  #define TARGET_BIG_SYM                  bfd_elfNN_ia64_hpux_big_vec
  #undef  TARGET_BIG_NAME
  #define TARGET_BIG_NAME                 "elfNN-ia64-hpux-big"
+ 
+ /* We need to undo the AIX specific functions.  */
+ 
+ #undef  elf_backend_add_symbol_hook
+ #define elf_backend_add_symbol_hook	elfNN_ia64_add_symbol_hook
+ 
+ #undef  bfd_elfNN_bfd_link_add_symbols
+ #define bfd_elfNN_bfd_link_add_symbols	_bfd_generic_link_add_symbols
+ 
+ /* These are HP-UX specific functions.  */
  
  #undef  elf_backend_post_process_headers
  #define elf_backend_post_process_headers elfNN_hpux_post_process_headers

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: bfd/elfxx-ia64.c patch
  2002-01-22 17:46 bfd/elfxx-ia64.c patch Steve Ellcey
@ 2002-01-25  8:46 ` Nick Clifton
  0 siblings, 0 replies; 2+ messages in thread
From: Nick Clifton @ 2002-01-25  8:46 UTC (permalink / raw)
  To: sje; +Cc: binutils

Hi Steve,

> 2002-01-22  Steve Ellcey <sje@cup.hp.com>
> 	* bfd/elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.

Approved and applied.

Cheers
        Nick

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-01-25 16:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-01-22 17:46 bfd/elfxx-ia64.c patch Steve Ellcey
2002-01-25  8:46 ` Nick Clifton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).