summaryrefslogtreecommitdiff
path: root/test/Object/ar-create.test
blob: 40e391da029fa1c1e265c8072da5e9431112d6f8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
Test which operations create an archive and which don't.

RUN: touch %t
RUN: rm -f %t.foo.a
RUN: not llvm-ar p %t.foo.a %t 2>&1 | FileCheck %s
RUN: not llvm-ar d %t.foo.a %t 2>&1 | FileCheck %s
RUN: not llvm-ar m %t.foo.a %t 2>&1 | FileCheck %s
RUN: not llvm-ar t %t.foo.a %t 2>&1 | FileCheck %s
RUN: not llvm-ar x %t.foo.a %t 2>&1 | FileCheck %s

RUN: llvm-ar q %t.foo.a %t 2>&1 | FileCheck --check-prefix=CREATE %s
RUN: rm -f %t.foo.a
RUN: llvm-ar r %t.foo.a %t 2>&1 | FileCheck --check-prefix=CREATE %s
RUN: rm -f %t.foo.a

CHECK: .foo.a': No such file or directory
CREATE: creating {{.*}}.foo.a