blob: 761cd1aca69fd94ddf7c05725fb3e0e1f52400f6 [file] [log] [blame]
Rafael Espindola9cef2152013-07-12 19:34:24 +00001Test the 'u' option of llvm-ar
2
3REQUIRES: shell
4
5RUN: cd %T
6RUN: rm -f %t.a
7
8Create an achive with the newest file
9RUN: llvm-ar r %t.a %p/Inputs/AUX/evenlen
10RUN: llvm-ar p %t.a | FileCheck --check-prefix=NEWER %s
11
12Check that without the 'u' option the member is replaced with an older file.
13RUN: llvm-ar r %t.a %p/Inputs/evenlen
14RUN: llvm-ar p %t.a | FileCheck --check-prefix=OLDER %s
15
16Check that with the 'u' option the member is replaced with a newer file.
17RUN: llvm-ar ru %t.a %p/Inputs/AUX/evenlen
18RUN: llvm-ar p %t.a | FileCheck --check-prefix=NEWER %s
19
20Check that with the 'u' option the member is not replaced with an older file.
21RUN: llvm-ar ru %t.a %p/Inputs/evenlen
22RUN: llvm-ar p %t.a | FileCheck --check-prefix=NEWER %s
23
24NEWER: newer
25OLDER: evenlen