-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Roman Gershman <[email protected]>
- Loading branch information
Showing
4 changed files
with
66 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# syntax=docker/dockerfile:1 | ||
FROM fedora:30 | ||
|
||
COPY ./install_boost.sh /tmp/ | ||
|
||
RUN dnf install -y automake gcc-c++ git cmake libtool make ninja-build \ | ||
openssl-devel libunwind-devel autoconf-archive patch wget bzip2 \ | ||
openssl-static zlib-devel | ||
|
||
RUN dnf install -y bison libzstd-static --releasever=32 \ | ||
&& dnf clean all && rm -rf /var/cache/yum | ||
|
||
RUN /tmp/install_boost.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#!/bin/bash | ||
set -ex | ||
|
||
BVER=1.74.0 | ||
BOOST=boost_${BVER//./_} # replace all . with _ | ||
|
||
# For sake of boost install we always use g++. | ||
export CXX=g++ | ||
|
||
install_boost() { | ||
mkdir -p /tmp/boost && pushd /tmp/boost | ||
if ! [ -d $BOOST ]; then | ||
url="https://boostorg.jfrog.io/artifactory/main/release/${BVER}/source/$BOOST.tar.bz2" | ||
echo "Downloading from $url" | ||
if ! [ -e $BOOST.tar.bz2 ]; then wget -nv ${url} -O $BOOST.tar.bz2; fi | ||
|
||
tar -xjf $BOOST.tar.bz2 | ||
fi | ||
|
||
booststap_arg="--without-libraries=graph_parallel,graph,wave,test,mpi,python,fiber,filesystem" | ||
cd $BOOST | ||
boostrap_cmd=`readlink -f bootstrap.sh` | ||
|
||
echo "CXX compiler ${CXX}" | ||
echo "Running ${boostrap_cmd} ${booststap_arg}" | ||
${boostrap_cmd} ${booststap_arg} || { cat bootstrap.log; return 1; } | ||
b2_args=(define=BOOST_COROUTINES_NO_DEPRECATION_WARNING=1 link=static variant=release | ||
threading=multi --without-test --without-math --without-log --without-locale --without-graph --without-wave --without-mpi --without-python --without-fiber --without-filesystem --without-iostreams --without-serialization --without-chrono --without-timer --without-regex -j4) | ||
|
||
echo "Building targets with ${b2_args[@]}" | ||
./b2 "${b2_args[@]}" cxxflags='-std=c++14 -Wno-deprecated-declarations' | ||
./b2 install "${b2_args[@]}" -d0 | ||
popd | ||
rm -rf /tmp/boost | ||
} | ||
|
||
install_boost |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters