mirror of
https://github.com/RPCS3/llvm.git
synced 2025-03-03 16:18:37 +00:00
Give llvm-lib rudimentary help output.
https://reviews.llvm.org/D49318 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@337084 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
60ba444e11
commit
981f0755e2
@ -121,6 +121,12 @@ int llvm::libDriverMain(ArrayRef<const char *> ArgsArr) {
|
|||||||
for (auto *Arg : Args.filtered(OPT_UNKNOWN))
|
for (auto *Arg : Args.filtered(OPT_UNKNOWN))
|
||||||
llvm::errs() << "ignoring unknown argument: " << Arg->getSpelling() << "\n";
|
llvm::errs() << "ignoring unknown argument: " << Arg->getSpelling() << "\n";
|
||||||
|
|
||||||
|
// Handle /help
|
||||||
|
if (Args.hasArg(OPT_help)) {
|
||||||
|
Table.PrintHelp(outs(), ArgsArr[0], "LLVM Lib");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
// If no input files, silently do nothing to match lib.exe.
|
// If no input files, silently do nothing to match lib.exe.
|
||||||
if (!Args.hasArgNoClaim(OPT_INPUT))
|
if (!Args.hasArgNoClaim(OPT_INPUT))
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -12,7 +12,11 @@ class P<string name, string help> :
|
|||||||
def libpath: P<"libpath", "Object file search path">;
|
def libpath: P<"libpath", "Object file search path">;
|
||||||
def out : P<"out", "Path to file to write output">;
|
def out : P<"out", "Path to file to write output">;
|
||||||
|
|
||||||
def llvmlibthin : F<"llvmlibthin">;
|
def llvmlibthin : F<"llvmlibthin">,
|
||||||
|
HelpText<"Make .lib point to .obj files instead of copying their contents">;
|
||||||
|
|
||||||
|
def help : F<"help">;
|
||||||
|
def help_q : Flag<["/?", "-?"], "">, Alias<help>;
|
||||||
|
|
||||||
//==============================================================================
|
//==============================================================================
|
||||||
// The flags below do nothing. They are defined only for lib.exe compatibility.
|
// The flags below do nothing. They are defined only for lib.exe compatibility.
|
||||||
|
3
test/tools/llvm-lib/help.test
Normal file
3
test/tools/llvm-lib/help.test
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
# RUN: llvm-lib /? | FileCheck %s
|
||||||
|
|
||||||
|
CHECK: OVERVIEW: LLVM Lib
|
Loading…
x
Reference in New Issue
Block a user