summaryrefslogtreecommitdiffstats
path: root/Source/cmCableDefineSetCommand.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2001-03-16 14:25:18 (GMT)
committerBrad King <brad.king@kitware.com>2001-03-16 14:25:18 (GMT)
commitdf8a7ecafdd8a52b816a22df374744e9667e34c5 (patch)
treef40955f90f2091edc98c5b8c594581e18caf5d78 /Source/cmCableDefineSetCommand.cxx
parentbe4db9150c6b3bd8a6c39d48fa693a6209c34740 (diff)
downloadCMake-df8a7ecafdd8a52b816a22df374744e9667e34c5.zip
CMake-df8a7ecafdd8a52b816a22df374744e9667e34c5.tar.gz
CMake-df8a7ecafdd8a52b816a22df374744e9667e34c5.tar.bz2
ENH: Changed generated includes to not have full path specified.
Diffstat (limited to 'Source/cmCableDefineSetCommand.cxx')
-rw-r--r--Source/cmCableDefineSetCommand.cxx16
1 files changed, 7 insertions, 9 deletions
diff --git a/Source/cmCableDefineSetCommand.cxx b/Source/cmCableDefineSetCommand.cxx
index a22c9e0..e682bc4 100644
--- a/Source/cmCableDefineSetCommand.cxx
+++ b/Source/cmCableDefineSetCommand.cxx
@@ -253,16 +253,16 @@ bool cmCableDefineSetCommand::AddSourceFile(const std::string& file)
// We must locate the file in the include path so that we can detect
// its extension, and whether there is more than one to find.
std::string header = file+".h";
+ std::string txx = file+".txx";
m_Makefile->ExpandVariablesInString(header);
-
+ m_Makefile->ExpandVariablesInString(txx);
+
// See if the file just exists here. The compiler's search path will
// locate it.
if(cmSystemTools::FileExists(header.c_str()))
{
m_SourceHeaders.push_back(header);
// See if there is a matching .txx as well.
- std::string txx = file+".txx";
- m_Makefile->ExpandVariablesInString(txx);
if(cmSystemTools::FileExists(txx.c_str()))
{
m_InstantiationSources.push_back(txx);
@@ -277,15 +277,13 @@ bool cmCableDefineSetCommand::AddSourceFile(const std::string& file)
for(std::vector<std::string>::const_iterator dir = includeDirectories.begin();
dir != includeDirectories.end(); ++dir)
{
- std::string path = *dir + "/" + header;
+ std::string path = *dir + "/";
m_Makefile->ExpandVariablesInString(path);
- if(cmSystemTools::FileExists(path.c_str()))
+ if(cmSystemTools::FileExists((path+header).c_str()))
{
- m_SourceHeaders.push_back(path);
+ m_SourceHeaders.push_back(header);
// See if there is a matching .txx as well.
- std::string txx = *dir + "/" + file + ".txx";
- m_Makefile->ExpandVariablesInString(txx);
- if(cmSystemTools::FileExists(txx.c_str()))
+ if(cmSystemTools::FileExists((path+txx).c_str()))
{
m_InstantiationSources.push_back(txx);
}