This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
[Re] Patch: Fix broken pe.sc script template for relocatables
- From: Danny Smith <danny_r_smith_2001 at yahoo dot co dot nz>
- To: binutils <binutils at sources dot redhat dot com>
- Date: Mon, 21 Oct 2002 05:56:49 +1000 (EST)
- Subject: [Re] Patch: Fix broken pe.sc script template for relocatables
This is a refresh of
http://sources.redhat.com/ml/binutils/2002-10/msg00159.html
The __RUNTIME_PSEUDO_RELOC_LIST__ addition to pe ldscripts
2002-08-27 Egor Duda <deo@logos-m.ru>
* scripttempl/pe.sc: Handle .rdata_runtime_pseudo_reloc sections.
Add symbols for application to access them.
causes subsequent link problems with objects made using ld --relocateable
because of multiple definitions. The symbols should only be added in the
final link. This fixes:
2002-10-21 Danny Smith <dannysmith@users.sourceforeg.net>
* scripttempl/pe.sc (__RUNTIME_PSEUDO_RELOC_LIST__,
__RUNTIME_PSEUDO_RELOC_LIST_END__): Add only when relocating.
Index: pe.sc
===================================================================
RCS file: /cvs/src/src/ld/scripttempl/pe.sc,v
retrieving revision 1.6
diff -u -p -r1.6 pe.sc
--- pe.sc 27 Aug 2002 11:12:53 -0000 1.6
+++ pe.sc 8 Oct 2002 19:25:58 -0000
@@ -85,11 +85,11 @@ SECTIONS
*(.rdata)
${R_RDATA}
*(.eh_frame)
- ___RUNTIME_PSEUDO_RELOC_LIST__ = .;
- __RUNTIME_PSEUDO_RELOC_LIST__ = .;
+ ${RELOCATING+___RUNTIME_PSEUDO_RELOC_LIST__ = .;}
+ ${RELOCATING+__RUNTIME_PSEUDO_RELOC_LIST__ = .;}
*(.rdata_runtime_pseudo_reloc)
- ___RUNTIME_PSEUDO_RELOC_LIST_END__ = .;
- __RUNTIME_PSEUDO_RELOC_LIST_END__ = .;
+ ${RELOCATING+___RUNTIME_PSEUDO_RELOC_LIST_END__ = .;}
+ ${RELOCATING+__RUNTIME_PSEUDO_RELOC_LIST_END__ = .;}
}
.pdata ${RELOCATING+BLOCK(__section_alignment__)} :
http://careers.yahoo.com.au - Yahoo! Careers
- 1,000's of jobs waiting online for you!