[Cmake-commits] [cmake-commits] king committed cmLocalGenerator.cxx 1.295 1.296 cmLocalGenerator.h 1.111 1.112
cmake-commits at cmake.org
cmake-commits at cmake.org
Thu Feb 26 09:16:19 EST 2009
Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv4054/Source
Modified Files:
cmLocalGenerator.cxx cmLocalGenerator.h
Log Message:
BUG: Use new include dir suppresson for all gens
This fixes CMAKE_<LANG>_IMPLICIT_INCLUDE_DIRECTORIES to be used for all
generators instead of just those that construct their own compiler
command lines directly. See issue #8598.
Index: cmLocalGenerator.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmLocalGenerator.cxx,v
retrieving revision 1.295
retrieving revision 1.296
diff -C 2 -d -r1.295 -r1.296
*** cmLocalGenerator.cxx 26 Feb 2009 13:49:10 -0000 1.295
--- cmLocalGenerator.cxx 26 Feb 2009 14:16:15 -0000 1.296
***************
*** 1188,1210 ****
}
- // Load implicit include directories for this language.
- std::set<cmStdString> impDirs;
- std::string impDirVar = "CMAKE_";
- impDirVar += lang;
- impDirVar += "_IMPLICIT_INCLUDE_DIRECTORIES";
- if(const char* value = this->Makefile->GetDefinition(impDirVar.c_str()))
- {
- std::vector<std::string> impDirVec;
- cmSystemTools::ExpandListArgument(value, impDirVec);
- for(std::vector<std::string>::const_iterator i = impDirVec.begin();
- i != impDirVec.end(); ++i)
- {
- impDirs.insert(*i);
- }
- }
-
cmOStringStream includeFlags;
std::vector<std::string> includes;
! this->GetIncludeDirectories(includes);
std::vector<std::string>::iterator i;
--- 1188,1194 ----
}
cmOStringStream includeFlags;
std::vector<std::string> includes;
! this->GetIncludeDirectories(includes, lang);
std::vector<std::string>::iterator i;
***************
*** 1251,1259 ****
for(i = includes.begin(); i != includes.end(); ++i)
{
- // Skip implicit include directories.
- if(impDirs.find(*i) != impDirs.end())
- {
- continue;
- }
#ifdef __APPLE__
if(cmSystemTools::IsPathToFramework(i->c_str()))
--- 1235,1238 ----
***************
*** 1316,1320 ****
//----------------------------------------------------------------------------
! void cmLocalGenerator::GetIncludeDirectories(std::vector<std::string>& dirs)
{
// Need to decide whether to automatically include the source and
--- 1295,1300 ----
//----------------------------------------------------------------------------
! void cmLocalGenerator::GetIncludeDirectories(std::vector<std::string>& dirs,
! const char* lang)
{
// Need to decide whether to automatically include the source and
***************
*** 1382,1385 ****
--- 1362,1380 ----
}
+ // Load implicit include directories for this language.
+ std::string impDirVar = "CMAKE_";
+ impDirVar += lang;
+ impDirVar += "_IMPLICIT_INCLUDE_DIRECTORIES";
+ if(const char* value = this->Makefile->GetDefinition(impDirVar.c_str()))
+ {
+ std::vector<std::string> impDirVec;
+ cmSystemTools::ExpandListArgument(value, impDirVec);
+ for(std::vector<std::string>::const_iterator i = impDirVec.begin();
+ i != impDirVec.end(); ++i)
+ {
+ emitted.insert(*i);
+ }
+ }
+
// Get the project-specified include directories.
std::vector<std::string>& includes =
Index: cmLocalGenerator.h
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmLocalGenerator.h,v
retrieving revision 1.111
retrieving revision 1.112
diff -C 2 -d -r1.111 -r1.112
*** cmLocalGenerator.h 24 Feb 2009 20:37:09 -0000 1.111
--- cmLocalGenerator.h 26 Feb 2009 14:16:16 -0000 1.112
***************
*** 190,194 ****
/** Get the include flags for the current makefile and language. */
! void GetIncludeDirectories(std::vector<std::string>& dirs);
/** Compute the language used to compile the given source file. */
--- 190,195 ----
/** Get the include flags for the current makefile and language. */
! void GetIncludeDirectories(std::vector<std::string>& dirs,
! const char* lang = "C");
/** Compute the language used to compile the given source file. */
More information about the Cmake-commits
mailing list