Update android boost packages to 1.84.0
This commit is contained in:
parent
2abc6e91b9
commit
c77e67b04e
|
@ -3,153 +3,146 @@
|
||||||
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
||||||
# you also find the URL of a binary repository.
|
# you also find the URL of a binary repository.
|
||||||
|
|
||||||
_pkgname=boost
|
_android_arch=aarch64
|
||||||
_pkg_arch=aarch64
|
pkgname=android-${_android_arch}-boost
|
||||||
_android_arch=arm64-v8a
|
pkgver=1.84.0
|
||||||
_boost_arch=arm
|
|
||||||
_boost_address_model=64
|
|
||||||
|
|
||||||
pkgname=android-$_pkg_arch-$_pkgname
|
|
||||||
pkgver=1.81.0
|
|
||||||
_srcname=boost_${pkgver//./_}
|
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
url='https://www.boost.org/'
|
_srcname=boost_${pkgver//./_}
|
||||||
arch=('any')
|
arch=('any')
|
||||||
|
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, ${_android_arch})"
|
||||||
|
url="https://www.boost.org/"
|
||||||
license=('custom')
|
license=('custom')
|
||||||
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, $_pkg_arch)"
|
depends=("android-${_android_arch}-bzip2"
|
||||||
depends=("android-$_pkg_arch-libiconv")
|
"android-${_android_arch}-icu"
|
||||||
options=(!buildflags staticlibs !strip !emptydirs)
|
"android-${_android_arch}-zlib"
|
||||||
makedepends=('bzip2' 'zlib' 'android-ndk' 'android-sdk' 'android-environment')
|
"android-${_android_arch}-zstd")
|
||||||
conflicts=("android-$_pkgname-$_android_arch")
|
makedepends=('android-environment')
|
||||||
replaces=("android-$_pkgname-$_android_arch")
|
if [[ $_android_arch == aarch64 ]] || [[ $_android_arch == x86-64 ]]; then
|
||||||
source=(https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.gz
|
makedepends+=("android-${_android_arch}-openmpi")
|
||||||
boost-1.81.0-phoenix-multiple-definitions.patch
|
optdepends+=("android-${_android_arch}-openmpi: for mpi support")
|
||||||
$_pkgname-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch
|
fi
|
||||||
no-versioned-shlibs.patch
|
options=(!strip !buildflags staticlibs !emptydirs)
|
||||||
disable-version-check.patch)
|
source=("https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.bz2"
|
||||||
sha256sums=('205666dea9f6a7cfed87c7a6dfbeb52a2c1b9de55712c9c1a87735d7181452b6'
|
"boost-1.81.0-phoenix-multiple-definitions.patch"
|
||||||
'3ebf428ef6be090a7b56a233330375539ac429333b83708e28fe5db049cfecdb'
|
"boost-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch"
|
||||||
'aa38addb40d5f44b4a8472029b475e7e6aef1c460509eb7d8edf03491dc1b5ee'
|
"disable-version-check.patch")
|
||||||
'd82d0f15064812dcabb3456a7bcb1db0e0f6145980e4728e638372e0fd35af23'
|
md5sums=('9cbfb9076ed06384471802b850698a6d'
|
||||||
'63d12e7d703b471882608b4225c489f6a35ab425602783a4f9c4ea99a10f9c4b')
|
'cb1c25777e9b85af62366e7c930244b8'
|
||||||
|
'991daf28f76ea0383620ccaf971decba'
|
||||||
|
'6290eb4fa0cab451aac92e12e85ef073')
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
cd ${_srcname}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
# https://github.com/boostorg/phoenix/issues/111
|
# https://github.com/boostorg/phoenix/issues/111
|
||||||
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
||||||
|
|
||||||
# https://github.com/boostorg/ublas/pull/97
|
# https://github.com/boostorg/ublas/pull/97
|
||||||
patch -Np2 -i ../$_pkgname-ublas-c++20-iterator.patch
|
patch -Np2 -i ../boost-ublas-c++20-iterator.patch
|
||||||
|
|
||||||
patch -i ../no-versioned-shlibs.patch
|
|
||||||
patch -p1 -i ../disable-version-check.patch
|
patch -p1 -i ../disable-version-check.patch
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
# Platform specific patches
|
||||||
local jobs="$(sed -e 's/.*\(-j *[0-9]\+\).*/\1/' <<< ${MAKEFLAGS})"
|
case "$_android_arch" in
|
||||||
local target_flags=" \
|
aarch64)
|
||||||
--target=${_pkg_arch}-linux-android$ANDROID_MINIMUM_PLATFORM --sysroot=$ANDROID_SYSROOT"
|
_boost_arch=arm
|
||||||
local common_flags=" \
|
_boost_address_model=64
|
||||||
$target_flags \
|
;;
|
||||||
-fexceptions \
|
armv7a-eabi)
|
||||||
-DANDROID \
|
_boost_arch=arm
|
||||||
-O3 -DNDEBUG \
|
_boost_address_model=32
|
||||||
-D_FORTIFY_SOURCE=2 -O2 -pipe -fno-plt -fexceptions --param=ssp-buffer-size=4 -fPIC \
|
;;
|
||||||
-DBOOST_ASIO_HAS_STD_STRING_VIEW=1"
|
x86)
|
||||||
local ld_flags=" \
|
_boost_arch=x86
|
||||||
$target_flags \
|
_boost_address_model=32
|
||||||
-fexceptions"
|
;;
|
||||||
|
x86-64)
|
||||||
|
_boost_arch=x86
|
||||||
|
_boost_address_model=64
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
cd ${_srcname}
|
./bootstrap.sh -with-toolset=gcc
|
||||||
|
|
||||||
msg2 'Bootstrapping b2'
|
# support for OpenMPI
|
||||||
./bootstrap.sh --with-toolset=gcc
|
if [[ _boost_address_model == 64 ]]; then
|
||||||
|
_boost_mpi='using mpi ;'
|
||||||
|
else
|
||||||
|
_boost_mpi=''
|
||||||
|
fi
|
||||||
|
|
||||||
install -Dm755 tools/build/src/engine/b2 "${_stagedir}"/bin/b2
|
userConfigs=$srcdir/$_srcname/user-config.jam
|
||||||
|
|
||||||
# Support for OpenMPI
|
cat << EOF > "${userConfigs}"
|
||||||
echo "using mpi ;" >> project-config.jam
|
${_boost_mpi}
|
||||||
|
using clang : android : ${ANDROID_CXX} :
|
||||||
|
<archiver>${ANDROID_AR} \
|
||||||
|
<assembler>${ANDROID_AS}
|
||||||
|
;
|
||||||
|
EOF
|
||||||
|
|
||||||
# boostbook is needed by quickbook
|
./b2 install \
|
||||||
install -dm755 "${_stagedir}"/share/boostbook
|
--prefix="$srcdir/fakeinstall" \
|
||||||
cp -a tools/boostbook/{xsl,dtd} "${_stagedir}"/share/boostbook/
|
--user-config="${userConfigs}" \
|
||||||
|
--layout=system \
|
||||||
# default "minimal" install: "release link=shared,static
|
--with-atomic \
|
||||||
# runtime-link=shared threading=single,multi"
|
--with-chrono \
|
||||||
# --layout=tagged will add the "-mt" suffix for multithreaded libraries
|
--with-container \
|
||||||
# and installs includes in $ANDROID_PREFIX/include/boost.
|
--with-date_time \
|
||||||
# --layout=system no longer adds the -mt suffix for multi-threaded libs.
|
--with-exception \
|
||||||
# install to ${_stagedir} for consistency with regular boost package
|
--with-fiber \
|
||||||
msg2 'Invoking build via b2'
|
--with-filesystem \
|
||||||
export PATH=$ANDROID_CROSS_PREFIX:$PATH
|
--with-graph \
|
||||||
"${_stagedir}"/bin/b2 \
|
--with-graph_parallel \
|
||||||
--with-atomic \
|
--with-iostreams \
|
||||||
--with-chrono \
|
--with-locale \
|
||||||
--with-container \
|
--with-log \
|
||||||
--with-date_time \
|
--with-math \
|
||||||
--with-exception \
|
--with-mpi \
|
||||||
--with-fiber \
|
--with-program_options \
|
||||||
--with-filesystem \
|
--with-random \
|
||||||
--with-graph \
|
--with-regex \
|
||||||
--with-graph_parallel \
|
--with-serialization \
|
||||||
--with-iostreams \
|
--with-system \
|
||||||
--with-locale \
|
--with-test \
|
||||||
--with-log \
|
--with-thread \
|
||||||
--with-math \
|
--with-timer \
|
||||||
--with-mpi \
|
--with-type_erasure \
|
||||||
--with-program_options \
|
--with-wave \
|
||||||
--with-random \
|
--with-stacktrace \
|
||||||
--with-regex \
|
-sICONV_PATH="${ANDROID_PREFIX}" \
|
||||||
--with-serialization \
|
variant=release \
|
||||||
--with-system \
|
debug-symbols=off \
|
||||||
--with-test \
|
runtime-link=shared \
|
||||||
--with-thread \
|
link=shared,static \
|
||||||
--with-timer \
|
target-os=android \
|
||||||
--with-type_erasure \
|
toolset=clang-android \
|
||||||
--with-wave \
|
architecture=$_boost_arch \
|
||||||
--with-stacktrace \
|
threading=multi \
|
||||||
variant=release \
|
address-model=$_boost_address_model \
|
||||||
debug-symbols=off \
|
cflags="${CXXFLAGS}" \
|
||||||
threading=multi \
|
cxxflags="${CFLAGS}" \
|
||||||
runtime-link=shared \
|
linkflags="${LDFLAGS}"
|
||||||
link=shared,static \
|
|
||||||
target-os=android \
|
|
||||||
toolset=clang-android \
|
|
||||||
architecture=$_boost_arch \
|
|
||||||
address-model=$_boost_address_model \
|
|
||||||
-sICONV_PATH="$ANDROID_PREFIX" \
|
|
||||||
cflags="$common_flags" \
|
|
||||||
cxxflags="$common_flags -frtti -std=gnu++17" \
|
|
||||||
linkflags="$ld_flags" \
|
|
||||||
--layout=system \
|
|
||||||
${jobs} \
|
|
||||||
\
|
|
||||||
--prefix="${_stagedir}" \
|
|
||||||
install
|
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
find "${srcdir}/fakeinstall"/lib -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
find "${srcdir}/fakeinstall"/lib -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
||||||
cp -a "${_stagedir}"/{include,share} "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
local libdir="${pkgdir}$ANDROID_PREFIX"/lib
|
install -dm755 "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
install -d "${libdir}"
|
cp -a "${srcdir}/fakeinstall"/lib/*.{a,so} "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
cp -a "${_stagedir}"/lib/*.a "${libdir}"/
|
cp -a "${srcdir}/fakeinstall"/lib/cmake "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
|
cp -a "${srcdir}/fakeinstall"/include "$pkgdir/${ANDROID_PREFIX}/"
|
||||||
|
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE_1_0.txt
|
||||||
cp -a "${_stagedir}"/lib "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
install -Dm644 "${srcdir}/"${_srcname}/LICENSE_1_0.txt \
|
|
||||||
"${pkgdir}"/usr/share/licenses/$pkgname/LICENSE_1_0.txt
|
|
||||||
|
|
||||||
find "${libdir}" -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
|
||||||
find "${libdir}" -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim: ts=2 sw=2 et:
|
|
||||||
|
|
|
@ -3,153 +3,146 @@
|
||||||
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
||||||
# you also find the URL of a binary repository.
|
# you also find the URL of a binary repository.
|
||||||
|
|
||||||
_pkgname=boost
|
_android_arch=armv7a-eabi
|
||||||
_pkg_arch=armv7a-eabi
|
pkgname=android-${_android_arch}-boost
|
||||||
_android_arch=armeabi-v7a
|
pkgver=1.84.0
|
||||||
_boost_arch=arm
|
|
||||||
_boost_address_model=32
|
|
||||||
|
|
||||||
pkgname=android-$_pkg_arch-$_pkgname
|
|
||||||
pkgver=1.81.0
|
|
||||||
_srcname=boost_${pkgver//./_}
|
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
url='https://www.boost.org/'
|
_srcname=boost_${pkgver//./_}
|
||||||
arch=('any')
|
arch=('any')
|
||||||
|
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, ${_android_arch})"
|
||||||
|
url="https://www.boost.org/"
|
||||||
license=('custom')
|
license=('custom')
|
||||||
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, $_pkg_arch)"
|
depends=("android-${_android_arch}-bzip2"
|
||||||
depends=("android-$_pkg_arch-libiconv")
|
"android-${_android_arch}-icu"
|
||||||
options=(!buildflags staticlibs !strip !emptydirs)
|
"android-${_android_arch}-zlib"
|
||||||
makedepends=('bzip2' 'zlib' 'android-ndk' 'android-sdk' 'android-environment')
|
"android-${_android_arch}-zstd")
|
||||||
conflicts=("android-$_pkgname-$_android_arch")
|
makedepends=('android-environment')
|
||||||
replaces=("android-$_pkgname-$_android_arch")
|
if [[ $_android_arch == aarch64 ]] || [[ $_android_arch == x86-64 ]]; then
|
||||||
source=(https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.gz
|
makedepends+=("android-${_android_arch}-openmpi")
|
||||||
boost-1.81.0-phoenix-multiple-definitions.patch
|
optdepends+=("android-${_android_arch}-openmpi: for mpi support")
|
||||||
$_pkgname-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch
|
fi
|
||||||
no-versioned-shlibs.patch
|
options=(!strip !buildflags staticlibs !emptydirs)
|
||||||
disable-version-check.patch)
|
source=("https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.bz2"
|
||||||
sha256sums=('205666dea9f6a7cfed87c7a6dfbeb52a2c1b9de55712c9c1a87735d7181452b6'
|
"boost-1.81.0-phoenix-multiple-definitions.patch"
|
||||||
'3ebf428ef6be090a7b56a233330375539ac429333b83708e28fe5db049cfecdb'
|
"boost-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch"
|
||||||
'aa38addb40d5f44b4a8472029b475e7e6aef1c460509eb7d8edf03491dc1b5ee'
|
"disable-version-check.patch")
|
||||||
'd82d0f15064812dcabb3456a7bcb1db0e0f6145980e4728e638372e0fd35af23'
|
md5sums=('9cbfb9076ed06384471802b850698a6d'
|
||||||
'63d12e7d703b471882608b4225c489f6a35ab425602783a4f9c4ea99a10f9c4b')
|
'cb1c25777e9b85af62366e7c930244b8'
|
||||||
|
'991daf28f76ea0383620ccaf971decba'
|
||||||
|
'6290eb4fa0cab451aac92e12e85ef073')
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
cd ${_srcname}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
# https://github.com/boostorg/phoenix/issues/111
|
# https://github.com/boostorg/phoenix/issues/111
|
||||||
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
||||||
|
|
||||||
# https://github.com/boostorg/ublas/pull/97
|
# https://github.com/boostorg/ublas/pull/97
|
||||||
patch -Np2 -i ../$_pkgname-ublas-c++20-iterator.patch
|
patch -Np2 -i ../boost-ublas-c++20-iterator.patch
|
||||||
|
|
||||||
patch -i ../no-versioned-shlibs.patch
|
|
||||||
patch -p1 -i ../disable-version-check.patch
|
patch -p1 -i ../disable-version-check.patch
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
# Platform specific patches
|
||||||
local jobs="$(sed -e 's/.*\(-j *[0-9]\+\).*/\1/' <<< ${MAKEFLAGS})"
|
case "$_android_arch" in
|
||||||
local target_flags=" \
|
aarch64)
|
||||||
--target=${_pkg_arch}-linux-android$ANDROID_MINIMUM_PLATFORM --sysroot=$ANDROID_SYSROOT"
|
_boost_arch=arm
|
||||||
local common_flags=" \
|
_boost_address_model=64
|
||||||
$target_flags \
|
;;
|
||||||
-fexceptions \
|
armv7a-eabi)
|
||||||
-DANDROID \
|
_boost_arch=arm
|
||||||
-O3 -DNDEBUG \
|
_boost_address_model=32
|
||||||
-D_FORTIFY_SOURCE=2 -O2 -pipe -fno-plt -fexceptions --param=ssp-buffer-size=4 -fPIC \
|
;;
|
||||||
-DBOOST_ASIO_HAS_STD_STRING_VIEW=1"
|
x86)
|
||||||
local ld_flags=" \
|
_boost_arch=x86
|
||||||
$target_flags \
|
_boost_address_model=32
|
||||||
-fexceptions"
|
;;
|
||||||
|
x86-64)
|
||||||
|
_boost_arch=x86
|
||||||
|
_boost_address_model=64
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
cd ${_srcname}
|
./bootstrap.sh -with-toolset=gcc
|
||||||
|
|
||||||
msg2 'Bootstrapping b2'
|
# support for OpenMPI
|
||||||
./bootstrap.sh --with-toolset=gcc
|
if [[ _boost_address_model == 64 ]]; then
|
||||||
|
_boost_mpi='using mpi ;'
|
||||||
|
else
|
||||||
|
_boost_mpi=''
|
||||||
|
fi
|
||||||
|
|
||||||
install -Dm755 tools/build/src/engine/b2 "${_stagedir}"/bin/b2
|
userConfigs=$srcdir/$_srcname/user-config.jam
|
||||||
|
|
||||||
# Support for OpenMPI
|
cat << EOF > "${userConfigs}"
|
||||||
echo "using mpi ;" >> project-config.jam
|
${_boost_mpi}
|
||||||
|
using clang : android : ${ANDROID_CXX} :
|
||||||
|
<archiver>${ANDROID_AR} \
|
||||||
|
<assembler>${ANDROID_AS}
|
||||||
|
;
|
||||||
|
EOF
|
||||||
|
|
||||||
# boostbook is needed by quickbook
|
./b2 install \
|
||||||
install -dm755 "${_stagedir}"/share/boostbook
|
--prefix="$srcdir/fakeinstall" \
|
||||||
cp -a tools/boostbook/{xsl,dtd} "${_stagedir}"/share/boostbook/
|
--user-config="${userConfigs}" \
|
||||||
|
--layout=system \
|
||||||
# default "minimal" install: "release link=shared,static
|
--with-atomic \
|
||||||
# runtime-link=shared threading=single,multi"
|
--with-chrono \
|
||||||
# --layout=tagged will add the "-mt" suffix for multithreaded libraries
|
--with-container \
|
||||||
# and installs includes in $ANDROID_PREFIX/include/boost.
|
--with-date_time \
|
||||||
# --layout=system no longer adds the -mt suffix for multi-threaded libs.
|
--with-exception \
|
||||||
# install to ${_stagedir} for consistency with regular boost package
|
--with-fiber \
|
||||||
msg2 'Invoking build via b2'
|
--with-filesystem \
|
||||||
export PATH=$ANDROID_CROSS_PREFIX:$PATH
|
--with-graph \
|
||||||
"${_stagedir}"/bin/b2 \
|
--with-graph_parallel \
|
||||||
--with-atomic \
|
--with-iostreams \
|
||||||
--with-chrono \
|
--with-locale \
|
||||||
--with-container \
|
--with-log \
|
||||||
--with-date_time \
|
--with-math \
|
||||||
--with-exception \
|
--with-mpi \
|
||||||
--with-fiber \
|
--with-program_options \
|
||||||
--with-filesystem \
|
--with-random \
|
||||||
--with-graph \
|
--with-regex \
|
||||||
--with-graph_parallel \
|
--with-serialization \
|
||||||
--with-iostreams \
|
--with-system \
|
||||||
--with-locale \
|
--with-test \
|
||||||
--with-log \
|
--with-thread \
|
||||||
--with-math \
|
--with-timer \
|
||||||
--with-mpi \
|
--with-type_erasure \
|
||||||
--with-program_options \
|
--with-wave \
|
||||||
--with-random \
|
--with-stacktrace \
|
||||||
--with-regex \
|
-sICONV_PATH="${ANDROID_PREFIX}" \
|
||||||
--with-serialization \
|
variant=release \
|
||||||
--with-system \
|
debug-symbols=off \
|
||||||
--with-test \
|
runtime-link=shared \
|
||||||
--with-thread \
|
link=shared,static \
|
||||||
--with-timer \
|
target-os=android \
|
||||||
--with-type_erasure \
|
toolset=clang-android \
|
||||||
--with-wave \
|
architecture=$_boost_arch \
|
||||||
--with-stacktrace \
|
threading=multi \
|
||||||
variant=release \
|
address-model=$_boost_address_model \
|
||||||
debug-symbols=off \
|
cflags="${CXXFLAGS}" \
|
||||||
threading=multi \
|
cxxflags="${CFLAGS}" \
|
||||||
runtime-link=shared \
|
linkflags="${LDFLAGS}"
|
||||||
link=shared,static \
|
|
||||||
target-os=android \
|
|
||||||
toolset=clang-android \
|
|
||||||
architecture=$_boost_arch \
|
|
||||||
address-model=$_boost_address_model \
|
|
||||||
-sICONV_PATH="$ANDROID_PREFIX" \
|
|
||||||
cflags="$common_flags" \
|
|
||||||
cxxflags="$common_flags -frtti -std=gnu++17" \
|
|
||||||
linkflags="$ld_flags" \
|
|
||||||
--layout=system \
|
|
||||||
${jobs} \
|
|
||||||
\
|
|
||||||
--prefix="${_stagedir}" \
|
|
||||||
install
|
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
find "${srcdir}/fakeinstall"/lib -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
find "${srcdir}/fakeinstall"/lib -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
||||||
cp -a "${_stagedir}"/{include,share} "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
local libdir="${pkgdir}$ANDROID_PREFIX"/lib
|
install -dm755 "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
install -d "${libdir}"
|
cp -a "${srcdir}/fakeinstall"/lib/*.{a,so} "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
cp -a "${_stagedir}"/lib/*.a "${libdir}"/
|
cp -a "${srcdir}/fakeinstall"/lib/cmake "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
|
cp -a "${srcdir}/fakeinstall"/include "$pkgdir/${ANDROID_PREFIX}/"
|
||||||
|
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE_1_0.txt
|
||||||
cp -a "${_stagedir}"/lib "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
install -Dm644 "${srcdir}/"${_srcname}/LICENSE_1_0.txt \
|
|
||||||
"${pkgdir}"/usr/share/licenses/$pkgname/LICENSE_1_0.txt
|
|
||||||
|
|
||||||
find "${libdir}" -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
|
||||||
find "${libdir}" -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim: ts=2 sw=2 et:
|
|
||||||
|
|
|
@ -3,153 +3,146 @@
|
||||||
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
||||||
# you also find the URL of a binary repository.
|
# you also find the URL of a binary repository.
|
||||||
|
|
||||||
_pkgname=boost
|
|
||||||
_pkg_arch=x86-64
|
|
||||||
_android_arch=x86_64
|
_android_arch=x86_64
|
||||||
_boost_arch=x86
|
pkgname=android-${_android_arch}-boost
|
||||||
_boost_address_model=64
|
pkgver=1.84.0
|
||||||
|
|
||||||
pkgname=android-$_pkg_arch-$_pkgname
|
|
||||||
pkgver=1.81.0
|
|
||||||
_srcname=boost_${pkgver//./_}
|
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
url='https://www.boost.org/'
|
_srcname=boost_${pkgver//./_}
|
||||||
arch=('any')
|
arch=('any')
|
||||||
|
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, ${_android_arch})"
|
||||||
|
url="https://www.boost.org/"
|
||||||
license=('custom')
|
license=('custom')
|
||||||
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, $_pkg_arch)"
|
depends=("android-${_android_arch}-bzip2"
|
||||||
depends=("android-$_pkg_arch-libiconv")
|
"android-${_android_arch}-icu"
|
||||||
options=(!buildflags staticlibs !strip !emptydirs)
|
"android-${_android_arch}-zlib"
|
||||||
makedepends=('bzip2' 'zlib' 'android-ndk' 'android-sdk' 'android-environment')
|
"android-${_android_arch}-zstd")
|
||||||
conflicts=("android-$_pkgname-$_android_arch")
|
makedepends=('android-environment')
|
||||||
replaces=("android-$_pkgname-$_android_arch")
|
if [[ $_android_arch == aarch64 ]] || [[ $_android_arch == x86-64 ]]; then
|
||||||
source=(https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.gz
|
makedepends+=("android-${_android_arch}-openmpi")
|
||||||
boost-1.81.0-phoenix-multiple-definitions.patch
|
optdepends+=("android-${_android_arch}-openmpi: for mpi support")
|
||||||
$_pkgname-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch
|
fi
|
||||||
no-versioned-shlibs.patch
|
options=(!strip !buildflags staticlibs !emptydirs)
|
||||||
disable-version-check.patch)
|
source=("https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.bz2"
|
||||||
sha256sums=('205666dea9f6a7cfed87c7a6dfbeb52a2c1b9de55712c9c1a87735d7181452b6'
|
"boost-1.81.0-phoenix-multiple-definitions.patch"
|
||||||
'3ebf428ef6be090a7b56a233330375539ac429333b83708e28fe5db049cfecdb'
|
"boost-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch"
|
||||||
'aa38addb40d5f44b4a8472029b475e7e6aef1c460509eb7d8edf03491dc1b5ee'
|
"disable-version-check.patch")
|
||||||
'd82d0f15064812dcabb3456a7bcb1db0e0f6145980e4728e638372e0fd35af23'
|
md5sums=('9cbfb9076ed06384471802b850698a6d'
|
||||||
'63d12e7d703b471882608b4225c489f6a35ab425602783a4f9c4ea99a10f9c4b')
|
'cb1c25777e9b85af62366e7c930244b8'
|
||||||
|
'991daf28f76ea0383620ccaf971decba'
|
||||||
|
'6290eb4fa0cab451aac92e12e85ef073')
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
cd ${_srcname}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
# https://github.com/boostorg/phoenix/issues/111
|
# https://github.com/boostorg/phoenix/issues/111
|
||||||
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
||||||
|
|
||||||
# https://github.com/boostorg/ublas/pull/97
|
# https://github.com/boostorg/ublas/pull/97
|
||||||
patch -Np2 -i ../$_pkgname-ublas-c++20-iterator.patch
|
patch -Np2 -i ../boost-ublas-c++20-iterator.patch
|
||||||
|
|
||||||
patch -i ../no-versioned-shlibs.patch
|
|
||||||
patch -p1 -i ../disable-version-check.patch
|
patch -p1 -i ../disable-version-check.patch
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
# Platform specific patches
|
||||||
local jobs="$(sed -e 's/.*\(-j *[0-9]\+\).*/\1/' <<< ${MAKEFLAGS})"
|
case "$_android_arch" in
|
||||||
local target_flags=" \
|
aarch64)
|
||||||
--target=${_pkg_arch}-linux-android$ANDROID_MINIMUM_PLATFORM --sysroot=$ANDROID_SYSROOT"
|
_boost_arch=arm
|
||||||
local common_flags=" \
|
_boost_address_model=64
|
||||||
$target_flags \
|
;;
|
||||||
-fexceptions \
|
armv7a-eabi)
|
||||||
-DANDROID \
|
_boost_arch=arm
|
||||||
-O3 -DNDEBUG \
|
_boost_address_model=32
|
||||||
-D_FORTIFY_SOURCE=2 -O2 -pipe -fno-plt -fexceptions --param=ssp-buffer-size=4 -fPIC \
|
;;
|
||||||
-DBOOST_ASIO_HAS_STD_STRING_VIEW=1"
|
x86)
|
||||||
local ld_flags=" \
|
_boost_arch=x86
|
||||||
$target_flags \
|
_boost_address_model=32
|
||||||
-fexceptions"
|
;;
|
||||||
|
x86-64)
|
||||||
|
_boost_arch=x86
|
||||||
|
_boost_address_model=64
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
cd ${_srcname}
|
./bootstrap.sh -with-toolset=gcc
|
||||||
|
|
||||||
msg2 'Bootstrapping b2'
|
# support for OpenMPI
|
||||||
./bootstrap.sh --with-toolset=gcc
|
if [[ _boost_address_model == 64 ]]; then
|
||||||
|
_boost_mpi='using mpi ;'
|
||||||
|
else
|
||||||
|
_boost_mpi=''
|
||||||
|
fi
|
||||||
|
|
||||||
install -Dm755 tools/build/src/engine/b2 "${_stagedir}"/bin/b2
|
userConfigs=$srcdir/$_srcname/user-config.jam
|
||||||
|
|
||||||
# Support for OpenMPI
|
cat << EOF > "${userConfigs}"
|
||||||
echo "using mpi ;" >> project-config.jam
|
${_boost_mpi}
|
||||||
|
using clang : android : ${ANDROID_CXX} :
|
||||||
|
<archiver>${ANDROID_AR} \
|
||||||
|
<assembler>${ANDROID_AS}
|
||||||
|
;
|
||||||
|
EOF
|
||||||
|
|
||||||
# boostbook is needed by quickbook
|
./b2 install \
|
||||||
install -dm755 "${_stagedir}"/share/boostbook
|
--prefix="$srcdir/fakeinstall" \
|
||||||
cp -a tools/boostbook/{xsl,dtd} "${_stagedir}"/share/boostbook/
|
--user-config="${userConfigs}" \
|
||||||
|
--layout=system \
|
||||||
# default "minimal" install: "release link=shared,static
|
--with-atomic \
|
||||||
# runtime-link=shared threading=single,multi"
|
--with-chrono \
|
||||||
# --layout=tagged will add the "-mt" suffix for multithreaded libraries
|
--with-container \
|
||||||
# and installs includes in $ANDROID_PREFIX/include/boost.
|
--with-date_time \
|
||||||
# --layout=system no longer adds the -mt suffix for multi-threaded libs.
|
--with-exception \
|
||||||
# install to ${_stagedir} for consistency with regular boost package
|
--with-fiber \
|
||||||
msg2 'Invoking build via b2'
|
--with-filesystem \
|
||||||
export PATH=$ANDROID_CROSS_PREFIX:$PATH
|
--with-graph \
|
||||||
"${_stagedir}"/bin/b2 \
|
--with-graph_parallel \
|
||||||
--with-atomic \
|
--with-iostreams \
|
||||||
--with-chrono \
|
--with-locale \
|
||||||
--with-container \
|
--with-log \
|
||||||
--with-date_time \
|
--with-math \
|
||||||
--with-exception \
|
--with-mpi \
|
||||||
--with-fiber \
|
--with-program_options \
|
||||||
--with-filesystem \
|
--with-random \
|
||||||
--with-graph \
|
--with-regex \
|
||||||
--with-graph_parallel \
|
--with-serialization \
|
||||||
--with-iostreams \
|
--with-system \
|
||||||
--with-locale \
|
--with-test \
|
||||||
--with-log \
|
--with-thread \
|
||||||
--with-math \
|
--with-timer \
|
||||||
--with-mpi \
|
--with-type_erasure \
|
||||||
--with-program_options \
|
--with-wave \
|
||||||
--with-random \
|
--with-stacktrace \
|
||||||
--with-regex \
|
-sICONV_PATH="${ANDROID_PREFIX}" \
|
||||||
--with-serialization \
|
variant=release \
|
||||||
--with-system \
|
debug-symbols=off \
|
||||||
--with-test \
|
runtime-link=shared \
|
||||||
--with-thread \
|
link=shared,static \
|
||||||
--with-timer \
|
target-os=android \
|
||||||
--with-type_erasure \
|
toolset=clang-android \
|
||||||
--with-wave \
|
architecture=$_boost_arch \
|
||||||
--with-stacktrace \
|
threading=multi \
|
||||||
variant=release \
|
address-model=$_boost_address_model \
|
||||||
debug-symbols=off \
|
cflags="${CXXFLAGS}" \
|
||||||
threading=multi \
|
cxxflags="${CFLAGS}" \
|
||||||
runtime-link=shared \
|
linkflags="${LDFLAGS}"
|
||||||
link=shared,static \
|
|
||||||
target-os=android \
|
|
||||||
toolset=clang-android \
|
|
||||||
architecture=$_boost_arch \
|
|
||||||
address-model=$_boost_address_model \
|
|
||||||
-sICONV_PATH="$ANDROID_PREFIX" \
|
|
||||||
cflags="$common_flags" \
|
|
||||||
cxxflags="$common_flags -frtti -std=gnu++17" \
|
|
||||||
linkflags="$ld_flags" \
|
|
||||||
--layout=system \
|
|
||||||
${jobs} \
|
|
||||||
\
|
|
||||||
--prefix="${_stagedir}" \
|
|
||||||
install
|
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
find "${srcdir}/fakeinstall"/lib -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
find "${srcdir}/fakeinstall"/lib -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
||||||
cp -a "${_stagedir}"/{include,share} "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
local libdir="${pkgdir}$ANDROID_PREFIX"/lib
|
install -dm755 "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
install -d "${libdir}"
|
cp -a "${srcdir}/fakeinstall"/lib/*.{a,so} "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
cp -a "${_stagedir}"/lib/*.a "${libdir}"/
|
cp -a "${srcdir}/fakeinstall"/lib/cmake "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
|
cp -a "${srcdir}/fakeinstall"/include "$pkgdir/${ANDROID_PREFIX}/"
|
||||||
|
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE_1_0.txt
|
||||||
cp -a "${_stagedir}"/lib "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
install -Dm644 "${srcdir}/"${_srcname}/LICENSE_1_0.txt \
|
|
||||||
"${pkgdir}"/usr/share/licenses/$pkgname/LICENSE_1_0.txt
|
|
||||||
|
|
||||||
find "${libdir}" -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
|
||||||
find "${libdir}" -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim: ts=2 sw=2 et:
|
|
||||||
|
|
|
@ -3,153 +3,146 @@
|
||||||
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
||||||
# you also find the URL of a binary repository.
|
# you also find the URL of a binary repository.
|
||||||
|
|
||||||
_pkgname=boost
|
|
||||||
_pkg_arch=x86
|
|
||||||
_android_arch=x86
|
_android_arch=x86
|
||||||
_boost_arch=x86
|
pkgname=android-${_android_arch}-boost
|
||||||
_boost_address_model=32
|
pkgver=1.84.0
|
||||||
|
|
||||||
pkgname=android-$_pkg_arch-$_pkgname
|
|
||||||
pkgver=1.81.0
|
|
||||||
_srcname=boost_${pkgver//./_}
|
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
url='https://www.boost.org/'
|
_srcname=boost_${pkgver//./_}
|
||||||
arch=('any')
|
arch=('any')
|
||||||
|
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, ${_android_arch})"
|
||||||
|
url="https://www.boost.org/"
|
||||||
license=('custom')
|
license=('custom')
|
||||||
pkgdesc="Free peer-reviewed portable C++ source libraries (Android, $_pkg_arch)"
|
depends=("android-${_android_arch}-bzip2"
|
||||||
depends=("android-$_pkg_arch-libiconv")
|
"android-${_android_arch}-icu"
|
||||||
options=(!buildflags staticlibs !strip !emptydirs)
|
"android-${_android_arch}-zlib"
|
||||||
makedepends=('bzip2' 'zlib' 'android-ndk' 'android-sdk' 'android-environment')
|
"android-${_android_arch}-zstd")
|
||||||
conflicts=("android-$_pkgname-$_android_arch")
|
makedepends=('android-environment')
|
||||||
replaces=("android-$_pkgname-$_android_arch")
|
if [[ $_android_arch == aarch64 ]] || [[ $_android_arch == x86-64 ]]; then
|
||||||
source=(https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.gz
|
makedepends+=("android-${_android_arch}-openmpi")
|
||||||
boost-1.81.0-phoenix-multiple-definitions.patch
|
optdepends+=("android-${_android_arch}-openmpi: for mpi support")
|
||||||
$_pkgname-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch
|
fi
|
||||||
no-versioned-shlibs.patch
|
options=(!strip !buildflags staticlibs !emptydirs)
|
||||||
disable-version-check.patch)
|
source=("https://boostorg.jfrog.io/artifactory/main/release/$pkgver/source/$_srcname.tar.bz2"
|
||||||
sha256sums=('205666dea9f6a7cfed87c7a6dfbeb52a2c1b9de55712c9c1a87735d7181452b6'
|
"boost-1.81.0-phoenix-multiple-definitions.patch"
|
||||||
'3ebf428ef6be090a7b56a233330375539ac429333b83708e28fe5db049cfecdb'
|
"boost-ublas-c++20-iterator.patch::https://github.com/boostorg/ublas/commit/a31e5cffa85f.patch"
|
||||||
'aa38addb40d5f44b4a8472029b475e7e6aef1c460509eb7d8edf03491dc1b5ee'
|
"disable-version-check.patch")
|
||||||
'd82d0f15064812dcabb3456a7bcb1db0e0f6145980e4728e638372e0fd35af23'
|
md5sums=('9cbfb9076ed06384471802b850698a6d'
|
||||||
'63d12e7d703b471882608b4225c489f6a35ab425602783a4f9c4ea99a10f9c4b')
|
'cb1c25777e9b85af62366e7c930244b8'
|
||||||
|
'991daf28f76ea0383620ccaf971decba'
|
||||||
|
'6290eb4fa0cab451aac92e12e85ef073')
|
||||||
|
|
||||||
prepare() {
|
prepare() {
|
||||||
cd ${_srcname}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
# https://github.com/boostorg/phoenix/issues/111
|
# https://github.com/boostorg/phoenix/issues/111
|
||||||
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
patch -Np1 -i ../boost-1.81.0-phoenix-multiple-definitions.patch
|
||||||
|
|
||||||
# https://github.com/boostorg/ublas/pull/97
|
# https://github.com/boostorg/ublas/pull/97
|
||||||
patch -Np2 -i ../$_pkgname-ublas-c++20-iterator.patch
|
patch -Np2 -i ../boost-ublas-c++20-iterator.patch
|
||||||
|
|
||||||
patch -i ../no-versioned-shlibs.patch
|
|
||||||
patch -p1 -i ../disable-version-check.patch
|
patch -p1 -i ../disable-version-check.patch
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
# Platform specific patches
|
||||||
local jobs="$(sed -e 's/.*\(-j *[0-9]\+\).*/\1/' <<< ${MAKEFLAGS})"
|
case "$_android_arch" in
|
||||||
local target_flags=" \
|
aarch64)
|
||||||
--target=${_pkg_arch}-linux-android$ANDROID_MINIMUM_PLATFORM --sysroot=$ANDROID_SYSROOT"
|
_boost_arch=arm
|
||||||
local common_flags=" \
|
_boost_address_model=64
|
||||||
$target_flags \
|
;;
|
||||||
-fexceptions \
|
armv7a-eabi)
|
||||||
-DANDROID \
|
_boost_arch=arm
|
||||||
-O3 -DNDEBUG \
|
_boost_address_model=32
|
||||||
-D_FORTIFY_SOURCE=2 -O2 -pipe -fno-plt -fexceptions --param=ssp-buffer-size=4 -fPIC \
|
;;
|
||||||
-DBOOST_ASIO_HAS_STD_STRING_VIEW=1"
|
x86)
|
||||||
local ld_flags=" \
|
_boost_arch=x86
|
||||||
$target_flags \
|
_boost_address_model=32
|
||||||
-fexceptions"
|
;;
|
||||||
|
x86-64)
|
||||||
|
_boost_arch=x86
|
||||||
|
_boost_address_model=64
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
cd ${_srcname}
|
./bootstrap.sh -with-toolset=gcc
|
||||||
|
|
||||||
msg2 'Bootstrapping b2'
|
# support for OpenMPI
|
||||||
./bootstrap.sh --with-toolset=gcc
|
if [[ _boost_address_model == 64 ]]; then
|
||||||
|
_boost_mpi='using mpi ;'
|
||||||
|
else
|
||||||
|
_boost_mpi=''
|
||||||
|
fi
|
||||||
|
|
||||||
install -Dm755 tools/build/src/engine/b2 "${_stagedir}"/bin/b2
|
userConfigs=$srcdir/$_srcname/user-config.jam
|
||||||
|
|
||||||
# Support for OpenMPI
|
cat << EOF > "${userConfigs}"
|
||||||
echo "using mpi ;" >> project-config.jam
|
${_boost_mpi}
|
||||||
|
using clang : android : ${ANDROID_CXX} :
|
||||||
|
<archiver>${ANDROID_AR} \
|
||||||
|
<assembler>${ANDROID_AS}
|
||||||
|
;
|
||||||
|
EOF
|
||||||
|
|
||||||
# boostbook is needed by quickbook
|
./b2 install \
|
||||||
install -dm755 "${_stagedir}"/share/boostbook
|
--prefix="$srcdir/fakeinstall" \
|
||||||
cp -a tools/boostbook/{xsl,dtd} "${_stagedir}"/share/boostbook/
|
--user-config="${userConfigs}" \
|
||||||
|
--layout=system \
|
||||||
# default "minimal" install: "release link=shared,static
|
--with-atomic \
|
||||||
# runtime-link=shared threading=single,multi"
|
--with-chrono \
|
||||||
# --layout=tagged will add the "-mt" suffix for multithreaded libraries
|
--with-container \
|
||||||
# and installs includes in $ANDROID_PREFIX/include/boost.
|
--with-date_time \
|
||||||
# --layout=system no longer adds the -mt suffix for multi-threaded libs.
|
--with-exception \
|
||||||
# install to ${_stagedir} for consistency with regular boost package
|
--with-fiber \
|
||||||
msg2 'Invoking build via b2'
|
--with-filesystem \
|
||||||
export PATH=$ANDROID_CROSS_PREFIX:$PATH
|
--with-graph \
|
||||||
"${_stagedir}"/bin/b2 \
|
--with-graph_parallel \
|
||||||
--with-atomic \
|
--with-iostreams \
|
||||||
--with-chrono \
|
--with-locale \
|
||||||
--with-container \
|
--with-log \
|
||||||
--with-date_time \
|
--with-math \
|
||||||
--with-exception \
|
--with-mpi \
|
||||||
--with-fiber \
|
--with-program_options \
|
||||||
--with-filesystem \
|
--with-random \
|
||||||
--with-graph \
|
--with-regex \
|
||||||
--with-graph_parallel \
|
--with-serialization \
|
||||||
--with-iostreams \
|
--with-system \
|
||||||
--with-locale \
|
--with-test \
|
||||||
--with-log \
|
--with-thread \
|
||||||
--with-math \
|
--with-timer \
|
||||||
--with-mpi \
|
--with-type_erasure \
|
||||||
--with-program_options \
|
--with-wave \
|
||||||
--with-random \
|
--with-stacktrace \
|
||||||
--with-regex \
|
-sICONV_PATH="${ANDROID_PREFIX}" \
|
||||||
--with-serialization \
|
variant=release \
|
||||||
--with-system \
|
debug-symbols=off \
|
||||||
--with-test \
|
runtime-link=shared \
|
||||||
--with-thread \
|
link=shared,static \
|
||||||
--with-timer \
|
target-os=android \
|
||||||
--with-type_erasure \
|
toolset=clang-android \
|
||||||
--with-wave \
|
architecture=$_boost_arch \
|
||||||
--with-stacktrace \
|
threading=multi \
|
||||||
variant=release \
|
address-model=$_boost_address_model \
|
||||||
debug-symbols=off \
|
cflags="${CXXFLAGS}" \
|
||||||
threading=multi \
|
cxxflags="${CFLAGS}" \
|
||||||
runtime-link=shared \
|
linkflags="${LDFLAGS}"
|
||||||
link=shared,static \
|
|
||||||
target-os=android \
|
|
||||||
toolset=clang-android \
|
|
||||||
architecture=$_boost_arch \
|
|
||||||
address-model=$_boost_address_model \
|
|
||||||
-sICONV_PATH="$ANDROID_PREFIX" \
|
|
||||||
cflags="$common_flags" \
|
|
||||||
cxxflags="$common_flags -frtti -std=gnu++17" \
|
|
||||||
linkflags="$ld_flags" \
|
|
||||||
--layout=system \
|
|
||||||
${jobs} \
|
|
||||||
\
|
|
||||||
--prefix="${_stagedir}" \
|
|
||||||
install
|
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
source android-env ${_pkg_arch}
|
cd "${srcdir}/$_srcname"
|
||||||
|
source android-env ${_android_arch}
|
||||||
|
|
||||||
local _stagedir="${srcdir}/stagedir"
|
find "${srcdir}/fakeinstall"/lib -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
find "${srcdir}/fakeinstall"/lib -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
||||||
cp -a "${_stagedir}"/{include,share} "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
local libdir="${pkgdir}$ANDROID_PREFIX"/lib
|
install -dm755 "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
install -d "${libdir}"
|
cp -a "${srcdir}/fakeinstall"/lib/*.{a,so} "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
cp -a "${_stagedir}"/lib/*.a "${libdir}"/
|
cp -a "${srcdir}/fakeinstall"/lib/cmake "$pkgdir/${ANDROID_PREFIX_LIB}/"
|
||||||
|
cp -a "${srcdir}/fakeinstall"/include "$pkgdir/${ANDROID_PREFIX}/"
|
||||||
|
|
||||||
install -dm755 "${pkgdir}$ANDROID_PREFIX"
|
install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE_1_0.txt
|
||||||
cp -a "${_stagedir}"/lib "${pkgdir}$ANDROID_PREFIX"
|
|
||||||
|
|
||||||
install -Dm644 "${srcdir}/"${_srcname}/LICENSE_1_0.txt \
|
|
||||||
"${pkgdir}"/usr/share/licenses/$pkgname/LICENSE_1_0.txt
|
|
||||||
|
|
||||||
find "${libdir}" -iname '*.a' -exec $ANDROID_STRIP -g {} \;
|
|
||||||
find "${libdir}" -iname '*.so' -exec $ANDROID_STRIP --strip-unneeded {} \;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# vim: ts=2 sw=2 et:
|
|
||||||
|
|
Loading…
Reference in New Issue