1 ## Test the ADDMOD MRI command.
3 # RUN: rm -rf %t && split-file %s %t
5 # RUN: yaml2obj %s -o f.o
7 # RUN: llvm-ar -M < add-mod.mri
8 # RUN: llvm-nm --print-armap add-mod.a | FileCheck --check-prefix=SYMS %s
9 # RUN: llvm-ar t add-mod.a | FileCheck --check-prefix=FILES %s
15 # RUN: not llvm-ar -M < no-create.mri 2>&1 | FileCheck --check-prefix=NOCREATE %s
17 # NOCREATE: error: script line 1: no output archive has been opened
19 ## ADDMOD with missing file.
20 # RUN: not llvm-ar -M < missing.mri 2>&1 | FileCheck -DMSG=%errc_ENOENT %s --check-prefix=MISSING
21 # RUN: not ls missing.a
23 # MISSING: error: script line 2: missing.o: [[MSG]]
25 ## ADD same file twice.
26 # RUN: llvm-ar -M < duplicate.mri
27 # RUN: llvm-nm --print-armap duplicate.a | FileCheck --check-prefix=SYMS2 %s
28 # RUN: llvm-ar t duplicate.a | FileCheck --check-prefix=FILES2 %s
30 # SYMS2-COUNT-2: f in {{.*}}