CPack fix CPackDeb crash when CPackDeb.cmake ends with a FATAL_ERROR
This commit is contained in:
parent
96453cea6a
commit
21007f8989
|
@ -96,6 +96,7 @@ int cmCPackDebGenerator::PackageComponents(bool ignoreGroup)
|
|||
cmCPackLogger(cmCPackLog::LOG_ERROR,
|
||||
"Error while execution CPackDeb.cmake" << std::endl);
|
||||
retval = 0;
|
||||
return retval;
|
||||
}
|
||||
|
||||
cmsys::Glob gl;
|
||||
|
@ -152,8 +153,8 @@ int cmCPackDebGenerator::PackageComponents(bool ignoreGroup)
|
|||
cmCPackLogger(cmCPackLog::LOG_ERROR,
|
||||
"Error while execution CPackDeb.cmake" << std::endl);
|
||||
retval = 0;
|
||||
return retval;
|
||||
}
|
||||
|
||||
cmsys::Glob gl;
|
||||
std::string findExpr(this->GetOption("WDIR"));
|
||||
findExpr += "/*";
|
||||
|
@ -230,6 +231,7 @@ int cmCPackDebGenerator::PackageComponentsAllInOne(bool allComponent)
|
|||
cmCPackLogger(cmCPackLog::LOG_ERROR,
|
||||
"Error while execution CPackDeb.cmake" << std::endl);
|
||||
retval = 0;
|
||||
return retval;
|
||||
}
|
||||
|
||||
cmsys::Glob gl;
|
||||
|
@ -288,9 +290,12 @@ int cmCPackDebGenerator::PackageFiles()
|
|||
"Error while execution CPackDeb.cmake" << std::endl);
|
||||
retval = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
packageFiles = files;
|
||||
return createDeb();
|
||||
}
|
||||
}
|
||||
return retval;
|
||||
}
|
||||
|
||||
|
|
|
@ -885,8 +885,12 @@ int cmCPackGenerator::InstallProjectViaInstallCMakeProjects(
|
|||
//----------------------------------------------------------------------
|
||||
bool cmCPackGenerator::ReadListFile(const char* moduleName)
|
||||
{
|
||||
bool retval;
|
||||
std::string fullPath = this->MakefileMap->GetModulesFile(moduleName);
|
||||
return this->MakefileMap->ReadListFile(0, fullPath.c_str());
|
||||
retval = this->MakefileMap->ReadListFile(0, fullPath.c_str());
|
||||
// include FATAL_ERROR and ERROR in the return status
|
||||
retval = retval && (! cmSystemTools::GetErrorOccuredFlag());
|
||||
return retval;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
|
Loading…
Reference in New Issue