summaryrefslogtreecommitdiffstats
path: root/Source/CPack/cmCPackCygwinBinaryGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/CPack/cmCPackCygwinBinaryGenerator.cxx')
-rw-r--r--Source/CPack/cmCPackCygwinBinaryGenerator.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/Source/CPack/cmCPackCygwinBinaryGenerator.cxx b/Source/CPack/cmCPackCygwinBinaryGenerator.cxx
index e8e1f7f..f6f51be 100644
--- a/Source/CPack/cmCPackCygwinBinaryGenerator.cxx
+++ b/Source/CPack/cmCPackCygwinBinaryGenerator.cxx
@@ -98,7 +98,15 @@ int cmCPackCygwinBinaryGenerator::CompressFiles(const char* outFileName,
const char* cmCPackCygwinBinaryGenerator::GetOutputExtension()
{
this->OutputExtension = "-";
- this->OutputExtension += this->GetOption("CPACK_CYGWIN_PATCH_NUMBER");
+ const char* patchNumber =this->GetOption("CPACK_CYGWIN_PATCH_NUMBER");
+ if(!patchNumber)
+ {
+ patchNumber = "1";
+ cmCPackLogger(cmCPackLog::LOG_WARNING,
+ "CPACK_CYGWIN_PATCH_NUMBER not specified using 1"
+ << std::endl);
+ }
+ this->OutputExtension +=
this->OutputExtension += ".tar.bz2";
return this->OutputExtension.c_str();
}