[llvm-dlltool] Respect NONAME keyword
[llvm-complete.git] / test / tools / llvm-elfabi / binary-read-neededlibs-bad-offset.test
blob6b7ba8b2d1989bc3a7fc2a4a7e0c714158efd5b8
1 # RUN: yaml2obj %s > %t
2 # RUN: not llvm-elfabi --elf %t --emit-tbe=%t.tbe 2>&1 | FileCheck %s
4 !ELF
5 FileHeader:
6   Class:           ELFCLASS64
7   Data:            ELFDATA2LSB
8   Type:            ET_DYN
9   Machine:         EM_X86_64
10 Sections:
11   - Name:            .dynstr
12     Type:            SHT_STRTAB
13     Flags:           [ SHF_ALLOC ]
14     Address:         0x1000
15     #                "\0libfoo.so\0libbar.so\0somelib.so\0foo\0"
16     Content:         "006c6962666f6f2e736f006c69626261722e736f00736f6d656c69622e736f00666f6f00"
17   - Name:            .dynamic
18     Type:            SHT_DYNAMIC
19     Flags:           [ SHF_ALLOC ]
20     Address:         0x0000000000001024
21     EntSize:         0x0000000000000010
22     Entries:
23       - Tag:             DT_NEEDED
24         Value:           0x0000000000000001
25       - Tag:             DT_SONAME
26         Value:           0x0000000000000015
27       # Bad DT_NEEDED entry (offset outside string table):
28       - Tag:             DT_NEEDED
29         Value:           0x000000000000FFFF
30       - Tag:             DT_STRSZ
31         Value:           0x0000000000000024
32       - Tag:             DT_STRTAB
33         Value:           0x0000000000001000
34       - Tag:             DT_SYMTAB
35         Value:           0x0000000000001000
36       - Tag:             DT_NULL
37         Value:           0x0000000000000000
38 ProgramHeaders:
39   - Type: PT_LOAD
40     Flags: [ PF_R ]
41     VAddr: 0x1000
42     PAddr: 0x1000
43     Align: 8
44     Sections:
45       - Section: .dynstr
46       - Section: .dynamic
47   - Type: PT_DYNAMIC
48     Flags: [ PF_X, PF_R ]
49     VAddr: 0x1024
50     PAddr: 0x1024
51     Sections:
53 # CHECK: DT_NEEDED string offset (0x000000000000ffff) outside of dynamic string table