[PATCH] D146796: [llvm-rc] Fix the reference to the option for disabling preprocessing in a message
Martin Storsjö via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 28 01:04:06 PDT 2023
This revision was automatically updated to reflect the committed changes.
Closed by commit rG014e5c8d39c1: [llvm-rc] Fix the reference to the option for disabling preprocessing in a… (authored by mstorsjo).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D146796/new/
https://reviews.llvm.org/D146796
Files:
llvm/tools/llvm-rc/llvm-rc.cpp
Index: llvm/tools/llvm-rc/llvm-rc.cpp
===================================================================
--- llvm/tools/llvm-rc/llvm-rc.cpp
+++ llvm/tools/llvm-rc/llvm-rc.cpp
@@ -219,6 +219,7 @@
std::string OutputFile;
Format OutputFormat = Res;
+ bool IsWindres = false;
bool BeVerbose = false;
WriterParams Params;
bool AppendNull = false;
@@ -239,9 +240,12 @@
} else {
errs() << "llvm-rc: Unable to find clang, skipping preprocessing."
<< "\n";
- errs() << "Pass -no-cpp to disable preprocessing. This will be an error "
- "in the future."
- << "\n";
+ StringRef OptionName =
+ Opts.IsWindres ? "--no-preprocess" : "-no-preprocess";
+ errs()
+ << "Pass " << OptionName
+ << " to disable preprocessing. This will be an error in the future."
+ << "\n";
return false;
}
}
@@ -366,6 +370,8 @@
unsigned MAI, MAC;
opt::InputArgList InputArgs = T.ParseArgs(ArgsArr, MAI, MAC);
+ Opts.IsWindres = true;
+
// The tool prints nothing when invoked with no command-line arguments.
if (InputArgs.hasArg(WINDRES_help)) {
T.printHelp(outs(), "windres [options] file...",
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D146796.508919.patch
Type: text/x-patch
Size: 1217 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230328/33673f5f/attachment.bin>
More information about the llvm-commits
mailing list