This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [Bug ld/3103] New: ld lma assignment change changes OVERLAY
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: hjl at lucon dot org, binutils at sourceware dot org
- Date: Wed, 23 Aug 2006 11:04:29 +0930
- Subject: Re: [Bug ld/3103] New: ld lma assignment change changes OVERLAY
- References: <20060822171233.3103.hjl@lucon.org>
On Tue, Aug 22, 2006 at 05:12:34PM -0000, hjl at lucon dot org wrote:
> http://sourceware.org/ml/binutils/2006-07/msg00314.html
>
> changes the section symbol for OVERLAY:
[snip]
> 3: 0000000000004000 0 NOTYPE GLOBAL DEFAULT ABS __load_start_text1
> 4: 0000000000004010 0 NOTYPE GLOBAL DEFAULT 2 __load_start_text2
That does look a little silly.
* ldexp.c (fold_name <LOADADDR>): Return an absolute value
rather than a section relative value.
Index: ld/ldexp.c
===================================================================
RCS file: /cvs/src/src/ld/ldexp.c,v
retrieving revision 1.62
diff -u -p -r1.62 ldexp.c
--- ld/ldexp.c 16 Aug 2006 08:31:45 -0000 1.62
+++ ld/ldexp.c 23 Aug 2006 00:37:22 -0000
@@ -577,8 +577,7 @@ fold_name (etree_type *tree)
if (os != NULL && os->processed_lma)
{
if (os->load_base == NULL)
- new_rel (os->bfd_section->lma - os->bfd_section->vma,
- NULL, os->bfd_section);
+ new_abs (os->bfd_section->lma);
else
exp_fold_tree_1 (os->load_base);
}
--
Alan Modra
IBM OzLabs - Linux Technology Centre