1 PKG_CHECK_MODULES(KEY_MANAGER_DEP
9 SET(KEY_MANAGER_SRC_PATH ${PROJECT_SOURCE_DIR}/src)
10 SET(KEY_MANAGER_PATH ${PROJECT_SOURCE_DIR}/src/manager)
12 SET(KEY_MANAGER_SOURCES
13 ${KEY_MANAGER_PATH}/main/key-manager-util.cpp
14 ${KEY_MANAGER_PATH}/main/generic-socket-manager.cpp
15 ${KEY_MANAGER_PATH}/main/socket-manager.cpp
16 ${KEY_MANAGER_PATH}/main/key-manager-main.cpp
17 ${KEY_MANAGER_PATH}/service/echo.cpp
18 ${KEY_MANAGER_PATH}/service/ckm-service.cpp
19 ${KEY_MANAGER_PATH}/service/ckm-logic.cpp
20 ${KEY_MANAGER_PATH}/service/key-provider.cpp
21 ${KEY_MANAGER_PATH}/service/ocsp.cpp
22 ${KEY_MANAGER_PATH}/service/DBCryptoModule.cpp
23 ${KEY_MANAGER_PATH}/service/CryptoService.cpp
24 ${KEY_MANAGER_PATH}/service/file-system.cpp
27 SET_SOURCE_FILES_PROPERTIES(
28 ${KEY_MANAGER_SOURCES}
30 COMPILE_FLAGS "-D_GNU_SOURCE -fvisibility=hidden")
32 INCLUDE_DIRECTORIES(SYSTEM
33 ${KEY_MANAGER_DEP_INCLUDE_DIRS}
37 ${KEY_MANAGER_SRC_PATH}/include
38 ${KEY_MANAGER_PATH}/main
39 ${KEY_MANAGER_PATH}/common
40 ${KEY_MANAGER_PATH}/service
41 ${KEY_MANAGER_PATH}/dpl/core/include
42 ${KEY_MANAGER_PATH}/dpl/log/include
45 ADD_EXECUTABLE(${TARGET_KEY_MANAGER} ${KEY_MANAGER_SOURCES})
47 TARGET_LINK_LIBRARIES(${TARGET_KEY_MANAGER}
48 ${KEY_MANAGER_DEP_LIBRARIES}
49 ${TARGET_KEY_MANAGER_COMMON}
50 ${TARGET_KEY_MANAGER_KEY_PROVIDER}
55 ################################################################################
57 SET(KEY_MANAGER_CLIENT_VERSION_MAJOR 1)
58 SET(KEY_MANAGER_CLIENT_VERSION ${KEY_MANAGER_CLIENT_VERSION_MAJOR}.0.1)
60 SET(KEY_MANAGER_CLIENT_SRC_PATH ${KEY_MANAGER_PATH}/client)
63 ${KEY_MANAGER_PATH}/client
64 ${KEY_MANAGER_PATH}/common
65 ${KEY_MANAGER_PATH}/dpl/core/include
66 ${KEY_MANAGER_PATH}/dpl/log/include
69 SET(KEY_MANAGER_CLIENT_SOURCES
70 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-certificate.cpp
71 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-control.cpp
72 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-common.cpp
73 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-echo.cpp
74 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-key.cpp
75 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-manager.cpp
76 ${KEY_MANAGER_CLIENT_SRC_PATH}/client-manager-impl.cpp
79 ADD_LIBRARY(${TARGET_KEY_MANAGER_CLIENT} SHARED ${KEY_MANAGER_CLIENT_SOURCES})
81 SET_TARGET_PROPERTIES(
82 ${TARGET_KEY_MANAGER_CLIENT}
84 COMPILE_FLAGS "-D_GNU_SOURCE -fPIC -fvisibility=default"
85 SOVERSION ${KEY_MANAGER_CLIENT_VERSION_MAJOR}
86 VERSION ${KEY_MANAGER_CLIENT_VERSION}
89 TARGET_LINK_LIBRARIES(${TARGET_KEY_MANAGER_CLIENT}
90 ${KEY_MANAGER_DEP_LIBRARIES}
91 ${TARGET_KEY_MANAGER_COMMON}
94 ################################################################################
96 INSTALL(TARGETS ${TARGET_KEY_MANAGER_CLIENT} DESTINATION ${LIB_INSTALL_DIR})
98 INSTALL(TARGETS ${TARGET_KEY_MANAGER} DESTINATION bin)
101 ${KEY_MANAGER_SRC_PATH}/include/ckm/key-manager.h
102 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-error.h
103 ${KEY_MANAGER_SRC_PATH}/include/ckm/ckm-type.h
104 DESTINATION /usr/include/ckm/ckm
107 ################################################################################
109 ADD_SUBDIRECTORY(manager)