Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
9 changes: 2 additions & 7 deletions ci/scripts/setup_rust.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
set -eux

RUSTUP_VERSION=${RUSTUP_VERSION:-1.29.0}
# 1.90.0 is the minimum required by paimon-full-text 0.1.0 (rust-version in its Cargo.toml).
RUST_VERSION=${RUST_VERSION:-1.90.0}
# Keep in sync with PAIMON_RUST_TOOLCHAIN in cmake_modules/ThirdpartyToolchain.cmake.
RUST_VERSION=${RUST_VERSION:-1.95.0}
CBINDGEN_VERSION=${CBINDGEN_VERSION:-0.29.2}
PROTOC_VERSION=27.4

Expand Down Expand Up @@ -76,11 +76,6 @@ if ! command -v protoc >/dev/null 2>&1 || \
echo "${protoc_home}/bin" >> "${GITHUB_PATH:-/dev/null}" || true
fi

# Vortex's FFI build pins rust-version >= 1.95 and is invoked with RUSTUP_TOOLCHAIN=stable (see
# cmake_modules/ThirdpartyToolchain.cmake). Install the stable channel alongside the pinned default
# so Vortex builds with it while Lance, Mosaic and tantivy-fts keep using the default toolchain.
rustup toolchain install stable --profile minimal

# cbindgen is used by the crate's build.rs to emit the C header that the
# C++ side includes. Corrosion will also run cbindgen at CMake configure
# time; both paths need it available.
Expand Down
9 changes: 7 additions & 2 deletions cmake_modules/ThirdpartyToolchain.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -1499,6 +1499,11 @@ macro(build_vortex)
# neither of which can go through paimon's filesystem. `callback_io.rs` adds an entry point
# backed by host callbacks; it is maintained in this repository and injected into the Vortex
# source tree, and the patch only declares the module.
# Keep in sync with RUST_VERSION in ci/scripts/setup_rust.sh; it overrides the
# rust-toolchain.toml shipped inside the Vortex archive.
set(PAIMON_RUST_TOOLCHAIN
"1.95.0"
CACHE STRING "Rust toolchain used by the Vortex FFI build.")
set(VORTEX_PATCH_FILE "${CMAKE_CURRENT_LIST_DIR}/vortex.diff")
set(VORTEX_CALLBACK_IO_SRC
"${CMAKE_SOURCE_DIR}/crates/vortex_callback_io/callback_io.rs")
Expand Down Expand Up @@ -1533,8 +1538,8 @@ macro(build_vortex)
"${VORTEX_CALLBACK_IO_SRC}"
"<SOURCE_DIR>/vortex-ffi/src/callback_io.rs"
COMMAND ${CMAKE_COMMAND} -E env "FLATC=${VORTEX_FLATC}"
"RUSTUP_TOOLCHAIN=stable" "CC=${CMAKE_C_COMPILER}"
"CXX=${CMAKE_CXX_COMPILER}"
"RUSTUP_TOOLCHAIN=${PAIMON_RUST_TOOLCHAIN}"
"CC=${CMAKE_C_COMPILER}" "CXX=${CMAKE_CXX_COMPILER}"
"CARGO_TARGET_DIR=${VORTEX_CARGO_TARGET_DIR}"
"RUSTFLAGS=-Crelocation-model=pic"
${PAIMON_CARGO_EXECUTABLE} rustc --locked --package
Expand Down
Loading