Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:mslacken:ml
milvus
build-without-conan.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File build-without-conan.patch of Package milvus
From bb8fb268bcb06961514046b31c46fc26909fa00e Mon Sep 17 00:00:00 2001 From: Christian Goll <cgoll@suse.com> Date: Tue, 10 Sep 2024 10:47:38 +0200 Subject: [PATCH 1/3] build without conan Signed-off-by: Christian Goll <cgoll@suse.com> --- internal/core/CMakeLists.txt | 15 +++++++++------ internal/core/src/bitset/CMakeLists.txt | 1 + internal/core/thirdparty/CMakeLists.txt | 25 +++++++++++++++++-------- 3 files changed, 27 insertions(+), 14 deletions(-) diff --git a/internal/core/CMakeLists.txt b/internal/core/CMakeLists.txt index 10b3c3e7..4cc95958 100644 --- a/internal/core/CMakeLists.txt +++ b/internal/core/CMakeLists.txt @@ -95,12 +95,15 @@ set( CMAKE_INSTALL_RPATH "/usr/lib" "${CMAKE_INSTALL_PREFIX}/lib" "${CMAKE_INSTA set( CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE ) # **************************** Dependencies **************************** -list( APPEND CMAKE_MODULE_PATH ${CMAKE_BINARY_DIR}/conan ) -include( ${CMAKE_BINARY_DIR}/conan/conanbuildinfo.cmake ) -set( CONAN_DISABLE_CHECK_COMPILER ON ) -conan_basic_setup( KEEP_RPATHS ) - -set( CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH} ${CONAN_PROTOBUF_ROOT}) +option(WITH_CONAN "Build with CONAN" ON) +if ( WITH_CONAN ) + list( APPEND CMAKE_MODULE_PATH ${CMAKE_BINARY_DIR}/conan ) + include( ${CMAKE_BINARY_DIR}/conan/conanbuildinfo.cmake ) + set( CONAN_DISABLE_CHECK_COMPILER ON ) + conan_basic_setup( KEEP_RPATHS ) + + set( CMAKE_PREFIX_PATH ${CMAKE_PREFIX_PATH} ${CONAN_PROTOBUF_ROOT}) +endif() include( CTest ) include( BuildUtils ) diff --git a/internal/core/src/bitset/CMakeLists.txt b/internal/core/src/bitset/CMakeLists.txt index 3f7c6ae2..ca9c0875 100644 --- a/internal/core/src/bitset/CMakeLists.txt +++ b/internal/core/src/bitset/CMakeLists.txt @@ -41,3 +41,4 @@ elseif (${CMAKE_SYSTEM_PROCESSOR} MATCHES "arm*") endif() add_library(milvus_bitset OBJECT ${BITSET_SRCS}) +install(TARGETS milvus_bitset DESTINATION "${CMAKE_INSTALL_LIBDIR}") diff --git a/internal/core/thirdparty/CMakeLists.txt b/internal/core/thirdparty/CMakeLists.txt index eb1806ac..22a964ea 100644 --- a/internal/core/thirdparty/CMakeLists.txt +++ b/internal/core/thirdparty/CMakeLists.txt @@ -11,8 +11,7 @@ # or implied. See the License for the specific language governing permissions and limitations under the License. #------------------------------------------------------------------------------- # Using default c and cxx compiler in our build tree -# Thirdpart cxx and c flags -append_flags(CMAKE_CXX_FLAGS FLAGS "-O3 -fPIC -Wno-error -fopenmp -Wno-macro-redefined") +include(FindPkgConfig) if (NOT KNOWHERE_VERBOSE_THIRDPARTY_BUILD) set(EP_LOG_OPTIONS LOG_CONFIGURE 1 LOG_BUILD 1 LOG_INSTALL 1 LOG_DOWNLOAD 1) @@ -20,7 +19,6 @@ else () set(EP_LOG_OPTIONS) endif () -set(MAKE_BUILD_ARGS "-j6") include(FetchContent) set(FETCHCONTENT_BASE_DIR ${MILVUS_BINARY_DIR}/3rdparty_download) @@ -33,9 +31,16 @@ find_package(Threads REQUIRED) add_subdirectory(knowhere) add_subdirectory(boost_ext) -add_subdirectory(rocksdb) -add_subdirectory(rdkafka) -add_subdirectory(simdjson) +if ( WITH_CONAN ) + add_subdirectory(rocksdb) + add_subdirectory(rdkafka) + add_subdirectory(simdjson) +else() + find_package(RocksDB REQUIRED) + pkg_check_modules(rdkafka REQUIRED) + find_package(simdjson REQUIRED) +endif() + if (USE_OPENDAL) add_subdirectory(opendal) endif() @@ -43,7 +48,11 @@ add_subdirectory(tantivy) add_subdirectory(milvus-storage) -if (LINUX) - add_subdirectory(jemalloc) +if (LINUX ) + if ( WITH_CONAN ) + add_subdirectory(jemalloc) + else() + pkg_check_modules(jemalloc REQUIRED) + endif() endif() -- 2.43.0
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor