summaryrefslogtreecommitdiffstats
path: root/host/cmake/Modules/UHDPackage.cmake
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2011-10-14 12:12:55 -0700
committerJosh Blum <josh@joshknows.com>2011-10-14 12:12:55 -0700
commit1eefd6f232241efcf678657dd638874c0f444c6f (patch)
tree861ffc8852d835d34ec03d7b8d66978e75628226 /host/cmake/Modules/UHDPackage.cmake
parentf817f6f1db02d8a0cd6698510a2094ebce3bd171 (diff)
downloaduhd-1eefd6f232241efcf678657dd638874c0f444c6f.tar.gz
uhd-1eefd6f232241efcf678657dd638874c0f444c6f.tar.bz2
uhd-1eefd6f232241efcf678657dd638874c0f444c6f.zip
uhd: added post/pre un/install scripts for deb and rpm packagesrelease_003_003_000
Diffstat (limited to 'host/cmake/Modules/UHDPackage.cmake')
-rw-r--r--host/cmake/Modules/UHDPackage.cmake20
1 files changed, 19 insertions, 1 deletions
diff --git a/host/cmake/Modules/UHDPackage.cmake b/host/cmake/Modules/UHDPackage.cmake
index 3c6ae14f2..27a43b56e 100644
--- a/host/cmake/Modules/UHDPackage.cmake
+++ b/host/cmake/Modules/UHDPackage.cmake
@@ -82,7 +82,7 @@ ENDIF()
########################################################################
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Ettus Research - USRP Hardware Driver")
SET(CPACK_PACKAGE_VENDOR "Ettus Research LLC")
-SET(CPACK_PACKAGE_CONTACT "support@ettus.com")
+SET(CPACK_PACKAGE_CONTACT "Ettus Research <support@ettus.com>")
SET(CPACK_PACKAGE_VERSION_MAJOR ${UHD_VERSION_MAJOR})
SET(CPACK_PACKAGE_VERSION_MINOR ${UHD_VERSION_MINOR})
SET(CPACK_PACKAGE_VERSION_PATCH ${UHD_VERSION_PATCH})
@@ -135,12 +135,30 @@ SET(CPACK_COMPONENTS_ALL libraries headers utilities examples tests manual doxyg
########################################################################
SET(CPACK_DEBIAN_PACKAGE_DEPENDS "libusb-1.0-0, libboost-dev")
SET(CPACK_DEBIAN_PACKAGE_RECOMMENDS "python, python-tk")
+FOREACH(filename preinst postinst prerm postrm)
+ LIST(APPEND CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA ${CMAKE_BINARY_DIR}/debian/${filename})
+ FILE(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/debian)
+ CONFIGURE_FILE(
+ ${CMAKE_SOURCE_DIR}/cmake/debian/${filename}.in
+ ${CMAKE_BINARY_DIR}/debian/${filename}
+ @ONLY)
+ENDFOREACH(filename)
########################################################################
# Setup CPack RPM
########################################################################
SET(CPACK_RPM_PACKAGE_REQUIRES "boost-devel, libusb1")
+FOREACH(filename post_install post_uninstall pre_install pre_uninstall)
+ STRING(TOUPPER ${filename} filename_upper)
+ LIST(APPEND CPACK_RPM_${filename_upper}_SCRIPT_FILE ${CMAKE_BINARY_DIR}/redhat/${filename})
+ FILE(MAKE_DIRECTORY ${CMAKE_BINARY_DIR}/redhat)
+ CONFIGURE_FILE(
+ ${CMAKE_SOURCE_DIR}/cmake/redhat/${filename}.in
+ ${CMAKE_BINARY_DIR}/redhat/${filename}
+ @ONLY)
+ENDFOREACH(filename)
+
########################################################################
# Setup CPack NSIS
########################################################################