* ldexp.c (fold_name): Loadaddrs of sections with an lma_region
are absolute.
ld/testsuite/
* ld-elf/loadaddr3.t: New.
* ld-elf/loadaddr3a.d: New.
* ld-elf/loadaddr3b.d: New.
+2006-08-29 Nathan Sidwell <nathan@codesourcery.com>
+
+ ld/
+ * ldexp.c (fold_name): Loadaddrs of sections with an lma_region
+ are absolute.
+
+ ld/testsuite/
+ * ld-elf/loadaddr3.t: New.
+ * ld-elf/loadaddr3a.d: New.
+ * ld-elf/loadaddr3b.d: New.
+
2006-08-24 Mark Shinwell <shinwell@codesourcery.com>
bfd/
if (os->load_base == NULL)
new_rel (0, NULL, os->bfd_section);
else
- exp_fold_tree_1 (os->load_base);
+ {
+ exp_fold_tree_1 (os->load_base);
+ /* If this section has a load region, the expression
+ will be absolute. */
+ if (os->lma_region && expld.result.valid_p)
+ expld.result.section = bfd_abs_section_ptr;
+ }
+
}
}
break;
#source: loadaddr.s
-#ld: -T loadaddr3.t -z max-page-size=0x200000
+#ld: -T loadaddr3.t
#readelf: -l --wide
-#target: *-*-linux*
+#target: *-*-elf*
#...
LOAD +0x000000 0x0*00000000 0x0*00000000 0x0*0101 0x0*0101 R E 0x.*
#source: loadaddr.s
-#ld: -T loadaddr3.t -z max-page-size=0x200000
+#ld: -T loadaddr3.t
#objdump: -t
-#target: *-*-linux*
+#target: *-*-elf*
#...
0+0000100 l d .text 0+0000000 .text