Skip to content

Commit

Permalink
python-3.7.6: Use array for BOOST_VERSION
Browse files Browse the repository at this point in the history
Store the variants of BOOST_VERSION in an array instead of in a space
seperated string to avoid parsing it over and over.
  • Loading branch information
donald committed Mar 30, 2020
1 parent 39dc716 commit 12a32bc
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions python-3.7.6-0.build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -242,15 +242,15 @@ pip3 install --prefix=$PREFIX multiqc
#boost for pycuda
(
. ${PREFIX}/profile
BOOST_VERSION="1.72.0 1_72_0"
BOOST_SRC=https://dl.bintray.com/boostorg/release/$( echo $BOOST_VERSION | cut -d" " -f1 )/source/boost_$( echo $BOOST_VERSION | cut -d" " -f2 ).tar.gz
BOOST_VERSION=(1.72.0 1_72_0)
BOOST_SRC=https://dl.bintray.com/boostorg/release/${BOOST_VERSION[0]}/source/boost_${BOOST_VERSION[1]}.tar.gz
PKGCFLAGS="-O2 -fPIC"

cd $BUILDDIR
test -e boost_$( echo $BOOST_VERSION | cut -d" " -f2 ).tar.gz || wget $BOOST_SRC
test -d boost-$( echo $BOOST_VERSION | cut -d" " -f1 ) || mkdir boost-$( echo $BOOST_VERSION | cut -d" " -f1 ) && tar -xf boost_$( echo $BOOST_VERSION | cut -d" " -f2 ).tar.gz -C boost-$( echo $BOOST_VERSION | cut -d" " -f1 ) --strip-components=1
test -e boost_${BOOST_VERSION[1]}.tar.gz || wget $BOOST_SRC
test -d boost-${BOOST_VERSION[0]} || mkdir boost-${BOOST_VERSION[0]} && tar -xf boost_${BOOST_VERSION[1]}.tar.gz -C boost-${BOOST_VERSION[0]} --strip-components=1

cd boost-$( echo $BOOST_VERSION | cut -d" " -f1 )
cd boost-${BOOST_VERSION[0]}
sed -e "/using python/ s|;|: ${PREFIX}/include/python${PYTHONVER}m ;|" \
-i bootstrap.sh

Expand Down

0 comments on commit 12a32bc

Please sign in to comment.