diff options
Diffstat (limited to 'Source/CPack')
-rw-r--r-- | Source/CPack/cmCPackGenericGenerator.cxx | 10 | ||||
-rw-r--r-- | Source/CPack/cpack.cxx | 6 |
2 files changed, 11 insertions, 5 deletions
diff --git a/Source/CPack/cmCPackGenericGenerator.cxx b/Source/CPack/cmCPackGenericGenerator.cxx index 64b283c..1987a4d 100644 --- a/Source/CPack/cmCPackGenericGenerator.cxx +++ b/Source/CPack/cmCPackGenericGenerator.cxx @@ -653,7 +653,7 @@ int cmCPackGenericGenerator::ProcessGenerator() tempDirectory = this->GetOption("CPACK_TOPLEVEL_DIRECTORY"); } if ( !this->CompressFiles(tempPackageFileName, - tempDirectory, gl.GetFiles()) ) + tempDirectory, gl.GetFiles()) || cmSystemTools::GetErrorOccuredFlag()) { cmCPackLogger(cmCPackLog::LOG_ERROR, "Problem compressing the directory" << std::endl); @@ -695,7 +695,13 @@ int cmCPackGenericGenerator::Initialize(const char* name, cmMakefile* mf, "Cannot initialize the generator" << std::endl); return 0; } - return this->InitializeInternal(); + int result = this->InitializeInternal(); + if (cmSystemTools::GetErrorOccuredFlag()) + { + return 0; + } + + return result; } //---------------------------------------------------------------------- diff --git a/Source/CPack/cpack.cxx b/Source/CPack/cpack.cxx index 67b9a05..ba9820f 100644 --- a/Source/CPack/cpack.cxx +++ b/Source/CPack/cpack.cxx @@ -377,13 +377,13 @@ int main (int argc, char *argv[]) { cmCPack_Log(&log, cmCPackLog::LOG_ERROR, "Cannot initialize CPack generator: " - << generator.c_str() << std::endl); + << gen << std::endl); parsed = 0; } if ( parsed && !cpackGenerator->Initialize(gen, mf, argv[0]) ) { cmCPack_Log(&log, cmCPackLog::LOG_ERROR, - "Cannot initialize the generator" << std::endl); + "Cannot initialize the generator " << gen << std::endl); parsed = 0; } @@ -442,7 +442,7 @@ int main (int argc, char *argv[]) } } - if ( !parsed || help ) + if ( help ) { doc.CheckOptions(argc, argv); // Construct and print requested documentation. |