This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: binutils-2.19.90 snapshot is available
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: "H.J. Lu" <hjl dot tools at gmail dot com>, binutils at sourceware dot org, Tristan Gingold <gingold at adacore dot com>, Dave Korn <dave dot korn dot cygwin at googlemail dot com>
- Date: Fri, 9 Oct 2009 06:34:54 -0700
- Subject: Re: binutils-2.19.90 snapshot is available
- References: <20090913022526.GR28290@bubble.grove.modra.org> <20090913160312.GA11300@ednor.casa.cgf.cx> <20090913160931.GA19246@ednor.casa.cgf.cx> <20090921214900.GA17794@ednor.casa.cgf.cx> <4AB84B22.7010901@gmail.com> <20090923203325.GA4166@ednor.casa.cgf.cx> <20090923215610.GB28784@bubble.grove.modra.org> <20090927160942.GA8212@ednor.casa.cgf.cx> <6dc9ffc80910082111h196d9315k7d316b1479359b2f@mail.gmail.com> <20091009052017.GL7842@bubble.grove.modra.org>
On Thu, Oct 8, 2009 at 10:20 PM, Alan Modra <amodra@bigpond.net.au> wrote:
> On Thu, Oct 08, 2009 at 09:11:02PM -0700, H.J. Lu wrote:
>> This patch may have caused:
>>
>> http://sourceware.org/bugzilla/show_bug.cgi?id=10749
>
> Yes, it did. ?I'm going to apply the following patch to both
> mainline and branch, and revert my 2009-09-28 patch
> http://sourceware.org/ml/binutils/2009-09/msg00646.html on the
> branch.
>
I checked in a testcase for it.
Thanks.
--
H.J.
---
2009-10-09 H.J. Lu <hongjiu.lu@intel.com>
PR ld/10749
* ld-elf/relocatable.d: New.
* ld-elf/relocatable.t: Likewise.
* ld-elf/simple.s: Likewise.
diff --git a/ld/testsuite/ld-elf/relocatable.d
b/ld/testsuite/ld-elf/relocatable.d
new file mode 100644
index 0000000..be4847a
--- /dev/null
+++ b/ld/testsuite/ld-elf/relocatable.d
@@ -0,0 +1,9 @@
+#name: relocatable with script
+#source: simple.s
+#ld: -r -T relocatable.t
+#readelf: -S --wide
+
+#...
+ \[[ 0-9]+\] \.text.*[ \t]+PROGBITS[ \t]+0+800000[ \t0-9a-f]+AX.*
+ \[[ 0-9]+\] \.data.*[ \t]+PROGBITS[ \t]+0+900000[ \t0-9a-f]+WA.*
+#pass
diff --git a/ld/testsuite/ld-elf/relocatable.t
b/ld/testsuite/ld-elf/relocatable.t
new file mode 100644
index 0000000..2ec056a
--- /dev/null
+++ b/ld/testsuite/ld-elf/relocatable.t
@@ -0,0 +1,8 @@
+SECTIONS
+{
+ . = 0x800000;
+ .text : { *(.text) }
+ . = 0x900000;
+ .data : { *(.data) }
+ /DISCARD/ : { *(.*) }
+}
diff --git a/ld/testsuite/ld-elf/simple.s b/ld/testsuite/ld-elf/simple.s
new file mode 100644
index 0000000..2834182
--- /dev/null
+++ b/ld/testsuite/ld-elf/simple.s
@@ -0,0 +1,4 @@
+ .text
+ .long 1
+ .data
+ .long 2