summaryrefslogtreecommitdiffstats
path: root/Source/cmVisualStudio10TargetGenerator.cxx
diff options
context:
space:
mode:
authorMark Ingram <mingram@serif.com>2018-05-04 10:17:56 (GMT)
committerMark Ingram <mingram@serif.com>2018-05-04 17:10:10 (GMT)
commit5cc195f1f4a7630b7ee54dfe9c2761cb5ee2a8e0 (patch)
treeb4dc5aa9e110266104e113ff52a7e6f92fe35ddd /Source/cmVisualStudio10TargetGenerator.cxx
parente628d6cd066774e4c95ec368fc6ef0be731ff0a5 (diff)
downloadCMake-5cc195f1f4a7630b7ee54dfe9c2761cb5ee2a8e0.zip
CMake-5cc195f1f4a7630b7ee54dfe9c2761cb5ee2a8e0.tar.gz
CMake-5cc195f1f4a7630b7ee54dfe9c2761cb5ee2a8e0.tar.bz2
VS Generator: Only include default certificate if it was actually copied
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r--Source/cmVisualStudio10TargetGenerator.cxx12
1 files changed, 8 insertions, 4 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx
index 7a7c647..2e8a2eb 100644
--- a/Source/cmVisualStudio10TargetGenerator.cxx
+++ b/Source/cmVisualStudio10TargetGenerator.cxx
@@ -3964,6 +3964,7 @@ void cmVisualStudio10TargetGenerator::WriteWinRTPackageCertificateKeyFile(
pfxFile, false);
ConvertToWindowsSlash(pfxFile);
this->AddedFiles.push_back(pfxFile);
+ this->AddedDefaultCertificate = true;
}
e1.Element("PackageCertificateKeyFile", pfxFile);
@@ -4530,10 +4531,13 @@ void cmVisualStudio10TargetGenerator::WriteCommonMissingFiles(
Elem(e1, "Image").Attribute("Include", splashScreen).EndElement();
this->AddedFiles.push_back(splashScreen);
- // This file has already been added to the build so don't copy it
- std::string keyFile = this->DefaultArtifactDir + "/Windows_TemporaryKey.pfx";
- ConvertToWindowsSlash(keyFile);
- Elem(e1, "None").Attribute("Include", keyFile).EndElement();
+ if (this->AddedDefaultCertificate) {
+ // This file has already been added to the build so don't copy it
+ std::string keyFile =
+ this->DefaultArtifactDir + "/Windows_TemporaryKey.pfx";
+ ConvertToWindowsSlash(keyFile);
+ Elem(e1, "None").Attribute("Include", keyFile).EndElement();
+ }
}
bool cmVisualStudio10TargetGenerator::ForceOld(const std::string& source) const