mirror of
https://github.com/intel/llvm.git
synced 2026-01-20 19:07:53 +08:00
Driver/Linux: Translate rewritten lib options back to standard -l form when
using generic GCC tools. llvm-svn: 114793
This commit is contained in:
@@ -1693,9 +1693,18 @@ void gcc::Common::ConstructJob(Compilation &C, const JobAction &JA,
|
||||
|
||||
if (II.isFilename())
|
||||
CmdArgs.push_back(II.getFilename());
|
||||
else
|
||||
else {
|
||||
const Arg &A = II.getInputArg();
|
||||
|
||||
// Reverse translate some rewritten options.
|
||||
if (A.getOption().matches(options::OPT_Z_reserved_lib_stdcxx)) {
|
||||
CmdArgs.push_back("-lstdc++");
|
||||
continue;
|
||||
}
|
||||
|
||||
// Don't render as input, we need gcc to do the translations.
|
||||
II.getInputArg().render(Args, CmdArgs);
|
||||
A.render(Args, CmdArgs);
|
||||
}
|
||||
}
|
||||
|
||||
const char *GCCName = getToolChain().getDriver().getCCCGenericGCCName().c_str();
|
||||
|
||||
Reference in New Issue
Block a user