1## Show that the help message for llvm-ranlib can be printed with either the 2## long flag -help. 3 4# RUN: llvm-ranlib -h | FileCheck %s --check-prefix=HELP 5# RUN: llvm-ranlib -help | FileCheck %s --check-prefix=HELP 6# RUN: llvm-ranlib --help | FileCheck %s --check-prefix=HELP 7# RUN: llvm-ranlib --version | FileCheck %s --check-prefix=VERSION 8# RUN: llvm-ranlib -V | FileCheck %s --check-prefix=VERSION 9 10## Also check combined options (first -h/-v flag wins) 11# RUN: llvm-ranlib -Dh | FileCheck %s --check-prefix=HELP 12# RUN: llvm-ranlib -DVh | FileCheck %s --check-prefix=VERSION 13# RUN: llvm-ranlib -DhV | FileCheck %s --check-prefix=HELP 14 15# HELP: USAGE: llvm-ranlib 16# VERSION: version 17 18## -v enables verbose output in BSD ranlib and GNU ar but is another alias 19## for --version in GNU ranlib. Reject -v. 20# RUN: not llvm-ranlib -v 2>&1 | FileCheck %s --check-prefix=ERR1 21# RUN: not llvm-ranlib -version 2>&1 | FileCheck %s --check-prefix=ERR2 22# RUN: not llvm-ranlib -Dvh 2>&1 | FileCheck %s --check-prefix=ERR3 23 24# ERR1: error: Invalid option: '-v' 25# ERR2: error: Invalid option: '-version' 26# ERR3: error: Invalid option: '-vh' 27