1 PKG_CHECK_MODULES(KEY_MANAGER_DEP
12 SET(KEY_MANAGER_SRC_PATH ${PROJECT_SOURCE_DIR}/src)
13 SET(KEY_MANAGER_PATH ${PROJECT_SOURCE_DIR}/src/manager)
15 SET(KEY_MANAGER_SOURCES
16 ${KEY_MANAGER_PATH}/main/key-manager-util.cpp
17 ${KEY_MANAGER_PATH}/main/generic-socket-manager.cpp
18 ${KEY_MANAGER_PATH}/main/socket-manager.cpp
19 ${KEY_MANAGER_PATH}/main/key-manager-main.cpp
20 ${KEY_MANAGER_PATH}/service/ckm-service.cpp
21 ${KEY_MANAGER_PATH}/service/ckm-logic.cpp
22 ${KEY_MANAGER_PATH}/service/key-provider.cpp
23 ${KEY_MANAGER_PATH}/service/ocsp.cpp
24 ${KEY_MANAGER_PATH}/service/crypto-logic.cpp
25 ${KEY_MANAGER_PATH}/service/CryptoService.cpp
26 ${KEY_MANAGER_PATH}/service/file-system.cpp
27 ${KEY_MANAGER_PATH}/service/db-crypto.cpp
28 ${KEY_MANAGER_PATH}/service/ocsp-service.cpp
29 ${KEY_MANAGER_PATH}/service/ocsp-logic.cpp
32 SET_SOURCE_FILES_PROPERTIES(
33 ${KEY_MANAGER_SOURCES}
35 COMPILE_FLAGS "-D_GNU_SOURCE -fvisibility=hidden")
37 INCLUDE_DIRECTORIES(SYSTEM
38 ${KEY_MANAGER_DEP_INCLUDE_DIRS}
42 ${KEY_MANAGER_SRC_PATH}/include
43 ${KEY_MANAGER_PATH}/main
44 ${KEY_MANAGER_PATH}/common
45 ${KEY_MANAGER_PATH}/service
46 ${KEY_MANAGER_PATH}/sqlcipher
47 ${KEY_MANAGER_PATH}/dpl/core/include
48 ${KEY_MANAGER_PATH}/dpl/log/include
49 ${KEY_MANAGER_PATH}/dpl/db/include
52 ADD_EXECUTABLE(${TARGET_KEY_MANAGER} ${KEY_MANAGER_SOURCES})
54 TARGET_LINK_LIBRARIES(${TARGET_KEY_MANAGER}
55 ${KEY_MANAGER_DEP_LIBRARIES}
56 ${TARGET_KEY_MANAGER_COMMON}
59 ################################################################################
61 SET(KEY_MANAGER_CLIENT_VERSION_MAJOR 1)
62 SET(KEY_MANAGER_CLIENT_VERSION ${KEY_MANAGER_CLIENT_VERSION_MAJOR}.0.1)
64 SET(KEY_MANAGER_CLIENT_SRC_PATH ${KEY_MANAGER_PATH}/client)
65 SET(KEY_MANAGER_CLIENT_CAPI_SRC_PATH ${KEY_MANAGER_PATH}/client-capi)
68 ${KEY_MANAGER_PATH}/client
69 ${KEY_MANAGER_PATH}/client-capi
70 ${KEY_MANAGER_PATH}/common
71 ${KEY_MANAGER_PATH}/dpl/core/include
72 ${KEY_MANAGER_PATH}/dpl/log/include
75 SET(KEY_MANAGER_CLIENT_SOURCES
76 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-common.cpp
77 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-error.cpp
78 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-manager-impl.cpp
79 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-type.cpp
80 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-error.cpp
81 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-manager.cpp
82 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-type-converter.cpp
83 ${KEY_MANAGER_PATH}/common/base64.cpp
84 ${KEY_MANAGER_PATH}/common/digest.cpp
85 ${KEY_MANAGER_PATH}/common/protocols.cpp
86 ${KEY_MANAGER_PATH}/common/message-buffer.cpp
87 ${KEY_MANAGER_PATH}/common/smack-check.cpp
88 ${KEY_MANAGER_PATH}/common/certificate-impl.cpp
89 ${KEY_MANAGER_PATH}/common/certificate-store.cpp
90 ${KEY_MANAGER_PATH}/common/generic-key.cpp
91 ${KEY_MANAGER_PATH}/common/pkcs12-impl.cpp
92 ${KEY_MANAGER_PATH}/dpl/log/src/abstract_log_provider.cpp
93 ${KEY_MANAGER_PATH}/dpl/log/src/dlog_log_provider.cpp
94 ${KEY_MANAGER_PATH}/dpl/log/src/log.cpp
95 ${KEY_MANAGER_PATH}/dpl/log/src/old_style_log_provider.cpp
96 ${KEY_MANAGER_PATH}/dpl/core/src/assert.cpp
97 ${KEY_MANAGER_PATH}/dpl/core/src/binary_queue.cpp
98 ${KEY_MANAGER_PATH}/dpl/core/src/colors.cpp
99 ${KEY_MANAGER_PATH}/dpl/core/src/exception.cpp
100 ${KEY_MANAGER_PATH}/dpl/core/src/noncopyable.cpp
101 ${KEY_MANAGER_PATH}/dpl/core/src/serialization.cpp
102 ${KEY_MANAGER_PATH}/dpl/core/src/singleton.cpp
103 ${KEY_MANAGER_PATH}/dpl/core/src/string.cpp
104 ${KEY_MANAGER_PATH}/dpl/core/src/errno_string.cpp
107 ADD_LIBRARY(${TARGET_KEY_MANAGER_CLIENT} SHARED ${KEY_MANAGER_CLIENT_SOURCES})
109 SET_TARGET_PROPERTIES(
110 ${TARGET_KEY_MANAGER_CLIENT}
112 COMPILE_FLAGS "-D_GNU_SOURCE -fPIC -fvisibility=default"
113 SOVERSION ${KEY_MANAGER_CLIENT_VERSION_MAJOR}
114 VERSION ${KEY_MANAGER_CLIENT_VERSION}
117 TARGET_LINK_LIBRARIES(${TARGET_KEY_MANAGER_CLIENT}
118 ${KEY_MANAGER_DEP_LIBRARIES}
121 ################################################################################
123 SET(KEY_MANAGER_CONTROL_CLIENT_VERSION_MAJOR 1)
124 SET(KEY_MANAGER_CONTROL_CLIENT_VERSION ${KEY_MANAGER_CONTROL_CLIENT_VERSION_MAJOR}.0.1)
126 SET(KEY_MANAGER_CONTROL_CLIENT_SRC_PATH ${KEY_MANAGER_PATH}/client)
127 SET(KEY_MANAGER_CONTROL_CLIENT_CAPI_SRC_PATH ${KEY_MANAGER_PATH}/client-capi)
130 ${KEY_MANAGER_PATH}/client
131 ${KEY_MANAGER_PATH}/client-capi
132 ${KEY_MANAGER_PATH}/common
133 ${KEY_MANAGER_PATH}/dpl/core/include
134 ${KEY_MANAGER_PATH}/dpl/log/include
137 SET(KEY_MANAGER_CONTROL_CLIENT_SOURCES
138 ${KEY_MANAGER_CONTROL_CLIENT_SRC_PATH}/client-control.cpp
139 ${KEY_MANAGER_CONTROL_CLIENT_SRC_PATH}/client-common.cpp
140 ${KEY_MANAGER_CONTROL_CLIENT_CAPI_SRC_PATH}/ckmc-control.cpp
141 ${KEY_MANAGER_CONTROL_CLIENT_CAPI_SRC_PATH}/ckmc-type-converter.cpp
142 ${KEY_MANAGER_PATH}/common/base64.cpp
143 ${KEY_MANAGER_PATH}/common/digest.cpp
144 ${KEY_MANAGER_PATH}/common/protocols.cpp
145 ${KEY_MANAGER_PATH}/common/message-buffer.cpp
146 ${KEY_MANAGER_PATH}/common/smack-check.cpp
147 ${KEY_MANAGER_PATH}/common/certificate-impl.cpp
148 ${KEY_MANAGER_PATH}/common/certificate-store.cpp
149 ${KEY_MANAGER_PATH}/common/generic-key.cpp
150 ${KEY_MANAGER_PATH}/dpl/log/src/abstract_log_provider.cpp
151 ${KEY_MANAGER_PATH}/dpl/log/src/dlog_log_provider.cpp
152 ${KEY_MANAGER_PATH}/dpl/log/src/log.cpp
153 ${KEY_MANAGER_PATH}/dpl/log/src/old_style_log_provider.cpp
154 ${KEY_MANAGER_PATH}/dpl/core/src/assert.cpp
155 ${KEY_MANAGER_PATH}/dpl/core/src/binary_queue.cpp
156 ${KEY_MANAGER_PATH}/dpl/core/src/colors.cpp
157 ${KEY_MANAGER_PATH}/dpl/core/src/exception.cpp
158 ${KEY_MANAGER_PATH}/dpl/core/src/noncopyable.cpp
159 ${KEY_MANAGER_PATH}/dpl/core/src/serialization.cpp
160 ${KEY_MANAGER_PATH}/dpl/core/src/singleton.cpp
161 ${KEY_MANAGER_PATH}/dpl/core/src/string.cpp
162 ${KEY_MANAGER_PATH}/dpl/core/src/errno_string.cpp
165 ADD_LIBRARY(${TARGET_KEY_MANAGER_CONTROL_CLIENT} SHARED ${KEY_MANAGER_CONTROL_CLIENT_SOURCES})
167 SET_TARGET_PROPERTIES(
168 ${TARGET_KEY_MANAGER_CONTROL_CLIENT}
170 COMPILE_FLAGS "-D_GNU_SOURCE -fPIC -fvisibility=default"
171 SOVERSION ${KEY_MANAGER_CONTROL_CLIENT_VERSION_MAJOR}
172 VERSION ${KEY_MANAGER_CONTROL_CLIENT_VERSION}
175 TARGET_LINK_LIBRARIES(${TARGET_KEY_MANAGER_CONTROL_CLIENT}
176 ${KEY_MANAGER_DEP_LIBRARIES}
179 ################################################################################
180 INSTALL(TARGETS ${TARGET_KEY_MANAGER_CLIENT} DESTINATION ${LIB_INSTALL_DIR})
181 INSTALL(TARGETS ${TARGET_KEY_MANAGER_CONTROL_CLIENT} DESTINATION ${LIB_INSTALL_DIR})
183 INSTALL(TARGETS ${TARGET_KEY_MANAGER} DESTINATION bin)
187 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-manager.h
188 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-certificate.h
189 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-control.h
190 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-error.h
191 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-key.h
192 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-password.h
193 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-pkcs12.h
194 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-raw-buffer.h
195 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-type.h
196 DESTINATION /usr/include/ckm/ckm
199 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-manager.h
200 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-control.h
201 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-error.h
202 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-type.h
203 DESTINATION /usr/include/ckm/ckmc
205 ################################################################################
207 ADD_SUBDIRECTORY(manager)
208 ADD_SUBDIRECTORY(listener)