diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2008-01-07 16:45:35 +0000 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2008-01-07 16:45:35 +0000 |
commit | ace793883816ba44f9c2cb090e8ea5ff159ad9be (patch) | |
tree | 42521bfb0c2c65a16935d8524cf416ceb336a50b /ld/testsuite/ld-elf | |
parent | a7c02bc8e11894a2c8ac3f834961f214229a4d51 (diff) | |
download | gdb-ace793883816ba44f9c2cb090e8ea5ff159ad9be.zip gdb-ace793883816ba44f9c2cb090e8ea5ff159ad9be.tar.gz gdb-ace793883816ba44f9c2cb090e8ea5ff159ad9be.tar.bz2 |
bfd/
2008-01-07 H.J. Lu <hongjiu.lu@intel.com>
PR ld/5522
* elflink.c (elf_link_input_bfd): Don't write out a section if
its output section is marked with SEC_NEVER_LOAD.
ld/testsuite/
2008-01-07 H.J. Lu <hongjiu.lu@intel.com>
PR ld/5522
* ld-elf/noload-3.d: New file.
* ld-elf/noload-3.s: Likewise.
* ld-elf/noload-3.t: Likewise.
Diffstat (limited to 'ld/testsuite/ld-elf')
-rw-r--r-- | ld/testsuite/ld-elf/noload-3.d | 7 | ||||
-rw-r--r-- | ld/testsuite/ld-elf/noload-3.s | 6 | ||||
-rw-r--r-- | ld/testsuite/ld-elf/noload-3.t | 7 |
3 files changed, 20 insertions, 0 deletions
diff --git a/ld/testsuite/ld-elf/noload-3.d b/ld/testsuite/ld-elf/noload-3.d new file mode 100644 index 0000000..84b27d7 --- /dev/null +++ b/ld/testsuite/ld-elf/noload-3.d @@ -0,0 +1,7 @@ +#ld: -T noload-3.t +#objdump: -s -j .foo1 + +#... +Contents of section .foo1: + [0-9a-f]+ [0-9a-f]+ [0-9a-f]+ [0-9a-f]+ [0-9a-f]+[ \t]+This is a test.* +#pass diff --git a/ld/testsuite/ld-elf/noload-3.s b/ld/testsuite/ld-elf/noload-3.s new file mode 100644 index 0000000..84aa2e2 --- /dev/null +++ b/ld/testsuite/ld-elf/noload-3.s @@ -0,0 +1,6 @@ + .section .foo2,"aw",%progbits + .byte 1 + .section .foo1,"w",%progbits + .string "This is a test." + .section .foo,"aw",%progbits + .space 16 diff --git a/ld/testsuite/ld-elf/noload-3.t b/ld/testsuite/ld-elf/noload-3.t new file mode 100644 index 0000000..fbb5166 --- /dev/null +++ b/ld/testsuite/ld-elf/noload-3.t @@ -0,0 +1,7 @@ +SECTIONS +{ + .foo2 : { *(.foo2) } + .foo1 : { *(.foo1) } + .foo (NOLOAD) : { *(.foo) } + /DISCARD/ : { *(*) } +} |