|
@@ -19,14 +19,14 @@ if(INIT_FLAVOR AND NOT EXISTS "$ENV{DESTDIR}${CONFIG_DIR}/@PROJECT_NAME@")
|
19
|
19
|
endif()
|
20
|
20
|
|
21
|
21
|
if(INIT_FLAVOR STREQUAL "sysv-lsb")
|
22
|
|
- file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/@PROJECT_NAME@.lsb_init" TYPE PROGRAM DESTINATION "${SYSCONF_DIR}/init.d" RENAME "@PROJECT_NAME@")
|
|
22
|
+ file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/@PROJECT_NAME@.sysv-lsb" TYPE PROGRAM DESTINATION "${SYSCONF_DIR}/init.d" RENAME "@PROJECT_NAME@")
|
23
|
23
|
if(INSSERV)
|
24
|
24
|
execute_process(
|
25
|
25
|
COMMAND ${INSSERV} -p "$ENV{DESTDIR}${SYSCONF_DIR}/init.d" @PROJECT_NAME@
|
26
|
26
|
)
|
27
|
27
|
endif()
|
28
|
28
|
elseif(INIT_FLAVOR STREQUAL "sysv-redhat")
|
29
|
|
- file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/@PROJECT_NAME@.rh_init" TYPE PROGRAM DESTINATION "${SYSCONF_DIR}/init.d" RENAME "@PROJECT_NAME@")
|
|
29
|
+ file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/@PROJECT_NAME@.sysv-redhat" TYPE PROGRAM DESTINATION "${SYSCONF_DIR}/init.d" RENAME "@PROJECT_NAME@")
|
30
|
30
|
if(CHKCONFIG AND NOT "$ENV{DESTDIR}")
|
31
|
31
|
execute_process(
|
32
|
32
|
COMMAND ${CHKCONFIG} --add @PROJECT_NAME@
|
|
@@ -35,7 +35,7 @@ elseif(INIT_FLAVOR STREQUAL "sysv-redhat")
|
35
|
35
|
elseif(INIT_FLAVOR STREQUAL "upstart")
|
36
|
36
|
file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/@PROJECT_NAME@.upstart" DESTINATION "${SYSCONF_DIR}/init" RENAME "@PROJECT_NAME@.conf")
|
37
|
37
|
elseif(INIT_FLAVOR STREQUAL "systemd")
|
38
|
|
- file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/@PROJECT_NAME@.service" DESTINATION "${SYSCONF_DIR}/systemd/system" RENAME "@PROJECT_NAME@.service")
|
|
38
|
+ file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/@PROJECT_NAME@.systemd" DESTINATION "${SYSCONF_DIR}/systemd/system" RENAME "@PROJECT_NAME@.service")
|
39
|
39
|
endif()
|
40
|
40
|
|
41
|
41
|
if(GENERATE_SRS_SECRET AND DD AND BASE64 AND EXISTS "/dev/urandom" AND NOT EXISTS "$ENV{DESTDIR}${SYSCONF_DIR}/${SECRET_FILE}")
|
|
@@ -50,3 +50,4 @@ if(GENERATE_SRS_SECRET AND DD AND BASE64 AND EXISTS "/dev/urandom" AND NOT EXIST
|
50
|
50
|
file(INSTALL FILES "@CMAKE_CURRENT_BINARY_DIR@/${SECRET_FILE}" DESTINATION "${SYSCONF_DIR}" RENAME "${SECRET_FILE}" PERMISSIONS OWNER_READ OWNER_WRITE)
|
51
|
51
|
file(REMOVE "@CMAKE_CURRENT_BINARY_DIR@/${SECRET_FILE}")
|
52
|
52
|
endif()
|
|
53
|
+
|