Skip to content

Commit 776d65b

Browse files
committed
Fix more
1 parent d9da911 commit 776d65b

9 files changed

Lines changed: 53 additions & 78 deletions

File tree

.github/workflows/velox_weekly.yml

Lines changed: 13 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -35,40 +35,6 @@ concurrency:
3535
cancel-in-progress: true
3636

3737
jobs:
38-
build-on-centos-7:
39-
strategy:
40-
fail-fast: false
41-
if: ${{ startsWith(github.repository, 'apache/') }}
42-
runs-on: ubuntu-22.04
43-
container: centos:7
44-
steps:
45-
- name: Build Gluten native libraries and package
46-
run: |
47-
sed -i -e 's|mirrorlist=|#mirrorlist=|g' /etc/yum.repos.d/CentOS-* || true
48-
sed -i -e 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-* || true
49-
yum update -y
50-
yum install -y epel-release sudo dnf
51-
yum install -y centos-release-scl
52-
rm /etc/yum.repos.d/CentOS-SCLo-scl.repo -f
53-
sed -i \
54-
-e 's/^mirrorlist/#mirrorlist/' \
55-
-e 's/^#baseurl/baseurl/' \
56-
-e 's/mirror\.centos\.org/vault.centos.org/' \
57-
/etc/yum.repos.d/CentOS-SCLo-scl-rh.repo
58-
yum install -y devtoolset-11
59-
source /opt/rh/devtoolset-11/enable
60-
yum install -y java-1.8.0-openjdk-devel patch wget git perl python3-pip
61-
export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk && \
62-
export PATH=$JAVA_HOME/bin:$PATH
63-
64-
# action/checkout does not work centos7 anymore, so we clone the branch instead.
65-
git clone -b main --depth=1 https://github.com/apache/gluten.git && cd gluten/
66-
if [ ${{ github.event_name }} = "pull_request" ]; then
67-
git fetch origin ${{ github.ref }}:pr_branch && git checkout pr_branch
68-
fi
69-
echo "TEST ONLY"
70-
./dev/package.sh --spark_version=3.5
71-
7238
build-on-centos:
7339
strategy:
7440
fail-fast: false
@@ -86,25 +52,19 @@ jobs:
8652
sed -i -e "s|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g" /etc/yum.repos.d/CentOS-* || true
8753
- name: build
8854
run: |
89-
yum update -y
90-
yum install -y epel-release sudo dnf
91-
if [ "${{ matrix.os }}" = "centos:7" ]; then
92-
yum install -y centos-release-scl
93-
rm /etc/yum.repos.d/CentOS-SCLo-scl.repo -f
94-
sed -i \
95-
-e 's/^mirrorlist/#mirrorlist/' \
96-
-e 's/^#baseurl/baseurl/' \
97-
-e 's/mirror\.centos\.org/vault.centos.org/' \
98-
/etc/yum.repos.d/CentOS-SCLo-scl-rh.repo
99-
yum install -y devtoolset-11
100-
source /opt/rh/devtoolset-11/enable
101-
elif [ "${{ matrix.os }}" = "quay.io/centos/centos:stream9" ]; then
102-
dnf install -y --setopt=install_weak_deps=False gcc-toolset-12
103-
source /opt/rh/gcc-toolset-12/enable || exit 1
104-
else
105-
dnf install -y --setopt=install_weak_deps=False gcc-toolset-11
106-
source /opt/rh/gcc-toolset-11/enable || exit 1
55+
if [ "${{ matrix.os }}" = "centos:8" ]; then
56+
sed -i -e "s|mirrorlist=|#mirrorlist=|g" /etc/yum.repos.d/CentOS-* || true
57+
sed -i -e "s|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g" /etc/yum.repos.d/CentOS-* || true
58+
dnf install -y centos-release-stream
59+
dnf swap -y centos-{linux,stream}-repos || true
60+
sed -i -e "s|mirrorlist=|#mirrorlist=|g" /etc/yum.repos.d/CentOS-Stream-* || true
61+
sed -i -e "s|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g" /etc/yum.repos.d/CentOS-Stream-* || true
62+
dnf clean all
10763
fi
64+
dnf update -y
65+
dnf install -y sudo
66+
dnf install -y --setopt=install_weak_deps=False gcc-toolset-12
67+
source /opt/rh/gcc-toolset-12/enable || exit 1
10868
yum install -y java-1.8.0-openjdk-devel patch wget git perl
10969
export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk && \
11070
export PATH=$JAVA_HOME/bin:$PATH
@@ -145,7 +105,7 @@ jobs:
145105
apt autoremove -y
146106
rm -rf /tmp/*
147107
fi
148-
sudo apt-get install -y openjdk-8-jdk python3-pip cmake libboost-all-dev
108+
sudo apt-get install -y openjdk-8-jdk python3-pip cmake
149109
export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
150110
cd $GITHUB_WORKSPACE/ && ./dev/package.sh --spark_version=3.5
151111

cpp/velox/CMakeLists.txt

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -413,17 +413,9 @@ if(DEFINED VCPKG_INSTALLED_DIR
413413
PRIVATE ${VCPKG_INSTALLED_DIR}/${VCPKG_TRIPLET_DIR}/lib/libthriftcpp2.a
414414
${VCPKG_INSTALLED_DIR}/${VCPKG_TRIPLET_DIR}/lib/libthriftprotocol.a)
415415
else()
416-
message(STATUS "Using system thrift libraries from /usr/local/lib")
417-
find_library(
418-
THRIFTCPP2_LIB
419-
NAMES thriftcpp2
420-
PATHS /usr/local/lib
421-
NO_DEFAULT_PATH)
422-
find_library(
423-
THRIFTPROTOCOL_LIB
424-
NAMES thriftprotocol
425-
PATHS /usr/local/lib
426-
NO_DEFAULT_PATH)
416+
message(STATUS "Using system thrift libraries")
417+
find_library(THRIFTCPP2_LIB NAMES thriftcpp2)
418+
find_library(THRIFTPROTOCOL_LIB NAMES thriftprotocol)
427419

428420
if(THRIFTCPP2_LIB AND THRIFTPROTOCOL_LIB)
429421
target_link_libraries(velox PRIVATE ${THRIFTCPP2_LIB} ${THRIFTPROTOCOL_LIB})

dev/build-thirdparty.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,9 @@ function process_setup_ubuntu_2204 {
3838
function process_setup_centos_9 {
3939
cp /lib64/{libre2.so.9,libdouble-conversion.so.3,libevent-2.1.so.7,libdwarf.so.0,libicudata.so.67,libicui18n.so.67,libicuuc.so.67,libsodium.so.23} $THIRDPARTY_LIB/
4040
cp /usr/local/lib/{libboost_context.so.1.84.0,libboost_filesystem.so.1.84.0,libboost_program_options.so.1.84.0,libboost_regex.so.1.84.0,libboost_system.so.1.84.0,libboost_thread.so.1.84.0,libboost_atomic.so.1.84.0} $THIRDPARTY_LIB/
41-
cp /usr/local/lib/{libgflags.so.2.2,libglog.so.1,libgeos.so.3.10.7} $THIRDPARTY_LIB/
41+
cp /usr/local/lib/libgflags.so.2.2 $THIRDPARTY_LIB/
42+
find /usr/local/lib /usr/local/lib64 -name "libglog.so.1" -exec cp {} $THIRDPARTY_LIB/ \; 2>/dev/null
43+
find /usr/local/lib /usr/local/lib64 -name "libgeos.so.3.10.7" -exec cp {} $THIRDPARTY_LIB/ \; 2>/dev/null
4244
}
4345

4446
function process_setup_centos_8 {

dev/vcpkg/triplets/arm64-linux-neon.cmake

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,7 @@ set(VCPKG_LINKER_FLAGS "-static-libstdc++ -static-libgcc")
1212
if("${PORT}" STREQUAL "openssl" AND "$ENV{VCPKG_DYNAMIC_OPENSSL}" STREQUAL "ON")
1313
set(VCPKG_LIBRARY_LINKAGE dynamic)
1414
endif()
15+
16+
if("${PORT}" STREQUAL "icu")
17+
set(VCPKG_LIBRARY_LINKAGE dynamic)
18+
endif()

dev/vcpkg/vcpkg-configuration.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,5 @@
1515
"baseline": "a7b6122f6b6504d16d96117336a0562693579933",
1616
"packages": [ "upb"]
1717
}
18-
1918
]
2019
}

ep/build-velox/src/build-velox.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ function compile {
120120
-DVELOX_MONO_LIBRARY=ON -DVELOX_BUILD_RUNNER=OFF -DVELOX_SIMDJSON_SKIPUTF8VALIDATION=ON \
121121
-DVELOX_ENABLE_GEO=OFF"
122122
if [[ "$(uname)" == "Darwin" && "$INSTALL_PREFIX" != "/usr/local" && "$INSTALL_PREFIX" != /usr/local/* ]]; then
123+
COMPILE_OPTION="$COMPILE_OPTION -DCMAKE_PREFIX_PATH=$INSTALL_PREFIX"
123124
COMPILE_OPTION="$COMPILE_OPTION -DCMAKE_NO_SYSTEM_FROM_IMPORTED=ON"
124125
COMPILE_OPTION="$COMPILE_OPTION -DCMAKE_IGNORE_PREFIX_PATH=/usr/local"
125126
COMPILE_OPTION="$COMPILE_OPTION -DCMAKE_IGNORE_PATH=/usr/local\;/usr/local/include\;/usr/local/lib\;/usr/local/lib/cmake"

ep/build-velox/src/get-velox.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,13 @@ function apply_compilation_fixes {
147147
fi
148148
$SUDO_CMD cp ${CURRENT_DIR}/modify_arrow.patch ${VELOX_HOME}/CMake/resolve_dependency_modules/arrow/
149149

150+
# Disable ARROW_TESTING in Velox's Arrow build to avoid Boost::process dependency on Linux.
151+
# On macOS, Boost from Homebrew provides Boost::process properly.
152+
if [ "$OS" == "Linux" ]; then
153+
sed -i'' -e 's/-DARROW_TESTING=ON/-DARROW_TESTING=OFF/g' ${VELOX_HOME}/CMake/resolve_dependency_modules/arrow/CMakeLists.txt
154+
sed -i'' -e '/libarrow_testing/d' ${VELOX_HOME}/CMake/resolve_dependency_modules/arrow/CMakeLists.txt
155+
fi
156+
150157
git add ${VELOX_HOME}/CMake/resolve_dependency_modules/arrow/modify_arrow.patch # to avoid the file from being deleted by git clean -dffx :/
151158
}
152159

ep/build-velox/src/setup-centos8.sh

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,16 @@ NPROC=$(getconf _NPROCESSORS_ONLN)
3636
export CFLAGS=$(get_cxx_flags $CPU_TARGET) # Used by LZO.
3737
export CXXFLAGS=$CFLAGS # Used by boost.
3838
export CPPFLAGS=$CFLAGS # Used by LZO.
39+
export INSTALL_PREFIX=${INSTALL_PREFIX:-/usr/local}
40+
EXTRA_PKG_CXXFLAGS=" -isystem ${INSTALL_PREFIX}/include"
3941
CMAKE_BUILD_TYPE="${BUILD_TYPE:-Release}"
4042
BUILD_DUCKDB="${BUILD_DUCKDB:-true}"
4143
BUILD_GEOS="${BUILD_GEOS:-true}"
42-
export CC=/opt/rh/gcc-toolset-11/root/bin/gcc
43-
export CXX=/opt/rh/gcc-toolset-11/root/bin/g++
44+
export CC=/opt/rh/gcc-toolset-12/root/bin/gcc
45+
export CXX=/opt/rh/gcc-toolset-12/root/bin/g++
4446
DEPENDENCY_DIR=${DEPENDENCY_DIR:-$(pwd)/deps-download}
4547

46-
FB_OS_VERSION="v2026.02.23.00"
48+
FB_OS_VERSION="v2026.01.05.00"
4749
FMT_VERSION="11.2.0"
4850
FAST_FLOAT_VERSION="v8.0.2"
4951
BOOST_VERSION="boost-1.84.0"
@@ -59,7 +61,7 @@ function install_build_prerequisites {
5961
dnf_install epel-release dnf-plugins-core # For ccache, ninja
6062
dnf config-manager --set-enabled powertools
6163
dnf update -y
62-
dnf_install ninja-build curl ccache gcc-toolset-11 git wget which expat-devel gettext-devel
64+
dnf_install ninja-build curl ccache gcc-toolset-12 git wget which expat-devel gettext-devel
6365
dnf_install yasm
6466
dnf_install autoconf automake python39 python39-devel python39-pip libtool
6567
pip3.9 install cmake==3.28.3
@@ -69,7 +71,8 @@ function install_build_prerequisites {
6971
function install_velox_deps_from_dnf {
7072
dnf_install libevent-devel \
7173
openssl-devel re2-devel libzstd-devel lz4-devel double-conversion-devel \
72-
libdwarf-devel curl-devel libicu-devel bison flex libsodium-devel
74+
libdwarf-devel curl-devel libicu-devel bison flex libsodium-devel \
75+
kernel-headers
7376

7477
# install sphinx for doc gen
7578
pip3.9 install sphinx sphinx-tabs breathe sphinx_rtd_theme
@@ -167,12 +170,15 @@ function install_folly {
167170

168171
function install_wangle {
169172
wget_and_untar https://github.com/facebook/wangle/archive/refs/tags/${FB_OS_VERSION}.tar.gz wangle
170-
cmake_install_dir wangle/wangle -DBUILD_TESTS=OFF
173+
cmake_install_dir wangle/wangle -DBUILD_TESTS=OFF -DBUILD_EXAMPLES=OFF
171174
}
172175

173176
function install_fbthrift {
174177
wget_and_untar https://github.com/facebook/fbthrift/archive/refs/tags/${FB_OS_VERSION}.tar.gz fbthrift
175-
cmake_install_dir fbthrift -Denable_tests=OFF -DBUILD_SHARED_LIBS=OFF -DBUILD_TESTS=OFF -DBUILD_SHARED_LIBS=OFF
178+
cd ${DEPENDENCY_DIR}/fbthrift
179+
git apply ${VELOX_HOME:-${DEPENDENCY_DIR}/../}/CMake/resolve_dependency_modules/fbthrift/compactv1-protocol-refiller.patch 2>/dev/null || true
180+
cd ${DEPENDENCY_DIR}
181+
cmake_install_dir fbthrift -Denable_tests=OFF -DBUILD_TESTS=OFF -DBUILD_SHARED_LIBS=OFF
176182
}
177183

178184
function install_mvfst {
@@ -228,7 +234,7 @@ function install_velox_deps {
228234
(
229235
if [[ $# -ne 0 ]]; then
230236
# Activate gcc11; enable errors on unset variables afterwards.
231-
source /opt/rh/gcc-toolset-11/enable || exit 1
237+
source /opt/rh/gcc-toolset-12/enable || exit 1
232238
set -u
233239
for cmd in "$@"; do
234240
run_and_time "${cmd}"
@@ -242,7 +248,7 @@ function install_velox_deps {
242248
echo "Skipping installation of build dependencies since INSTALL_PREREQUISITES is not set"
243249
fi
244250
# Activate gcc11; enable errors on unset variables afterwards.
245-
source /opt/rh/gcc-toolset-11/enable || exit 1
251+
source /opt/rh/gcc-toolset-12/enable || exit 1
246252
set -u
247253
install_velox_deps
248254
echo "All dependencies for Velox installed!"

ep/build-velox/src/setup-openeuler24.sh

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ NPROC=$(getconf _NPROCESSORS_ONLN)
3636
export CFLAGS=$(get_cxx_flags $CPU_TARGET) # Used by LZO.
3737
export CXXFLAGS=$CFLAGS # Used by boost.
3838
export CPPFLAGS=$CFLAGS # Used by LZO.
39+
EXTRA_PKG_CXXFLAGS=" -isystem ${INSTALL_PREFIX}/include"
3940
CMAKE_BUILD_TYPE="${BUILD_TYPE:-Release}"
4041
VELOX_BUILD_SHARED=${VELOX_BUILD_SHARED:-"OFF"} #Build folly and gflags shared for use in libvelox.so.
4142
BUILD_DUCKDB="${BUILD_DUCKDB:-true}"
@@ -44,8 +45,8 @@ VERSION=$(cat /etc/os-release | grep VERSION_ID)
4445
export INSTALL_PREFIX=${INSTALL_PREFIX:-"/usr/local"}
4546
DEPENDENCY_DIR=${DEPENDENCY_DIR:-$(pwd)/deps-download}
4647

47-
FB_OS_VERSION="v2026.02.23.00"
48-
FMT_VERSION="10.1.1"
48+
FB_OS_VERSION="v2026.01.05.00"
49+
FMT_VERSION="11.2.0"
4950
BOOST_VERSION="boost-1.84.0"
5051
DUCKDB_VERSION="v0.8.1"
5152
GEOS_VERSION="3.10.7"
@@ -155,11 +156,14 @@ function install_folly {
155156

156157
function install_wangle {
157158
wget_and_untar https://github.com/facebook/wangle/archive/refs/tags/${FB_OS_VERSION}.tar.gz wangle
158-
cmake_install_dir wangle/wangle -DBUILD_TESTS=OFF
159+
cmake_install_dir wangle/wangle -DBUILD_TESTS=OFF -DBUILD_EXAMPLES=OFF
159160
}
160161

161162
function install_fbthrift {
162163
wget_and_untar https://github.com/facebook/fbthrift/archive/refs/tags/${FB_OS_VERSION}.tar.gz fbthrift
164+
cd ${DEPENDENCY_DIR}/fbthrift
165+
git apply ${VELOX_HOME:-${DEPENDENCY_DIR}/../}/CMake/resolve_dependency_modules/fbthrift/compactv1-protocol-refiller.patch 2>/dev/null || true
166+
cd ${DEPENDENCY_DIR}
163167
cmake_install_dir fbthrift -Denable_tests=OFF -DBUILD_TESTS=OFF -DBUILD_SHARED_LIBS=OFF
164168
}
165169

0 commit comments

Comments
 (0)