boost-1.80: initial commit, version 1.80.0

This commit is contained in:
Tim Biermann 2023-01-28 21:53:23 +01:00
parent 42ddeb931a
commit dbd0c0153a
Signed by: tb
GPG Key ID: 42F8B4E30B673606
4 changed files with 17113 additions and 0 deletions

16981
boost-1.80/.footprint Normal file

File diff suppressed because it is too large Load Diff

6
boost-1.80/.signature Normal file
View File

@ -0,0 +1,6 @@
untrusted comment: verify with /etc/ports/contrib.pub
RWSagIOpLGJF397ijG9qtuNMedxkZvRFewKEbtR1eCu1yG2j8OtnR7Ni3wKWip8IDq5H+itPNxacDfy6PfypWgNytDd/S1LQMQY=
SHA256 (Pkgfile) = 33033e74b2812d164057b409527722364e4d79f834a1eadbe2911588414bf0b9
SHA256 (.footprint) = 871c0541516bb35251e87611871b0386d9575f4b6beff7bce2be1df1d59e09eb
SHA256 (boost_1_80_0.tar.bz2) = 1e19565d82e43bc59209a168f5ac899d3ba471d55c7610c677d4ccf2c9c500c0
SHA256 (boost-ublas-c++20-iterator.patch) = aa38addb40d5f44b4a8472029b475e7e6aef1c460509eb7d8edf03491dc1b5ee

67
boost-1.80/Pkgfile Normal file
View File

@ -0,0 +1,67 @@
# Description: Free peer-reviewed portable C++ source libraries.
# URL: https://www.boost.org/
# Maintainer: Danny Rawlins, crux at romster dot me
# Depends on: bzip2 zstd
# Optional: icu openmpi python3-numpy
name=boost-1.80
version=1.80.0
release=1
source=(https://boostorg.jfrog.io/artifactory/main/release/$version/source/${name/-1.80/}_${version//./_}.tar.bz2
boost-ublas-c++20-iterator.patch)
build() {
cd ${name/-1.80/}_${version//./_}
# https://github.com/boostorg/ublas/pull/97
patch -p2 -i $SRC/boost-ublas-c++20-iterator.patch
# Boost.Build does not allow for disabling of numpy
# extensions, thereby leading to automagic numpy
# https://github.com/boostorg/python/issues/111#issuecomment-280447482
prt-get isinst python3-numpy || sed \
-e 's/\[ unless \[ python\.numpy \] : <build>no \]/<build>no/g' \
-i libs/python/build/Jamfile
pushd tools/build
./bootstrap.sh --cxxflags="$CXXFLAGS $LDFLAGS"
./b2 install --prefix=$PKG/usr/opt/$name
ln -s b2 $PKG/usr/opt/$name/bin/bjam
popd
# Boost.Build does not allow for disabling of numpy
# extensions, thereby leading to automagic numpy
# https://github.com/boostorg/python/issues/111#issuecomment-280447482
prt-get isinst python3-numpy || sed \
-e 's/\[ unless \[ python\.numpy \] : <build>no \]/<build>no/g' \
-i libs/python/build/Jamfile
./bootstrap.sh --with-toolset=gcc --with-python=/usr/bin/python3
# support for OpenMPI
prt-get isinst openmpi && echo "using mpi ;" >>project-config.jam || PKGMK_BOOST+=' --without-mpi --without-graph_parallel'
prt-get isinst icu || PKGMK_BOOST+=' --disable-icu boost.locale.icu=off'
./b2 install ${PKGMK_BOOST} \
--prefix=$PKG/usr/opt/$name \
--layout=system \
--without-stacktrace \
-j ${JOBS-1} \
variant=release \
debug-symbols=off \
threading=multi \
runtime-link=shared \
link=shared,static \
toolset=gcc \
python=$(/usr/bin/python3 -c 'import sys; print("%s.%s" % sys.version_info[:2])') \
cflags="$CPPFLAGS $CFLAGS -fPIC -O3 -ffat-lto-objects" \
cxxflags="$CPPFLAGS $CXXFLAGS -fPIC -O3 -ffat-lto-objects" \
linkflags="$LDFLAGS"
prt-get isinst python3-numpy || rm -r $PKG/usr/opt/$name/include/boost/python/numpy*
prt-get isinst openmpi || rm -r $PKG//usr/opt/$name/include/boost/mpi/python*
echo "/usr/opt/$name/lib" >> $name.conf
install -Dm755 $name.conf $PKG/etc/ld.so.conf.d/$name.conf
}

View File

@ -0,0 +1,59 @@
From a31e5cffa85f58b64a39fa7c4a1bd3bd9228b069 Mon Sep 17 00:00:00 2001
From: Conrad Poelman <cpgithub@stellarscience.com>
Date: Tue, 4 Aug 2020 17:20:40 -0400
Subject: [PATCH] Remove deprecated inheritance from std::iterator (#97)
std::iterator was deprecated in C++17 and removed in C++20. I replaced the inheritance with the 5 equivalent typedefs, even though they're not all used by ublas, for compatibility in case clients depend on them.
---
.../boost/numeric/ublas/detail/iterator.hpp | 24 ++++++++++++++-----
1 file changed, 18 insertions(+), 6 deletions(-)
diff --git a/include/boost/numeric/ublas/detail/iterator.hpp b/include/boost/numeric/ublas/detail/iterator.hpp
index 1723a301c..7aebf2f9f 100644
--- a/include/boost/numeric/ublas/detail/iterator.hpp
+++ b/include/boost/numeric/ublas/detail/iterator.hpp
@@ -107,8 +107,12 @@ namespace boost { namespace numeric { namespace ublas {
* via the post increment operator.
*/
template<class IC, class I, class T>
- struct forward_iterator_base:
- public std::iterator<IC, T> {
+ struct forward_iterator_base {
+ typedef IC iterator_category;
+ typedef T value_type;
+ typedef std::ptrdiff_t difference_type;
+ typedef T* pointer;
+ typedef T& reference;
typedef I derived_iterator_type;
typedef T derived_value_type;
@@ -145,8 +149,12 @@ namespace boost { namespace numeric { namespace ublas {
* via the post increment and post decrement operator.
*/
template<class IC, class I, class T>
- struct bidirectional_iterator_base:
- public std::iterator<IC, T> {
+ struct bidirectional_iterator_base {
+ typedef IC iterator_category;
+ typedef T value_type;
+ typedef std::ptrdiff_t difference_type;
+ typedef T* pointer;
+ typedef T& reference;
typedef I derived_iterator_type;
typedef T derived_value_type;
@@ -200,8 +208,12 @@ namespace boost { namespace numeric { namespace ublas {
*/
template<class IC, class I, class T, class D = std::ptrdiff_t>
// ISSUE the default for D seems rather dangerous as it can easily be (silently) incorrect
- struct random_access_iterator_base:
- public std::iterator<IC, T> {
+ struct random_access_iterator_base {
+ typedef IC iterator_category;
+ typedef T value_type;
+ typedef D difference_type;
+ typedef T* pointer;
+ typedef T& reference;
typedef I derived_iterator_type;
typedef T derived_value_type;
typedef D derived_difference_type;