Skip to content
Merged
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
e506f86
Clean unused imports and improve type annotations
ShuhaoZhangTony Sep 30, 2025
36a0db6
code quality fix
ShuhaoZhangTony Sep 30, 2025
c19186a
fix: 添加libstdc++版本检查和自动修复
ShuhaoZhangTony Oct 2, 2025
71b6a91
Update SageFlow import error message to recommend CLI install
ShuhaoZhangTony Oct 5, 2025
6374a63
chore: remove python bindings (moved to main SAGE repo)
ShuhaoZhangTony Oct 5, 2025
fa7c6b0
chore: move examples to main SAGE repo
ShuhaoZhangTony Oct 5, 2025
f154ec1
refactor: rename library from candy to sageflow
ShuhaoZhangTony Oct 7, 2025
ebef3ff
chore: completely remove Python bindings build logic
ShuhaoZhangTony Oct 7, 2025
95424c2
refactor: rename namespace from candy to sageFlow
ShuhaoZhangTony Oct 7, 2025
12a2318
fix: replace candy:: scope resolution with sageFlow::
ShuhaoZhangTony Oct 7, 2025
aa8879b
refactor: 改为动态库以匹配 sageDB 架构
ShuhaoZhangTony Oct 7, 2025
81af7dd
fix: 只在 BUILD_TESTING=ON 时构建 gtest
ShuhaoZhangTony Oct 7, 2025
88bf3a7
将例子推送回c++项目
ShuhaoZhangTony Oct 9, 2025
63f3895
update namespaces and add examples
ShuhaoZhangTony Oct 9, 2025
f1c1ae4
fix examples to link against sageflow
ShuhaoZhangTony Oct 9, 2025
af22e8a
updated: refs/heads/main-dev
ShuhaoZhangTony Oct 9, 2025
8f43967
quick fix
ShuhaoZhangTony Oct 9, 2025
a6839ac
清理.gitignore文件,移除不必要的注释和空行
ShuhaoZhangTony Oct 9, 2025
f0827ee
fix streaming examples build bug (#52)
ZeroJustMe Oct 9, 2025
8ac9c6b
Extract data generation as modular framework with dataset support, da…
ZeroJustMe Oct 13, 2025
c77ab52
Update join experiment tools (#54)
ZeroJustMe Oct 13, 2025
8991da8
style: apply ruff formatting fixes
ShuhaoZhangTony Oct 25, 2025
1f07266
feat: Add Python bindings with module_local() for type safety
ShuhaoZhangTony Oct 29, 2025
56b7253
fix: Add conditional SKBUILD install for libsageflow.so
ShuhaoZhangTony Oct 29, 2025
a3b446b
fix(cmake): Fix shared library installation for wheel builds
ShuhaoZhangTony Oct 29, 2025
991922f
install fix
KimmoZAG Oct 30, 2025
7bec747
cicd fix
KimmoZAG Oct 30, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 1 addition & 32 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.20)

project(CANDY CXX)
project(sageFlow CXX)

set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
Expand All @@ -16,7 +16,6 @@ if(BUILD_TESTING)
enable_testing()
endif()


set(_sage_flow_shared_deps FALSE)
if(DEFINED SAGE_COMMON_DEPS_FILE AND EXISTS "${SAGE_COMMON_DEPS_FILE}")
include("${SAGE_COMMON_DEPS_FILE}")
Expand Down Expand Up @@ -79,33 +78,3 @@ add_subdirectory(src)
add_subdirectory(test)
add_subdirectory(examples)

# Python bindings
if(NOT _sage_flow_shared_deps)
include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/pybind11_dependency.cmake)
endif()

pybind11_add_module(_sage_flow python/bindings.cpp)
target_link_libraries(_sage_flow PRIVATE
candy
externalRuntimeLibs
)
target_include_directories(_sage_flow PRIVATE include)
if(DEFINED SAGE_COMMON_COMPILE_DEFINITIONS)
target_compile_definitions(_sage_flow PRIVATE ${SAGE_COMMON_COMPILE_DEFINITIONS})
else()
target_compile_definitions(_sage_flow PRIVATE PYBIND11_INTERNALS_ID="sage_pybind11_shared")
endif()

# Reduce exported symbol surface to minimize potential cross-module clashes
if(DEFINED SAGE_COMMON_COMPILE_OPTIONS)
target_compile_options(_sage_flow PRIVATE ${SAGE_COMMON_COMPILE_OPTIONS})
else()
target_compile_options(_sage_flow PRIVATE -fvisibility=hidden -fvisibility-inlines-hidden)
endif()

if(ENABLE_GPERFTOOLS AND DEFINED SAGE_GPERFTOOLS_LIBS AND SAGE_GPERFTOOLS_LIBS)
target_link_libraries(_sage_flow PRIVATE ${SAGE_GPERFTOOLS_LIBS})
endif()
set_target_properties(_sage_flow PROPERTIES CXX_VISIBILITY_PRESET hidden VISIBILITY_INLINES_HIDDEN YES)


39 changes: 39 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,45 @@ BUILD_TYPE=${BUILD_TYPE:-Debug}

echo "Building sageFlow with CMake (CMAKE_BUILD_TYPE=${BUILD_TYPE})..."

# Function to check and fix libstdc++ version issue in conda environment
check_libstdcxx() {
# Only check if we're in a conda environment
if [[ -z "${CONDA_PREFIX}" ]]; then
return 0
fi

# Check if conda libstdc++ needs update
local conda_libstdcxx="${CONDA_PREFIX}/lib/libstdc++.so.6"
if [[ ! -f "${conda_libstdcxx}" ]]; then
return 0
fi

# Check GCC version requirement
local gcc_version=$(gcc -dumpversion | cut -d. -f1)
if [[ ${gcc_version} -ge 11 ]]; then
# Check if conda libstdc++ has required GLIBCXX version
if ! strings "${conda_libstdcxx}" | grep -q "GLIBCXX_3.4.30"; then
echo "⚠️ 检测到conda环境中的libstdc++版本过低,正在更新..."
echo " 这是C++20/GCC 11+编译所必需的"

# Try to update libstdc++ in conda environment
if command -v conda &> /dev/null; then
conda install -c conda-forge libstdcxx-ng -y || {
echo "⚠️ 无法自动更新libstdc++,将使用系统版本"
# Set LD_LIBRARY_PATH to prefer system libstdc++
if [[ -f "/usr/lib/x86_64-linux-gnu/libstdc++.so.6" ]]; then
export LD_LIBRARY_PATH="/usr/lib/x86_64-linux-gnu:${LD_LIBRARY_PATH}"
echo " 已设置LD_LIBRARY_PATH优先使用系统libstdc++"
fi
}
fi
fi
fi
}

# Check libstdc++ before building
check_libstdcxx

# Create build directory if not exists
mkdir -p build

Expand Down
2 changes: 0 additions & 2 deletions examples/CMakeLists.txt

This file was deleted.

13 changes: 0 additions & 13 deletions examples/README.md

This file was deleted.

15 changes: 0 additions & 15 deletions examples/Source/CMakeLists.txt

This file was deleted.

175 changes: 0 additions & 175 deletions examples/Source/fvecs_to_vector_records.cpp

This file was deleted.

Loading
Loading