summaryrefslogtreecommitdiff
path: root/Source/cmBuildNameCommand.cxx
diff options
context:
space:
mode:
authorJim Miller <millerjv@crd.ge.com>2001-07-02 16:30:40 -0400
committerJim Miller <millerjv@crd.ge.com>2001-07-02 16:30:40 -0400
commitc453f2fc7ae665f584124617c080bc8906f6bf06 (patch)
tree66f9aad298e07f0c1303c088cf452b8ee3a88e4e /Source/cmBuildNameCommand.cxx
parent6307ffbb650a16f498cb7ba393b846eef4b92e09 (diff)
downloadcmake-c453f2fc7ae665f584124617c080bc8906f6bf06.tar.gz
FIX: BuildName removes path to compiler and converts any illegal characters
Diffstat (limited to 'Source/cmBuildNameCommand.cxx')
-rw-r--r--Source/cmBuildNameCommand.cxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/Source/cmBuildNameCommand.cxx b/Source/cmBuildNameCommand.cxx
index f5f0658478..91b7edbb0a 100644
--- a/Source/cmBuildNameCommand.cxx
+++ b/Source/cmBuildNameCommand.cxx
@@ -68,18 +68,18 @@ bool cmBuildNameCommand::InitialPass(std::vector<std::string>& args)
if(reg.find(buildname.c_str()))
{
buildname = reg.match(1) + "-" + reg.match(2);
- cmSystemTools::ReplaceString(buildname,
- "/", "_");
- cmSystemTools::ReplaceString(buildname,
- "(", "_");
- cmSystemTools::ReplaceString(buildname,
- ")", "_");
}
}
}
std::string compiler = "-${CMAKE_CXX_COMPILER}";
m_Makefile->ExpandVariablesInString ( compiler );
- buildname += compiler;
+ buildname += cmSystemTools::GetFilenameName(compiler);
+ cmSystemTools::ReplaceString(buildname,
+ "/", "_");
+ cmSystemTools::ReplaceString(buildname,
+ "(", "_");
+ cmSystemTools::ReplaceString(buildname,
+ ")", "_");
cmCacheManager::GetInstance()->
AddCacheEntry("BUILDNAME",