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}
57 ${TARGET_KEY_MANAGER_KEY_PROVIDER}
60 ################################################################################
62 SET(KEY_MANAGER_CLIENT_VERSION_MAJOR 1)
63 SET(KEY_MANAGER_CLIENT_VERSION ${KEY_MANAGER_CLIENT_VERSION_MAJOR}.0.1)
65 SET(KEY_MANAGER_CLIENT_SRC_PATH ${KEY_MANAGER_PATH}/client)
66 SET(KEY_MANAGER_CLIENT_CAPI_SRC_PATH ${KEY_MANAGER_PATH}/client-capi)
69 ${KEY_MANAGER_PATH}/client
70 ${KEY_MANAGER_PATH}/client-capi
71 ${KEY_MANAGER_PATH}/common
72 ${KEY_MANAGER_PATH}/dpl/core/include
73 ${KEY_MANAGER_PATH}/dpl/log/include
76 SET(KEY_MANAGER_CLIENT_SOURCES
77 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-common.cpp
78 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-error.cpp
79 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-manager-impl.cpp
80 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-type.cpp
81 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-error.cpp
82 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-manager.cpp
83 ${KEY_MANAGER_CLIENT_CAPI_SRC_PATH}/ckmc-type-converter.cpp
84 ${KEY_MANAGER_PATH}/common/base64.cpp
85 ${KEY_MANAGER_PATH}/common/digest.cpp
86 ${KEY_MANAGER_PATH}/common/protocols.cpp
87 ${KEY_MANAGER_PATH}/common/message-buffer.cpp
88 ${KEY_MANAGER_PATH}/common/smack-check.cpp
89 ${KEY_MANAGER_PATH}/common/certificate-impl.cpp
90 ${KEY_MANAGER_PATH}/common/certificate-store.cpp
91 ${KEY_MANAGER_PATH}/common/generic-key.cpp
92 ${KEY_MANAGER_PATH}/common/pkcs12-impl.cpp
93 ${KEY_MANAGER_PATH}/dpl/log/src/abstract_log_provider.cpp
94 ${KEY_MANAGER_PATH}/dpl/log/src/dlog_log_provider.cpp
95 ${KEY_MANAGER_PATH}/dpl/log/src/log.cpp
96 ${KEY_MANAGER_PATH}/dpl/log/src/old_style_log_provider.cpp
97 ${KEY_MANAGER_PATH}/dpl/core/src/assert.cpp
98 ${KEY_MANAGER_PATH}/dpl/core/src/binary_queue.cpp
99 ${KEY_MANAGER_PATH}/dpl/core/src/colors.cpp
100 ${KEY_MANAGER_PATH}/dpl/core/src/exception.cpp
101 ${KEY_MANAGER_PATH}/dpl/core/src/noncopyable.cpp
102 ${KEY_MANAGER_PATH}/dpl/core/src/serialization.cpp
103 ${KEY_MANAGER_PATH}/dpl/core/src/singleton.cpp
104 ${KEY_MANAGER_PATH}/dpl/core/src/string.cpp
105 ${KEY_MANAGER_PATH}/dpl/core/src/errno_string.cpp
108 ADD_LIBRARY(${TARGET_KEY_MANAGER_CLIENT} SHARED ${KEY_MANAGER_CLIENT_SOURCES})
110 SET_TARGET_PROPERTIES(
111 ${TARGET_KEY_MANAGER_CLIENT}
113 COMPILE_FLAGS "-D_GNU_SOURCE -fPIC -fvisibility=default"
114 SOVERSION ${KEY_MANAGER_CLIENT_VERSION_MAJOR}
115 VERSION ${KEY_MANAGER_CLIENT_VERSION}
118 TARGET_LINK_LIBRARIES(${TARGET_KEY_MANAGER_CLIENT}
119 ${KEY_MANAGER_DEP_LIBRARIES}
122 ################################################################################
124 SET(KEY_MANAGER_CONTROL_CLIENT_VERSION_MAJOR 1)
125 SET(KEY_MANAGER_CONTROL_CLIENT_VERSION ${KEY_MANAGER_CONTROL_CLIENT_VERSION_MAJOR}.0.1)
127 SET(KEY_MANAGER_CONTROL_CLIENT_SRC_PATH ${KEY_MANAGER_PATH}/client)
128 SET(KEY_MANAGER_CONTROL_CLIENT_CAPI_SRC_PATH ${KEY_MANAGER_PATH}/client-capi)
131 ${KEY_MANAGER_PATH}/client
132 ${KEY_MANAGER_PATH}/client-capi
133 ${KEY_MANAGER_PATH}/common
134 ${KEY_MANAGER_PATH}/dpl/core/include
135 ${KEY_MANAGER_PATH}/dpl/log/include
138 SET(KEY_MANAGER_CONTROL_CLIENT_SOURCES
139 ${KEY_MANAGER_CONTROL_CLIENT_SRC_PATH}/client-control.cpp
140 ${KEY_MANAGER_CONTROL_CLIENT_SRC_PATH}/client-common.cpp
141 ${KEY_MANAGER_CONTROL_CLIENT_CAPI_SRC_PATH}/ckmc-control.cpp
142 ${KEY_MANAGER_CONTROL_CLIENT_CAPI_SRC_PATH}/ckmc-type-converter.cpp
143 ${KEY_MANAGER_PATH}/common/base64.cpp
144 ${KEY_MANAGER_PATH}/common/digest.cpp
145 ${KEY_MANAGER_PATH}/common/protocols.cpp
146 ${KEY_MANAGER_PATH}/common/message-buffer.cpp
147 ${KEY_MANAGER_PATH}/common/smack-check.cpp
148 ${KEY_MANAGER_PATH}/common/certificate-impl.cpp
149 ${KEY_MANAGER_PATH}/common/certificate-store.cpp
150 ${KEY_MANAGER_PATH}/common/generic-key.cpp
151 ${KEY_MANAGER_PATH}/dpl/log/src/abstract_log_provider.cpp
152 ${KEY_MANAGER_PATH}/dpl/log/src/dlog_log_provider.cpp
153 ${KEY_MANAGER_PATH}/dpl/log/src/log.cpp
154 ${KEY_MANAGER_PATH}/dpl/log/src/old_style_log_provider.cpp
155 ${KEY_MANAGER_PATH}/dpl/core/src/assert.cpp
156 ${KEY_MANAGER_PATH}/dpl/core/src/binary_queue.cpp
157 ${KEY_MANAGER_PATH}/dpl/core/src/colors.cpp
158 ${KEY_MANAGER_PATH}/dpl/core/src/exception.cpp
159 ${KEY_MANAGER_PATH}/dpl/core/src/noncopyable.cpp
160 ${KEY_MANAGER_PATH}/dpl/core/src/serialization.cpp
161 ${KEY_MANAGER_PATH}/dpl/core/src/singleton.cpp
162 ${KEY_MANAGER_PATH}/dpl/core/src/string.cpp
163 ${KEY_MANAGER_PATH}/dpl/core/src/errno_string.cpp
166 ADD_LIBRARY(${TARGET_KEY_MANAGER_CONTROL_CLIENT} SHARED ${KEY_MANAGER_CONTROL_CLIENT_SOURCES})
168 SET_TARGET_PROPERTIES(
169 ${TARGET_KEY_MANAGER_CONTROL_CLIENT}
171 COMPILE_FLAGS "-D_GNU_SOURCE -fPIC -fvisibility=default"
172 SOVERSION ${KEY_MANAGER_CONTROL_CLIENT_VERSION_MAJOR}
173 VERSION ${KEY_MANAGER_CONTROL_CLIENT_VERSION}
176 TARGET_LINK_LIBRARIES(${TARGET_KEY_MANAGER_CONTROL_CLIENT}
177 ${KEY_MANAGER_DEP_LIBRARIES}
180 ################################################################################
181 INSTALL(TARGETS ${TARGET_KEY_MANAGER_CLIENT} DESTINATION ${LIB_INSTALL_DIR})
182 INSTALL(TARGETS ${TARGET_KEY_MANAGER_CONTROL_CLIENT} DESTINATION ${LIB_INSTALL_DIR})
184 INSTALL(TARGETS ${TARGET_KEY_MANAGER} DESTINATION bin)
188 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-manager.h
189 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-certificate.h
190 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-control.h
191 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-error.h
192 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-key.h
193 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-password.h
194 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-pkcs12.h
195 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-raw-buffer.h
196 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-type.h
197 DESTINATION /usr/include/ckm/ckm
200 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-manager.h
201 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-control.h
202 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-error.h
203 ${KEY_MANAGER_SRC_PATH}/include/ckmc/ckmc-type.h
204 DESTINATION /usr/include/ckm/ckmc
206 ################################################################################
208 ADD_SUBDIRECTORY(manager)
209 ADD_SUBDIRECTORY(listener)