2 add_executable(ceph_rgw_jsonparser
4 target_link_libraries(ceph_rgw_jsonparser
8 add_executable(ceph_rgw_multiparser
10 target_link_libraries(ceph_rgw_multiparser
20 add_custom_target(civetweb_h
21 COMMAND ${CMAKE_COMMAND} -E make_directory
22 "${CMAKE_BINARY_DIR}/src/include/civetweb"
23 COMMAND ${CMAKE_COMMAND} -E copy_if_different
24 "${CMAKE_SOURCE_DIR}/src/civetweb/include/civetweb.h"
25 "${CMAKE_BINARY_DIR}/src/include/civetweb"
26 COMMENT "keep civetweb.h up-to-date")
63 rgw_sync_module_log.cc
71 rgw_object_expirer_core.cc
90 rgw_rest_replica_log.cc
106 rgw_crypt_sanitize.cc)
108 if (WITH_RADOSGW_FCGI_FRONTEND)
109 list(APPEND rgw_a_srcs rgw_fcgi.cc)
112 add_library(rgw_a STATIC ${rgw_a_srcs})
114 add_dependencies(rgw_a civetweb_h)
116 target_include_directories(rgw_a PUBLIC
119 target_compile_definitions(rgw_a PUBLIC BOOST_COROUTINES_NO_DEPRECATION_WARNING)
121 target_link_libraries(rgw_a librados cls_lock_client cls_rgw_client cls_refcount_client
122 cls_log_client cls_statelog_client cls_timeindex_client cls_version_client
123 cls_replica_log_client cls_user_client ceph-common common_utf8 global
124 ${CURL_LIBRARIES} ${Boost_LIBRARIES}
126 ${OPENLDAP_LIBRARIES} ${CRYPTO_LIBS})
129 rgw_loadgen_process.cc
131 rgw_civetweb_frontend.cc
134 if (WITH_RADOSGW_FCGI_FRONTEND)
135 list(APPEND radosgw_srcs rgw_fcgi_process.cc)
138 if (WITH_RADOSGW_BEAST_FRONTEND)
139 list(APPEND radosgw_srcs
141 rgw_asio_frontend.cc)
142 endif (WITH_RADOSGW_BEAST_FRONTEND)
144 add_library(radosgw_a STATIC ${radosgw_srcs}
145 $<TARGET_OBJECTS:civetweb_common_objs>)
146 target_link_libraries(radosgw_a rgw_a ${SSL_LIBRARIES})
148 add_executable(radosgw rgw_main.cc)
149 target_link_libraries(radosgw radosgw_a librados
150 cls_rgw_client cls_lock_client cls_refcount_client
151 cls_log_client cls_statelog_client cls_timeindex_client
152 cls_version_client cls_replica_log_client cls_user_client
153 global ${FCGI_LIBRARY} ${LIB_RESOLV}
154 ${CURL_LIBRARIES} ${EXPAT_LIBRARIES} ${BLKID_LIBRARIES}
156 # radosgw depends on cls libraries at runtime, but not as link dependencies
157 add_dependencies(radosgw cls_rgw cls_lock cls_refcount
158 cls_log cls_statelog cls_timeindex
159 cls_version cls_replica_log cls_user)
160 install(TARGETS radosgw DESTINATION bin)
162 set(radosgw_admin_srcs
165 add_executable(radosgw-admin ${radosgw_admin_srcs})
166 target_link_libraries(radosgw-admin rgw_a librados
167 cls_rgw_client cls_lock_client cls_refcount_client
168 cls_log_client cls_statelog_client cls_timeindex_client
169 cls_version_client cls_replica_log_client cls_user_client
170 global ${FCGI_LIBRARY} ${LIB_RESOLV}
171 ${CURL_LIBRARIES} ${EXPAT_LIBRARIES} ${SSL_LIBRARIES} ${BLKID_LIBRARIES})
172 install(TARGETS radosgw-admin DESTINATION bin)
174 set(radosgw_token_srcs
176 add_executable(radosgw-token ${radosgw_token_srcs})
177 target_link_libraries(radosgw-token librados
178 global ${ALLOC_LIBS})
179 install(TARGETS radosgw-token DESTINATION bin)
181 set(radosgw_object_expirer_srcs
182 rgw_object_expirer.cc)
183 add_executable(radosgw-object-expirer ${radosgw_object_expirer_srcs})
184 target_link_libraries(radosgw-object-expirer rgw_a librados
185 cls_rgw_client cls_lock_client cls_refcount_client
186 cls_log_client cls_statelog_client cls_timeindex_client
187 cls_version_client cls_replica_log_client cls_user_client
188 global ${FCGI_LIBRARY} ${LIB_RESOLV}
189 ${CURL_LIBRARIES} ${EXPAT_LIBRARIES})
190 install(TARGETS radosgw-object-expirer DESTINATION bin)
195 add_library(rgw SHARED ${librgw_srcs})
196 target_link_libraries(rgw LINK_PRIVATE
206 cls_replica_log_client
212 set_target_properties(rgw PROPERTIES OUTPUT_NAME rgw VERSION 2.0.0
214 install(TARGETS rgw DESTINATION ${CMAKE_INSTALL_LIBDIR})
217 include(MergeStaticLibraries)
218 add_library(cephd_rgw_base STATIC rgw_main.cc ${radosgw_admin_srcs})
219 target_include_directories(cephd_rgw_base PUBLIC ${FCGI_INCLUDE_DIR})
220 set_target_properties(cephd_rgw_base PROPERTIES COMPILE_DEFINITIONS BUILDING_FOR_EMBEDDED)
221 merge_static_libraries(cephd_rgw cephd_rgw_base rgw_a radosgw_a)
222 target_link_libraries(cephd_rgw ${FCGI_LIBRARY})