mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[PrefixMap] Remap clang cc1 args when building swift interfaces
Fix a bug that swift clang importer is not setup correctly when prefix map is used. There are two separate issues: * CC1 args used to setup clang import when building swift (interface and sources) are not correctly remapped. * When loading SDKInfo from SDK path, the SDKSettings.json is not loading from VFS, thus the file cannot be loaded from remapped path. rdar://134458611
This commit is contained in:
@@ -1787,6 +1787,9 @@ void InterfaceSubContextDelegateImpl::inheritOptionsForBuildingInterface(
|
||||
genericSubInvocation.getClangImporterOptions().ClangImporterDirectCC1Scan =
|
||||
clangImporterOpts.ClangImporterDirectCC1Scan;
|
||||
|
||||
genericSubInvocation.getSearchPathOptions().ScannerPrefixMapper =
|
||||
SearchPathOpts.ScannerPrefixMapper;
|
||||
|
||||
// Validate Clang modules once per-build session flags must be consistent
|
||||
// across all module sub-invocations
|
||||
if (clangImporterOpts.ValidateModulesOnce) {
|
||||
|
||||
Reference in New Issue
Block a user