Support installing to /usr or another location requiring sudo access
My preferred workflow when developing in a KDE Neon VM is to overwrite the system packages and install everything to
/usr. I currently use raw CMake and make for this, but I would like to switch to
kdesrc-build. However I cannot, because it will fail to install to
cat ~/kde/src/log/2019-03-17-02/kiconthemes/install.log # kdesrc-build running: 'make' 'install/fast' # from directory: /home/dev/kde/build/kiconthemes Install the project... -- Install configuration: "RelWithDebInfo" -- Installing: /usr/lib/x86_64-linux-gnu/cmake/KF5IconThemes/KF5IconThemesConfig.cmake CMake Error at cmake_install.cmake:41 (file): file INSTALL cannot copy file "/home/dev/kde/build/kiconthemes/KF5IconThemesConfig.cmake" to "/usr/lib/x86_64-linux-gnu/cmake/KF5IconThemes/KF5IconThemesConfig.cmake". Makefile:79: recipe for target 'install/fast' failed make: *** [install/fast] Error 1
It would be nice if it could run this with sudo in such a circumstance, since then the user could be prompted or could even set up passwordless sudo so the install step can be completed with no further user input required.