diff options
Diffstat (limited to 'ld')
-rw-r--r-- | ld/ChangeLog | 6 | ||||
-rw-r--r-- | ld/testsuite/ld-elf/anno-sym.d | 5 | ||||
-rw-r--r-- | ld/testsuite/ld-elf/anno-sym.l | 4 | ||||
-rw-r--r-- | ld/testsuite/ld-elf/anno-sym.s | 13 |
4 files changed, 28 insertions, 0 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog index 9bb178e..3c4bec5 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,9 @@ +2021-04-28 Nick Clifton <nickc@redhat.com> + + * testsuite/ld-elf/anno-sym.s: New test source file. + * testsuite/ld-elf/anno-sym.d: New test driver. + * testsuite/ld-elf/anno-sym.l: New test error output. + 2021-04-26 Jan Beulich <jbeulich@suse.com> * testsuite/ld-i386/pcrel16-2.s, testsuite/ld-i386/pcrel16-2.d, diff --git a/ld/testsuite/ld-elf/anno-sym.d b/ld/testsuite/ld-elf/anno-sym.d new file mode 100644 index 0000000..9e53c4a --- /dev/null +++ b/ld/testsuite/ld-elf/anno-sym.d @@ -0,0 +1,5 @@ +# Check that linking anno-sym.o produces an undefined reference message referring to '_start' and not 'annobin_hello.c' +#ld: -e _start +#error_output: anno-sym.l +# The mips-irix6 target fails this test because it does not find any function symbols. Not sure why. +#skip: *-*-irix* diff --git a/ld/testsuite/ld-elf/anno-sym.l b/ld/testsuite/ld-elf/anno-sym.l new file mode 100644 index 0000000..ee9611a --- /dev/null +++ b/ld/testsuite/ld-elf/anno-sym.l @@ -0,0 +1,4 @@ +#... +.*: in function `(|_)start': +.*: undefined reference to `foo' +#pass diff --git a/ld/testsuite/ld-elf/anno-sym.s b/ld/testsuite/ld-elf/anno-sym.s new file mode 100644 index 0000000..0e4b5aa --- /dev/null +++ b/ld/testsuite/ld-elf/anno-sym.s @@ -0,0 +1,13 @@ + .text + + .hidden .annobin_hello.c + .type .annobin_hello.c, STT_NOTYPE + .equiv .annobin_hello.c, . + .size .annobin_hello.c, 0 + + .global _start +_start: + .nop + .align 4 + .dc.a foo + |