From cf7893b9340a7db1af5bb451709ff4555bea3475 Mon Sep 17 00:00:00 2001 From: Ken Martin Date: Thu, 16 Sep 2004 10:48:10 -0400 Subject: [PATCH] BUG: fix VSExternal for visual studio 6 --- Source/cmGlobalVisualStudio6Generator.cxx | 12 +++++++++--- Tests/VSExternalInclude/CMakeLists.txt | 2 +- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/Source/cmGlobalVisualStudio6Generator.cxx b/Source/cmGlobalVisualStudio6Generator.cxx index afceb6b24..8a017e131 100644 --- a/Source/cmGlobalVisualStudio6Generator.cxx +++ b/Source/cmGlobalVisualStudio6Generator.cxx @@ -477,9 +477,9 @@ void cmGlobalVisualStudio6Generator::WriteProject(std::ostream& fout, const char* cacheValue = m_CMakeInstance->GetCacheDefinition(libPath.c_str()); if(cacheValue && *cacheValue) - { + { fout << "Begin Project Dependency\n"; - fout << "Project_Dep_Name " << j->first << "\n"; + fout << "Project_Dep_Name " << j->first.c_str() << "\n"; fout << "End Project Dependency\n"; } } @@ -494,8 +494,14 @@ void cmGlobalVisualStudio6Generator::WriteProject(std::ostream& fout, { if(*i != dspname) { + std::string depName = *i; + if(strncmp(depName.c_str(), "INCLUDE_EXTERNAL_MSPROJECT", 26) == 0) + { + depName.erase(depName.begin(), depName.begin() + 27); + } + fout << "Begin Project Dependency\n"; - fout << "Project_Dep_Name " << *i << "\n"; + fout << "Project_Dep_Name " << depName << "\n"; fout << "End Project Dependency\n"; } } diff --git a/Tests/VSExternalInclude/CMakeLists.txt b/Tests/VSExternalInclude/CMakeLists.txt index e161fbee5..841df4f9e 100644 --- a/Tests/VSExternalInclude/CMakeLists.txt +++ b/Tests/VSExternalInclude/CMakeLists.txt @@ -1,7 +1,7 @@ PROJECT(VSExternalInclude) IF(${CMAKE_GENERATOR} MATCHES "Visual Studio 6") - SET(PROJECT_EXT dps) + SET(PROJECT_EXT dsp) ELSE(${CMAKE_GENERATOR} MATCHES "Visual Studio 6") SET(PROJECT_EXT vcproj) ENDIF(${CMAKE_GENERATOR} MATCHES "Visual Studio 6")