ar-create.test 622 B

1234567891011121314151617
  1. Test which operations create an archive and which don't.
  2. RUN: touch %t
  3. RUN: rm -f %t.foo.a
  4. RUN: not llvm-ar p %t.foo.a %t 2>&1 | FileCheck %s
  5. RUN: not llvm-ar d %t.foo.a %t 2>&1 | FileCheck %s
  6. RUN: not llvm-ar m %t.foo.a %t 2>&1 | FileCheck %s
  7. RUN: not llvm-ar t %t.foo.a %t 2>&1 | FileCheck %s
  8. RUN: not llvm-ar x %t.foo.a %t 2>&1 | FileCheck %s
  9. RUN: llvm-ar q %t.foo.a %t 2>&1 | FileCheck --check-prefix=CREATE %s
  10. RUN: rm -f %t.foo.a
  11. RUN: llvm-ar r %t.foo.a %t 2>&1 | FileCheck --check-prefix=CREATE %s
  12. RUN: rm -f %t.foo.a
  13. CHECK: llvm-ar{{(.exe|.EXE)?}}: error loading '{{[^']+}}.foo.a':
  14. CREATE: creating {{.*}}.foo.a