This allows libtool to detect the presence of llvm-strip and use
it with the options --strip-debug and --strip-unneeded.
Also hook up the -V alias for objcopy.
Differential Revision: https://reviews.llvm.org/D54936
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@347731
91177308-0d34-0410-b5e6-
96231b3b80d8
# RUN: llvm-objcopy -version | FileCheck %s
# RUN: llvm-objcopy --version | FileCheck %s
+# RUN: llvm-objcopy -V | FileCheck %s
# CHECK: {{ version }}
# RUN: llvm-strip -version | FileCheck %s
# RUN: llvm-strip --version | FileCheck %s
+# RUN: llvm-strip -V | FileCheck %s
-# CHECK: {{ version }}
+# CHECK-DAG: {{ version }}
+# CHECK-DAG: GNU strip
}
if (InputArgs.hasArg(OBJCOPY_version)) {
+ outs() << "llvm-objcopy, compatible with GNU objcopy\n";
cl::PrintVersionMessage();
exit(0);
}
}
if (InputArgs.hasArg(STRIP_version)) {
+ outs() << "llvm-strip, compatible with GNU strip\n";
cl::PrintVersionMessage();
exit(0);
}
def version : Flag<["-", "--"], "version">,
HelpText<"Print the version and exit.">;
+def V : Flag<["-"], "V">, Alias<version>;
def version : Flag<["-", "--"], "version">,
HelpText<"Print the version and exit.">;
+def V : Flag<["-"], "V">, Alias<version>;