Merge pull request #32690 from compnerd/grand-unified-module-theory

Unified Swift Module Layout
This commit is contained in:
Saleem Abdulrasool
2020-09-15 17:23:15 -07:00
committed by GitHub
5 changed files with 43 additions and 80 deletions

View File

@@ -137,10 +137,14 @@ static void updateRuntimeLibraryPaths(SearchPathOptions &SearchPathOpts,
if (SearchPathOpts.SkipRuntimeLibraryImportPaths)
return;
if (!Triple.isOSDarwin())
llvm::sys::path::append(LibPath, swift::getMajorArchitectureName(Triple));
SearchPathOpts.RuntimeLibraryImportPaths.push_back(std::string(LibPath.str()));
// This is compatibility for <=5.3
if (!Triple.isOSDarwin()) {
llvm::sys::path::append(LibPath, swift::getMajorArchitectureName(Triple));
SearchPathOpts.RuntimeLibraryImportPaths.push_back(std::string(LibPath.str()));
}
if (!SearchPathOpts.SDKPath.empty()) {
if (tripleIsMacCatalystEnvironment(Triple)) {
LibPath = SearchPathOpts.SDKPath;