mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[Driver] Pass -emit-tbd through to -frontend -merge-modules, to get TBD files without -wmo.
Fixes rdar://problem/33735706
This commit is contained in:
@@ -769,9 +769,13 @@ static bool writeTBDIfNeeded(CompilerInvocation &Invocation,
|
||||
if (!frontendOpts.InputsAndOutputs.hasTBDPath())
|
||||
return false;
|
||||
|
||||
if (!frontendOpts.InputsAndOutputs.isWholeModule()) {
|
||||
Instance.getDiags().diagnose(SourceLoc(),
|
||||
diag::tbd_only_supported_in_whole_module);
|
||||
return false;
|
||||
}
|
||||
|
||||
const std::string &TBDPath = Invocation.getTBDPathForWholeModule();
|
||||
assert(!TBDPath.empty() &&
|
||||
"If not WMO, getTBDPathForWholeModule should have failed");
|
||||
|
||||
auto installName = frontendOpts.TBDInstallName.empty()
|
||||
? "lib" + Invocation.getModuleName().str() + ".dylib"
|
||||
|
||||
Reference in New Issue
Block a user