aboutsummaryrefslogtreecommitdiff
path: root/lib/Frontend/CompilerInstance.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2011-09-15 22:00:41 +0000
committerDouglas Gregor <dgregor@apple.com>2011-09-15 22:00:41 +0000
commitfba18aa8f2cd1994dc65e8cb9f4be201c560dc0b (patch)
tree7d8906cda58e7645cc60254e4ed7bc34f28247f3 /lib/Frontend/CompilerInstance.cpp
parentdd22509c82eb7681a0f46b41d61cb2e25a4d8fa1 (diff)
Add an experimental flag -fauto-module-import that automatically turns
#include or #import direcctives of framework headers into module imports of the corresponding framework module. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139860 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Frontend/CompilerInstance.cpp')
-rw-r--r--lib/Frontend/CompilerInstance.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Frontend/CompilerInstance.cpp b/lib/Frontend/CompilerInstance.cpp
index c56cc3d9db..92798c8c29 100644
--- a/lib/Frontend/CompilerInstance.cpp
+++ b/lib/Frontend/CompilerInstance.cpp
@@ -228,7 +228,10 @@ void CompilerInstance::createPreprocessor() {
if (!getHeaderSearchOpts().DisableModuleHash)
llvm::sys::path::append(SpecificModuleCache,
getInvocation().getModuleHash());
- PP->getHeaderSearchInfo().setModuleCachePath(SpecificModuleCache);
+ PP->getHeaderSearchInfo().configureModules(SpecificModuleCache,
+ getPreprocessorOpts().ModuleBuildPath.empty()
+ ? std::string()
+ : getPreprocessorOpts().ModuleBuildPath.back());
// Handle generating dependencies, if requested.
const DependencyOutputOptions &DepOpts = getDependencyOutputOpts();