MacroDBusAddActivationService
David Faure
faure at kde.org
Sun Aug 26 16:14:31 UTC 2012
kde-runtime has cmake/modules/MacroDBusAddActivationService.cmake
which says
macro(dbus_add_activation_service _sources)
foreach (_i ${_sources})
get_filename_component(_service_file ${_i} ABSOLUTE)
string(REGEX REPLACE "\\.service.*$" ".service" _output_file ${_i})
set(_target ${CMAKE_CURRENT_BINARY_DIR}/${_output_file})
configure_file(${_service_file} ${_target})
install(FILES ${_target} DESTINATION ${DBUS_SERVICES_INSTALL_DIR} )
endforeach (_i ${ARGN})
endmacro(dbus_add_activation_service _sources)
Typical usage: see kde-runtime/kuiserver:
dbus_add_activation_service(org.kde.kuiserver.service.in)
where that file contains
[D-BUS Service]
Name=org.kde.kuiserver
Exec=@CMAKE_INSTALL_PREFIX@/bin/kuiserver
I would now need this in kdelibs (frameworks branch), in order to generate
org.kde.kded5.service and install it, to allow launching kded5 via dbus auto-
activation.
Can this macro go into ECM? Or even cmake?
It's basically useful for anyone making a dbus service with cmake -- not even
necessarily using Qt.
--
David Faure, faure at kde.org, http://www.davidfaure.fr
Sponsored by Nokia to work on KDE, incl. KDE Frameworks 5
More information about the Kde-buildsystem
mailing list