File tantivity-local-install.patch of Package milvus
From 8b5a9443618d6526f638305f5966f9e16945e025 Mon Sep 17 00:00:00 2001
From: Christian Goll <cgoll@suse.com>
Date: Wed, 11 Sep 2024 11:43:24 +0200
Subject: [PATCH] tantivity local install
Signed-off-by: Christian Goll <cgoll@suse.com>
---
internal/core/thirdparty/tantivy/CMakeLists.txt | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/internal/core/thirdparty/tantivy/CMakeLists.txt b/internal/core/thirdparty/tantivy/CMakeLists.txt
index 3963647e..fc14e704 100644
--- a/internal/core/thirdparty/tantivy/CMakeLists.txt
+++ b/internal/core/thirdparty/tantivy/CMakeLists.txt
@@ -6,8 +6,8 @@ else ()
set(TARGET_DIR "release")
endif ()
-set(TANTIVY_LIB_DIR "${CMAKE_INSTALL_PREFIX}/lib")
-set(TANTIVY_INCLUDE_DIR "${CMAKE_INSTALL_PREFIX}/include")
+set(TANTIVY_LIB_DIR "$ENV{HOME}${CMAKE_INSTALL_PREFIX}/lib")
+set(TANTIVY_INCLUDE_DIR "$ENV{HOME}${CMAKE_INSTALL_PREFIX}/include")
set(TANTIVY_NAME "libtantivy_binding${CMAKE_STATIC_LIBRARY_SUFFIX}")
set(LIB_FILE "${CMAKE_CURRENT_BINARY_DIR}/${TARGET_DIR}/${TANTIVY_NAME}")
@@ -51,7 +51,7 @@ set_target_properties(tantivy_binding
PROPERTIES
IMPORTED_GLOBAL TRUE
IMPORTED_LOCATION "${TANTIVY_LIB_DIR}/${TANTIVY_NAME}"
- INTERFACE_INCLUDE_DIRECTORIES "${CMAKE_INSTALL_PREFIX}/include")
+ INTERFACE_INCLUDE_DIRECTORIES "${TANTIVY_INCLUDE_DIR}")
if (CMAKE_BUILD_TYPE STREQUAL "Debug")
add_compile_options(-fno-stack-protector -fno-omit-frame-pointer -fno-var-tracking -fsanitize=address)
--
2.43.0