aboutsummaryrefslogtreecommitdiffstats
path: root/conf/system/CMakeLists.txt
diff options
context:
space:
mode:
authorJosé Bollo <jose.bollo@iot.bzh>2019-05-03 18:43:21 +0200
committerJosé Bollo <jose.bollo@iot.bzh>2019-05-14 10:58:01 +0200
commitcc937529cdf8fad47b9b988fe205406f75d61acd (patch)
tree40e47ef34ab2269aa3602e5d4c3957ec1f617846 /conf/system/CMakeLists.txt
parent2db5d235fe4819c622d22282f5945ef4f13f6372 (diff)
Refactor of system and user setuphalibut_7.99.1halibut/7.99.17.99.1
Since a long time, the creation of the user and system run environment was made by a sub-optimal, hardly maintainable and false-error generating. This change puts the user and system setup in separate shell scripts. This makes them more easy to maintain, update or tune. This facility will useful for further evolution. Bug-AGL: SPEC-1016 Change-Id: Iede81a659eacf4e5c21c561a33d300408e1bd058 Signed-off-by: Jose Bollo <jose.bollo@iot.bzh>
Diffstat (limited to 'conf/system/CMakeLists.txt')
-rw-r--r--conf/system/CMakeLists.txt17
1 files changed, 14 insertions, 3 deletions
diff --git a/conf/system/CMakeLists.txt b/conf/system/CMakeLists.txt
index cdece83..4f77f93 100644
--- a/conf/system/CMakeLists.txt
+++ b/conf/system/CMakeLists.txt
@@ -19,8 +19,12 @@
cmake_minimum_required(VERSION 2.8)
configure_file(afm-system-daemon.service.in afm-system-daemon.service)
-configure_file(afm-system-daemon.socket.in afm-system-daemon.socket)
+configure_file(afm-system-daemon.socket.in afm-system-daemon.socket)
+configure_file(afm-system-setup.service.in afm-system-setup.service)
+configure_file(afm-system-setup.sh.in afm-system-setup.sh)
configure_file(afm-api-afm-main@.service.in afm-api-afm-main@.service)
+configure_file(afm-user-setup@.service.in afm-user-setup@.service)
+configure_file(afm-user-setup.sh.in afm-user-setup.sh)
if(NOT USE_SDK)
set(SYSCONFDIR_DBUS_SYSTEM ${CMAKE_INSTALL_SYSCONFDIR}/dbus-1/system.d CACHE STRING "Path to dbus system configuration files")
@@ -34,12 +38,19 @@ if(NOT USE_SDK)
${CMAKE_CURRENT_BINARY_DIR}/afm-api-afm-main@.service
${CMAKE_CURRENT_BINARY_DIR}/afm-system-daemon.service
${CMAKE_CURRENT_BINARY_DIR}/afm-system-daemon.socket
- ${CMAKE_CURRENT_SOURCE_DIR}/afm-system-setup.service
+ ${CMAKE_CURRENT_BINARY_DIR}/afm-system-setup.service
${CMAKE_CURRENT_SOURCE_DIR}/afm-user-session@.service
${CMAKE_CURRENT_SOURCE_DIR}/afm-user-session@.target
- ${CMAKE_CURRENT_SOURCE_DIR}/afm-user-setup@.service
+ ${CMAKE_CURRENT_BINARY_DIR}/afm-user-setup@.service
DESTINATION
${UNITDIR_SYSTEM}
)
+ install(
+ PROGRAMS
+ ${CMAKE_CURRENT_BINARY_DIR}/afm-user-setup.sh
+ ${CMAKE_CURRENT_BINARY_DIR}/afm-system-setup.sh
+ DESTINATION
+ ${afm_libexecdir}
+ )
endif()