MCPcopy Create free account
hub / github.com/Kitware/CMake / InitializeInternal

Method InitializeInternal

Source/CPack/cmCPackAppImageGenerator.cxx:29–62  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27cmCPackAppImageGenerator::~cmCPackAppImageGenerator() = default;
28
29int cmCPackAppImageGenerator::InitializeInternal()
30{
31 this->SetOptionIfNotSet("CPACK_APPIMAGE_TOOL_EXECUTABLE", "appimagetool");
32 this->AppimagetoolPath = cmSystemTools::FindProgram(
33 *this->GetOption("CPACK_APPIMAGE_TOOL_EXECUTABLE"));
34
35 if (this->AppimagetoolPath.empty()) {
36 cmCPackLogger(
37 cmCPackLog::LOG_ERROR,
38 "Cannot find AppImageTool: '"
39 << *this->GetOption("CPACK_APPIMAGE_TOOL_EXECUTABLE")
40 << "' check if it's installed, is executable, or is in your PATH"
41 << std::endl);
42
43 return 0;
44 }
45
46 this->SetOptionIfNotSet("CPACK_APPIMAGE_PATCHELF_EXECUTABLE", "patchelf");
47 this->PatchElfPath = cmSystemTools::FindProgram(
48 *this->GetOption("CPACK_APPIMAGE_PATCHELF_EXECUTABLE"));
49
50 if (this->PatchElfPath.empty()) {
51 cmCPackLogger(
52 cmCPackLog::LOG_ERROR,
53 "Cannot find patchelf: '"
54 << *this->GetOption("CPACK_APPIMAGE_PATCHELF_EXECUTABLE")
55 << "' check if it's installed, is executable, or is in your PATH"
56 << std::endl);
57
58 return 0;
59 }
60
61 return Superclass::InitializeInternal();
62}
63
64int cmCPackAppImageGenerator::PackageFiles()
65{

Callers

nothing calls this directly

Calls 3

SetOptionIfNotSetMethod · 0.45
GetOptionMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected