Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lld / test / MachO / invalid / bad-archive-member.s
blob418129d5dfefe8fbfee8bf798dba76366d7dfcbb
1 # REQUIRES: x86
2 # RUN: rm -rf %t; split-file %s %t
3 # RUN: llvm-mc -filetype=obj -triple=x86_64-apple-darwin %t/foo.s -o %t/foo.o
4 # RUN: llvm-mc -filetype=obj -triple=x86_64-apple-darwin %t/test.s -o %t/test.o
5 # RUN: %lld -dylib -lSystem %t/foo.o -o %t/foo.dylib
6 # RUN: llvm-ar rcs %t/foo.a %t/foo.dylib
7 # RUN: not %lld %t/test.o %t/foo.a -o /dev/null 2>&1 | FileCheck %s \
8 # RUN: --check-prefix=SYM -DFILE=%t/foo.a
9 # RUN: not %lld %t/test.o -ObjC %t/foo.a -o /dev/null 2>&1 | FileCheck %s \
10 # RUN: --check-prefix=SYM -DFILE=%t/foo.a
11 # RUN: not %lld %t/test.o -force_load %t/foo.a -o /dev/null 2>&1 | FileCheck %s \
12 # RUN: --check-prefix=FORCE-LOAD -DFILE=%t/foo.a
13 # SYM: error: [[FILE]]: could not get the member defining symbol _foo: foo.dylib has unhandled file type
14 # FORCE-LOAD: error: [[FILE]]: -force_load failed to load archive member: foo.dylib has unhandled file type
16 #--- foo.s
17 .globl _foo
18 _foo:
19 ret
21 #--- test.s
22 .globl _main
23 _main:
24 callq _foo
25 ret