summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/cmLocalVisualStudio7Generator.cxx16
-rw-r--r--Source/cmTarget.cxx11
-rw-r--r--Source/cmTarget.h3
3 files changed, 16 insertions, 14 deletions
diff --git a/Source/cmLocalVisualStudio7Generator.cxx b/Source/cmLocalVisualStudio7Generator.cxx
index da579db..f59f3da 100644
--- a/Source/cmLocalVisualStudio7Generator.cxx
+++ b/Source/cmLocalVisualStudio7Generator.cxx
@@ -638,29 +638,17 @@ void cmLocalVisualStudio7Generator::WriteConfiguration(std::ostream& fout,
{
if(target.GetType() == cmTarget::EXECUTABLE)
{
- std::string targetName;
- std::string targetNameFull;
- std::string targetNamePDB;
- target.GetExecutableNames(targetName, targetNameFull,
- targetNamePDB, configName);
fout << "\t\t\t\tProgramDataBaseFileName=\""
<< this->ExecutableOutputPath
- << "$(OutDir)/" << targetNamePDB << "\"\n";
+ << "$(OutDir)/" << target.GetPDBName(configName) << "\"\n";
}
else if(target.GetType() == cmTarget::STATIC_LIBRARY ||
target.GetType() == cmTarget::SHARED_LIBRARY ||
target.GetType() == cmTarget::MODULE_LIBRARY)
{
- std::string targetName;
- std::string targetNameSO;
- std::string targetNameFull;
- std::string targetNameImport;
- std::string targetNamePDB;
- target.GetLibraryNames(targetName, targetNameSO, targetNameFull,
- targetNameImport, targetNamePDB, configName);
fout << "\t\t\t\tProgramDataBaseFileName=\""
<< this->LibraryOutputPath
- << "$(OutDir)/" << targetNamePDB << "\"\n";
+ << "$(OutDir)/" << target.GetPDBName(configName) << "\"\n";
}
}
fout << "/>\n"; // end of <Tool Name=VCCLCompilerTool
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 1b5138b..5e2001a 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -1376,6 +1376,17 @@ const char* cmTarget::GetPrefixVariableInternal(TargetType type,
}
//----------------------------------------------------------------------------
+std::string cmTarget::GetPDBName(const char* config)
+{
+ std::string prefix;
+ std::string base;
+ std::string suffix;
+ this->GetFullNameInternal(this->GetType(), config, false,
+ prefix, base, suffix);
+ return prefix+base+".pdb";
+}
+
+//----------------------------------------------------------------------------
std::string cmTarget::GetFullName(const char* config, bool implib)
{
return this->GetFullNameInternal(this->GetType(), config, implib);
diff --git a/Source/cmTarget.h b/Source/cmTarget.h
index afe2862..3e7d838 100644
--- a/Source/cmTarget.h
+++ b/Source/cmTarget.h
@@ -205,6 +205,9 @@ public:
void GetFullName(std::string& prefix,
std::string& base, std::string& suffix,
const char* config=0, bool implib = false);
+
+ /** Get the name of the pdb file for the target. */
+ std::string GetPDBName(const char* config=0);
/** Get the full path to the target according to the settings in its
makefile and the configuration type. */