Skip to content

Commit

Permalink
Upgrade Boost to 1.84
Browse files Browse the repository at this point in the history
The boost version 1.84 fixes a bug that prevents
the addition of a group of inverse functions.
The fix was provided in Boost PR
boostorg/math#1007

The update occurs for the setup scripts for CentOS and
Ubuntu. MacOS already installs the latest available
Boost version on brew.

In addition, the requirement for the Boost version
is updated to make sure the proper version is used.
There is no known build problem when upgrading the
version.
  • Loading branch information
czentgr committed Feb 6, 2024
1 parent e8da627 commit 1a7be38
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 6 deletions.
4 changes: 2 additions & 2 deletions CMake/resolve_dependency_modules/boost/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ add_compile_options(-w)
# We need to use boost > 1.70 to build it with CMake 1.81 was the first to be
# released as a github release INCLUDING the cmake files (which are not in the
# officale releases for some reason)
set(VELOX_BOOST_BUILD_VERSION 1.81.0)
set(VELOX_BOOST_BUILD_VERSION 1.84.0)
string(
CONCAT VELOX_BOOST_SOURCE_URL
"https://github.com/boostorg/boost/releases/download/"
"boost-${VELOX_BOOST_BUILD_VERSION}/"
"boost-${VELOX_BOOST_BUILD_VERSION}.tar.gz")
set(VELOX_BOOST_BUILD_SHA256_CHECKSUM
121da556b718fd7bd700b5f2e734f8004f1cfa78b7d30145471c526ba75a151c)
4d27e9efed0f6f152dc28db6430b9d3dfb40c0345da7342eaa5a987dde57bd95)

resolve_dependency_url(BOOST)
message(STATUS "Building boost from source")
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ if(${VELOX_ENABLE_DUCKDB})
endif()

set_source(fmt)
resolve_dependency(fmt)
resolve_dependency(fmt 10.1.1)

if(NOT ${VELOX_BUILD_MINIMAL})
find_package(ZLIB REQUIRED)
Expand Down
2 changes: 1 addition & 1 deletion scripts/setup-centos8.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ function cmake_install {
wget_and_untar https://github.com/gflags/gflags/archive/v2.2.2.tar.gz gflags
wget_and_untar https://github.com/google/glog/archive/v0.6.0.tar.gz glog
wget_and_untar http://www.oberhumer.com/opensource/lzo/download/lzo-2.10.tar.gz lzo
wget_and_untar https://boostorg.jfrog.io/artifactory/main/release/1.72.0/source/boost_1_72_0.tar.gz boost
wget_and_untar https://github.com/boostorg/boost/releases/download/boost-1.84.0/boost-1.84.0.tar.gz boost
wget_and_untar https://github.com/google/snappy/archive/1.1.8.tar.gz snappy
wget_and_untar https://github.com/fmtlib/fmt/archive/10.1.1.tar.gz fmt

Expand Down
11 changes: 9 additions & 2 deletions scripts/setup-ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ NPROC=$(getconf _NPROCESSORS_ONLN)
DEPENDENCY_DIR=${DEPENDENCY_DIR:-$(pwd)}
export CMAKE_BUILD_TYPE=Release

# Install all velox and folly dependencies.
# Install all velox and folly dependencies.
# The is an issue on 22.04 where a version conflict prevents glog install,
# installing libunwind first fixes this.
apt update && apt install sudo
Expand All @@ -43,7 +43,6 @@ sudo --preserve-env apt update && sudo --preserve-env apt install -y libunwind-d
libc-ares-dev \
libcurl4-openssl-dev \
libssl-dev \
libboost-all-dev \
libicu-dev \
libdouble-conversion-dev \
libfmt-dev \
Expand Down Expand Up @@ -87,6 +86,13 @@ function prompt {
) 2> /dev/null
}

function install_boost {
wget_and_untar https://github.com/boostorg/boost/releases/download/boost-1.84.0/boost-1.84.0.tar.gz boost
cd boost
./bootstrap.sh --prefix=/usr/local
./b2 "-j$(nproc)" -d0 install threading=multi
}

function install_folly {
github_checkout facebook/folly "${FB_OS_VERSION}"
cmake_install -DBUILD_TESTS=OFF -DFOLLY_HAVE_INT128_T=ON
Expand Down Expand Up @@ -120,6 +126,7 @@ function install_conda {
}

function install_velox_deps {
run_and_time install_boost
run_and_time install_folly
run_and_time install_fizz
run_and_time install_wangle
Expand Down

0 comments on commit 1a7be38

Please sign in to comment.