diff options
author | Brad King <brad.king@kitware.com> | 2017-07-13 14:07:32 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2017-07-13 14:07:36 (GMT) |
commit | 489a7706c25b604fa06644ab5044a9f5954b7953 (patch) | |
tree | f4556312acf0ce7a108240655945244e1323a225 /Source/cmLocalGenerator.cxx | |
parent | aa97170f2b25a99d2cc69fd6b2a059e52872f341 (diff) | |
parent | 4bafa3922e3773e5bcc6741994379455c7d1c0fc (diff) | |
download | CMake-489a7706c25b604fa06644ab5044a9f5954b7953.zip CMake-489a7706c25b604fa06644ab5044a9f5954b7953.tar.gz CMake-489a7706c25b604fa06644ab5044a9f5954b7953.tar.bz2 |
Merge topic 'android-system-include-last'
4bafa392 Android: Always add standard include directories last
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1052
Diffstat (limited to 'Source/cmLocalGenerator.cxx')
-rw-r--r-- | Source/cmLocalGenerator.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx index 85ef042..921be3b 100644 --- a/Source/cmLocalGenerator.cxx +++ b/Source/cmLocalGenerator.cxx @@ -960,6 +960,20 @@ void cmLocalGenerator::GetIncludeDirectories(std::vector<std::string>& dirs, } } + // Add standard include directories for this language. + // We do not filter out implicit directories here. + std::string const standardIncludesVar = + "CMAKE_" + lang + "_STANDARD_INCLUDE_DIRECTORIES"; + std::string const standardIncludes = + this->Makefile->GetSafeDefinition(standardIncludesVar); + std::vector<std::string>::size_type const before = includes.size(); + cmSystemTools::ExpandListArgument(standardIncludes, includes); + for (std::vector<std::string>::iterator i = includes.begin() + before; + i != includes.end(); ++i) { + cmSystemTools::ConvertToUnixSlashes(*i); + dirs.push_back(*i); + } + for (std::vector<std::string>::const_iterator i = implicitDirs.begin(); i != implicitDirs.end(); ++i) { if (std::find(includes.begin(), includes.end(), *i) != includes.end()) { |