summaryrefslogtreecommitdiff
path: root/grc
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2020-01-06 14:13:23 -0800
committerMichael Dickens <michael.dickens@ettus.com>2020-01-06 20:31:01 -0500
commit25a2e1b64f4770b19234687589bbed32d558a71b (patch)
treeaf52d1477de10761c848e5e76aa9865052bc3aaf /grc
parent7cf3c45890953ad6943bb1fdede4c55f564468d6 (diff)
cmake: grc: Provide ENABLE_POSTINSTALL option
This option allows disabling post-install tasks. Currently, there is one such task: The execution of `grc_setup_freedesktop install`. For developers building from source, this is very convenient to do during installation. However, for package maintainers, this is not desired and should be executed separately. Maintainers of packages can thus provide ENABLE_POSTINSTALL=OFF to avoid permission errors. This continues bc0592b6, which defaulted to always running the script.
Diffstat (limited to 'grc')
-rw-r--r--grc/scripts/freedesktop/CMakeLists.txt6
1 files changed, 4 insertions, 2 deletions
diff --git a/grc/scripts/freedesktop/CMakeLists.txt b/grc/scripts/freedesktop/CMakeLists.txt
index 721c96bfb7..f9511071e5 100644
--- a/grc/scripts/freedesktop/CMakeLists.txt
+++ b/grc/scripts/freedesktop/CMakeLists.txt
@@ -61,7 +61,9 @@ if(UNIX AND HAVE_XDG_UTILS)
DESTINATION ${GR_PKG_LIBEXEC_DIR}
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
)
- install (
- CODE "execute_process(COMMAND ${CMAKE_INSTALL_PREFIX}/${GR_PKG_LIBEXEC_DIR}/grc_setup_freedesktop install)"
+ if(ENABLE_POSTINSTALL)
+ install (
+ CODE "execute_process(COMMAND ${CMAKE_INSTALL_PREFIX}/${GR_PKG_LIBEXEC_DIR}/grc_setup_freedesktop install)"
)
+ endif(ENABLE_POSTINSTALL)
endif(UNIX AND HAVE_XDG_UTILS)