Recommit "rL366894: [yaml2obj] - Allow custom fields for the SHT_UNDEF sections."
[llvm-complete.git] / test / tools / yaml2obj / relocation-missing-symbol.yaml
blob7edbf188a21f49efce10cf0c5dee7a12a99ce5cd
1 # Show that yaml2obj rejects a symbol reference from a relocation if the symbol
2 # does not exist.
4 # RUN: not yaml2obj %s -o %t 2>&1 | FileCheck %s
6 # CHECK: Unknown symbol referenced: 'does_not_exist' at YAML section '.rela.text'
8 --- !ELF
9 FileHeader:
10   Class:   ELFCLASS64
11   Data:    ELFDATA2LSB
12   Type:    ET_REL
13   Machine: EM_X86_64
14 Sections:
15   - Name: .text
16     Type: SHT_PROGBITS
17   - Name: .rela.text
18     Type: SHT_RELA
19     Info: .text
20     Link: .symtab
21     Relocations:
22       - Type: R_X86_64_PC32
23         Offset: 0
24         Symbol: does_not_exist