<div dir="ltr">Hey guys,<div><br></div><div>I am creating a RPM package with CMake. Here is a small example of how it looks:</div><div><br></div><div>========</div><div><br></div><div><div>cmake_minimum_required(VERSION 3.5)</div><div><br></div><div>set(BOOST_LIB "${CMAKE_CURRENT_SOURCE_DIR}/boost")</div><div><br></div><div>file(GLOB_RECURSE BOOST_LIBRARIES ${BOOST_LIB}/*)</div><div><br></div><div>install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/usr/bin/executable DESTINATION bin)</div><div>install(FILES ${BOOST_LIBRARIES} DESTINATION lib)</div><div><br></div><div>set(CPACK_GENERATOR "RPM")</div><div>set(CPACK_PACKAGE_VERSION 6.5)</div><div>set(CPACK_PACKAGE_NAME "executable-proj")</div><div># set(CPACK_RPM_PACKAGE_NAME "executable-proj")</div><div>set(CPACK_RPM_PACKAGE_SUMMARY "Simple executable project")</div><div>set(CPACK_RPM_PACKAGE_ARCHITECTURE x86_64)</div><div>set(CPACK_PACKAGE_VENDOR "Some Vendor Limited")</div><div>set(CPACK_RPM_PACKAGE_MAINTAINER "Some Vendor Limited")</div><div>set(CPACK_RPM_PACKAGE_AUTOREQ "NO")</div><div>set(CPACK_PACKAGE_EXECUTABLES "executable")</div><div><br></div><div>INCLUDE(CPack)</div></div><div><br></div><div>======</div><div><br></div><div>Before running this cmake script, I am setting executable permissions on the build machine, where the package is created.</div><div><br></div><div>Then, I create a docker image, where this RPM is downloaded and installed. But when I want to start the executable within a docker container, then I am getting the message "permission denied". </div><div>When I look at the permissions of my installed package, then I see, I only have read permissions.</div><div><br></div><div>So the question is: What can I do for getting executable permissions for this executable? Is this a CMake/CPack problem?</div></div>