mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
[ClangImporter] Simply clang-importer creation flags
Currently, `-direct-clang-cc1-module-build` and `-only-use-extra-clang-opts` have to be passed together for clang importer creation to succeed. Missing either will result in error. Simplified the swift-frontend flags by removing `-only-use-extra-clang-opts` and let `-direct-clang-cc1-module-build` to do both.
This commit is contained in:
@@ -167,10 +167,6 @@ ModuleDependencyVector ClangImporter::bridgeClangModuleDependencies(
|
||||
swiftArgs.push_back("-module-name");
|
||||
swiftArgs.push_back(clangModuleDep.ID.ModuleName);
|
||||
|
||||
// We pass the entire argument list via -Xcc, so the invocation should
|
||||
// use extra clang options alone.
|
||||
swiftArgs.push_back("-only-use-extra-clang-opts");
|
||||
|
||||
auto pcmPath = moduleCacheRelativeLookupModuleOutput(
|
||||
clangModuleDep.ID, ModuleOutputKind::ModuleFile, moduleOutputPath);
|
||||
swiftArgs.push_back("-o");
|
||||
@@ -307,10 +303,6 @@ void ClangImporter::recordBridgingHeaderOptions(
|
||||
// Swift frontend action: -emit-pcm
|
||||
swiftArgs.push_back("-emit-pch");
|
||||
|
||||
// We pass the entire argument list via -Xcc, so the invocation should
|
||||
// use extra clang options alone.
|
||||
swiftArgs.push_back("-only-use-extra-clang-opts");
|
||||
|
||||
// Ensure that the resulting PCM build invocation uses Clang frontend
|
||||
// directly
|
||||
swiftArgs.push_back("-direct-clang-cc1-module-build");
|
||||
|
||||
Reference in New Issue
Block a user