]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rados: build minimally when "WITH_MGR" is off 51250/head
authorJ. Eric Ivancich <ivancich@redhat.com>
Thu, 30 Sep 2021 22:18:30 +0000 (18:18 -0400)
committerKonstantin Shalygin <k0ste@k0ste.ru>
Sat, 2 Sep 2023 21:09:59 +0000 (04:09 +0700)
Minimize footprint of the MGR when WITH_MGR is off. Include the
minimal in MON. Don't include any MGR tests.

Signed-off-by: J. Eric Ivancich <ivancich@redhat.com>
(cherry picked from commit 15c6fb535d5c5b051f4ad9dc68e20c769b2293d7)

src/CMakeLists.txt
src/mon/CMakeLists.txt
src/test/CMakeLists.txt

index a9aef68ed6d5a641b0937a36ff5318011c1c5e42..6f5dd11f7bf38c98876322dc686a3bf89b171e39 100644 (file)
@@ -601,7 +601,9 @@ if(WITH_LIBRADOSSTRIPER)
   add_subdirectory(libradosstriper)
 endif()
 
-add_subdirectory(mgr)
+if(WITH_MGR)
+  add_subdirectory(mgr)
+endif()
 
 set(librados_config_srcs
   librados-config.cc)
index b4056fdb1ecd180cd279933604e7e25cf8d3a447..7b237c01c2f84511ffb71b9ac5a47979054c092a 100644 (file)
@@ -24,7 +24,11 @@ set(lib_mon_srcs
   ../mds/MDSAuthCaps.cc
   ../mgr/mgr_commands.cc
   ../osd/OSDCap.cc
-  $<TARGET_OBJECTS:mgr_cap_obj>)
+  ../mgr/MgrCap.cc)
+
+if(TARGET mgr_cap_obj)
+  list(APPEND lib_mon_srcs $<TARGET_OBJECTS:mgr_cap_obj>)
+endif()
 
 if(HAVE_GSSAPI)
   list(APPEND lib_mon_srcs
index eff00cc2a4fc068a4c106867e545f74ad1d795fb..2b699f0f62fc868323330f03bad63e751c1f954d 100644 (file)
@@ -63,7 +63,9 @@ if(NOT WIN32)
   add_subdirectory(libcephsqlite)
   add_subdirectory(client)
   add_subdirectory(mon)
-  add_subdirectory(mgr)
+  if(WITH_MGR)
+    add_subdirectory(mgr)
+  endif()
   add_subdirectory(msgr)
   add_subdirectory(neorados)
   add_subdirectory(objectstore)
@@ -72,7 +74,7 @@ if(NOT WIN32)
   add_subdirectory(osd)
   add_subdirectory(osdc)
   add_subdirectory(immutable_object_cache)
-endif()
+endif(NOT WIN32)
 
 if(WITH_RADOSGW)
   set(rgw_libs rgw_a)