Version: unspecified (using KDE 1.2) OS: Linux After running cmake in a fresh build environment, the CMAKE_INSTALL_PREFIX is set to /usr but when running 'make install' things get installed in /usr/local. Reproducible: Always Steps to Reproduce: Create an empty build sub-directory. cd into this directory. Run 'cmake ..'. No need to actually compile anything. Actual Results: The setting is correct, but generated files don't contain it. thb@localhost:~/tmp/kmymoney-4.5.2/build> grep INSTALL_PREFIX CMakeCache.txt CMAKE_INSTALL_PREFIX:PATH=/usr thb@localhost:~/tmp/kmymoney-4.5.2/build> grep "INSTALL DESTINATION" kmymoney/cmake_install.cmake | head -n 1 FILE(INSTALL DESTINATION "/usr/local/bin" TYPE EXECUTABLE FILES "/home/thb/tmp/kmymoney-4.5.2/build/kmymoney/CMakeFiles/CMakeRelink.dir/kmymoney") Expected Results: thb@localhost:~/tmp/kmymoney-4.5.2/build> grep INSTALL_PREFIX CMakeCache.txt CMAKE_INSTALL_PREFIX:PATH=/usr thb@localhost:~/tmp/kmymoney-4.5.2/build> grep "INSTALL DESTINATION" kmymoney/cmake_install.cmake | head -n 1 FILE(INSTALL DESTINATION "/usr/bin" TYPE EXECUTABLE FILES "/home/thb/tmp/kmymoney-4.5.2/build/kmymoney/CMakeFiles/CMakeRelink.dir/kmymoney") Removing all 'cmake_install.cmake' with 'find . -name cmake_install.cmake | xargs rm' after running 'cmake ..' the first time and re-running 'cmake ..' solves the problem.
SVN commit 1209041 by tbaumgart: setup default CMAKE_INSTALL_PREFIX before calling FIND_PACKAGE(KDE4) BUG: 261132 M +9 -5 CMakeLists.txt WebSVN link: http://websvn.kde.org/?view=rev&revision=1209041
SVN commit 1209043 by tbaumgart: setup default CMAKE_INSTALL_PREFIX before calling FIND_PACKAGE(KDE4) Backported to stable branch BUG: 261132 M +9 -5 CMakeLists.txt WebSVN link: http://websvn.kde.org/?view=rev&revision=1209043