Here is the setup I tried using CMake 2.8.2 to reproduce the problem:
/test.sh:
/CMakeLists.txt:
cmake_minimum_required(VERSION 2.8)
SET(CPACK_PACKAGE_NAME test)
SET(CPACK_PACKAGE_VERSION 1.0)
LIST(APPEND CPACK_GENERATOR RPM)
SET(CPACK_RPM_POST_INSTALL_SCRIPT_FILE "test.sh")
INCLUDE(CPack)
then:
mkdir build && cd build && cmake .. && make package
Results:
CPackRPM:Warning: CPACK_RPM_POST_INSTALL_SCRIPT_FILE does not exists - ignoring
How to make the build system aware of my file test.sh ?