File tree Expand file tree Collapse file tree
mooncake-transfer-engine/include Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ if (BUILD_UNIT_TESTS)
1212 enable_testing ()
1313endif ()
1414
15+ option (WITH_TE "build mooncake transfer engine and sample code" ON )
1516option (WITH_STORE "build mooncake store library and sample code" ON )
1617option (WITH_P2P_STORE "build p2p store library and sample code" OFF )
1718option (WITH_RUST_EXAMPLE "build the Rust interface and sample code for the transfer engine" OFF )
@@ -45,8 +46,10 @@ add_subdirectory(mooncake-common)
4546include_directories (mooncake-common/etcd )
4647include_directories (mooncake-common/include )
4748
48- add_subdirectory (mooncake-transfer-engine )
49- include_directories (mooncake-transfer-engine/include )
49+ if (WITH_TE)
50+ add_subdirectory (mooncake-transfer-engine )
51+ include_directories (mooncake-transfer-engine/include )
52+ endif ()
5053
5154if (WITH_STORE)
5255 message (STATUS "Mooncake Store will be built" )
Original file line number Diff line number Diff line change @@ -10,4 +10,8 @@ add_library(mooncake_common
1010target_link_libraries (mooncake_common PUBLIC
1111 yaml-cpp
1212 jsoncpp
13- )
13+ )
14+
15+ if (BUILD_SHARED_LIBS )
16+ install (TARGETS mooncake_common DESTINATION lib)
17+ endif ()
Original file line number Diff line number Diff line change @@ -29,15 +29,17 @@ message("${PYTHON_SYS_PATH}")
2929
3030set (PYTHON_PACKAGE_NAME "mooncake" )
3131
32- pybind11_add_module (engine ${SOURCES} ${CACHE_ALLOCATOR_SOURCES}
33- transfer_engine/transfer_engine_py.cpp
34- )
32+ if (WITH_TE)
33+ pybind11_add_module (engine ${SOURCES} ${CACHE_ALLOCATOR_SOURCES}
34+ transfer_engine/transfer_engine_py.cpp
35+ )
3536
36- target_link_libraries (engine PUBLIC
37- transfer_engine
38- glog::glog
39- gflags::gflags
40- )
37+ target_link_libraries (engine PUBLIC
38+ transfer_engine
39+ glog::glog
40+ gflags::gflags
41+ )
42+ endif ()
4143
4244set (ALLOCATOR_SO_PATH "${CMAKE_BINARY_DIR } /mooncake-transfer-engine/nvlink-allocator/nvlink_allocator.so" )
4345if (USE_MNNVL)
@@ -113,4 +115,6 @@ if (WITH_STORE)
113115 install (TARGETS store DESTINATION ${PYTHON_SYS_PATH} /${PYTHON_PACKAGE_NAME} )
114116endif ()
115117
116- install (TARGETS engine DESTINATION ${PYTHON_SYS_PATH} /${PYTHON_PACKAGE_NAME} )
118+ if (WITH_TE)
119+ install (TARGETS engine DESTINATION ${PYTHON_SYS_PATH} /${PYTHON_PACKAGE_NAME} )
120+ endif ()
Original file line number Diff line number Diff line change @@ -48,6 +48,10 @@ if (STORE_USE_ETCD)
4848 add_dependencies (mooncake_store build_etcd_wrapper )
4949endif ()
5050
51+ if (BUILD_SHARED_LIBS )
52+ install (TARGETS mooncake_store DESTINATION lib)
53+ endif ()
54+
5155# Master binary
5256add_executable (mooncake_master master.cpp )
5357
@@ -66,6 +70,7 @@ target_link_libraries(mooncake_master PRIVATE
6670 mooncake_store
6771 cachelib_memory_allocator
6872 pthread
73+ ibverbs
6974 mooncake_common
7075 ${ETCD_WRAPPER_LIB}
7176 ${MASTER_EXTRA_LIBS}
@@ -75,4 +80,4 @@ if (STORE_USE_ETCD)
7580 add_dependencies (mooncake_master build_etcd_wrapper )
7681endif ()
7782
78- install (TARGETS mooncake_master DESTINATION bin)
83+ install (TARGETS mooncake_master DESTINATION bin)
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ function(add_store_test name)
55 cachelib_memory_allocator
66 ${ETCD_WRAPPER_LIB}
77 glog
8+ ibverbs
89 gtest
910 gtest_main
1011 pthread
Original file line number Diff line number Diff line change 11install (FILES transfer_engine_c.h DESTINATION include)
2+ install (FILES common.h DESTINATION include)
3+ install (FILES config.h DESTINATION include)
4+ install (FILES error.h DESTINATION include)
5+ install (FILES memory_location.h DESTINATION include)
6+ install (FILES multi_transport.h DESTINATION include)
7+ install (FILES topology.h DESTINATION include)
8+ install (FILES transfer_engine.h DESTINATION include)
9+ install (FILES transfer_metadata.h DESTINATION include)
10+ install (FILES common/base/status.h DESTINATION include/common/base)
11+ install (FILES transport/transport.h DESTINATION include/transport)
You can’t perform that action at this time.
0 commit comments