This rewrites the test using yaml.
llvm-svn: 339775
// RUN: not ld.lld %t.o -o /dev/null 2>&1 | FileCheck %s
// CHECK: SHF_MERGE section size must be a multiple of sh_entsize
-// Test that we accept a zero sh_entsize.
-// RUN: ld.lld %p/Inputs/shentsize-zero.elf -o /dev/null
-
.section .foo,"aM",@progbits,4
.short 42
--- /dev/null
+# REQUIRES: x86
+
+# RUN: yaml2obj %s -o %t.o
+
+# Test that we accept a zero sh_entsize for SHF_MERGE section.
+# RUN: ld.lld %t.o -o %t.exe
+
+!ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ OSABI: ELFOSABI_FREEBSD
+ Type: ET_REL
+ Machine: EM_X86_64
+Sections:
+ - Type: SHT_PROGBITS
+ Name: .strings
+ Flags: [ SHF_ALLOC, SHF_MERGE, SHF_STRINGS ]
+ AddressAlign: 0x04
+ Content: "FFFFFFFFFFFFFFFF"
+ EntSize: 0x0