alpha textrel fix

Richard Henderson rth@redhat.com
Sat Jan 26 02:25:00 GMT 2002


Noticed while examining libstdc++ headers that .rela.debug_info
had caused DT_TEXTREL to get set.


r~


        * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
        for non-allocated sections.

Index: elf64-alpha.c
===================================================================
RCS file: /cvs/src/src/bfd/elf64-alpha.c,v
retrieving revision 1.54
diff -c -p -d -r1.54 elf64-alpha.c
*** elf64-alpha.c	2002/01/23 21:51:53	1.54
--- elf64-alpha.c	2002/01/26 08:39:28
*************** elf64_alpha_check_relocs (abfd, info, se
*** 2501,2507 ****
  		  rent->srel = sreloc;
  		  rent->rtype = r_type;
  		  rent->count = 1;
! 		  rent->reltext = (sec->flags & SEC_READONLY) != 0;
  
  		  rent->next = h->reloc_entries;
  		  h->reloc_entries = rent;
--- 2501,2508 ----
  		  rent->srel = sreloc;
  		  rent->rtype = r_type;
  		  rent->count = 1;
! 		  rent->reltext = ((sec->flags & (SEC_READONLY | SEC_ALLOC))
! 				   == (SEC_READONLY | SEC_ALLOC));
  
  		  rent->next = h->reloc_entries;
  		  h->reloc_entries = rent;



More information about the Binutils mailing list