Merge pull request #9610 from Rmys/master

boost rebuild boost-build
This commit is contained in:
Rmys
2021-07-07 22:18:58 +03:00
committed by GitHub
10 changed files with 342 additions and 608 deletions
+26 -44
View File
@@ -8,51 +8,26 @@ from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import get
#WorkDir = "boost-%s" % get.srcVERSION()
def setup():
shelltools.cd("%s" % get.workDIR())
shelltools.move("boost_*", "boost-%s" % get.srcVERSION())
shelltools.cd("boost-%s" % get.srcVERSION())
shelltools.copytree("../boost-%s" % (get.srcVERSION().replace("_", "~")), "../boost-%s-38" % get.srcVERSION())
shelltools.system("./bootstrap.sh --with-toolset=gcc \
--with-icu \
--with-python=/usr/bin/python2.7 \
--with-python=python3 \
--prefix=%s/usr" % get.installDIR())
shelltools.cd("../boost-%s-38" % get.srcVERSION())
shelltools.system("./bootstrap.sh --with-toolset=gcc \
--with-icu \
--with-python=/usr/bin/python3 \
--with-libraries=python \
--prefix=%s/usr" % get.installDIR())
shelltools.system('echo "using mpi ;" >> project-config.jam')
shelltools.cd("tools/build")
shelltools.system("./bootstrap.sh --with-toolset --prefix=%s/usr" % get.installDIR())
shelltools.cd("..")
def build():
shelltools.system("./b2 \
variant=release \
debug-symbols=off \
threading=multi \
runtime-link=shared \
link=shared,static \
toolset=gcc \
python=2.7 \
cflags='-fno-strict-aliasing -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations' \
cxxflags='-fno-strict-aliasing -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations' \
--layout=system")
shelltools.cd("../boost-%s-38" % get.srcVERSION())
shelltools.system("./b2 \
shelltools.system("./b2 stage \
variant=release \
debug-symbols=off \
threading=multi \
@@ -62,21 +37,28 @@ def build():
python=3.8 \
cflags='-fno-strict-aliasing -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations' \
cxxflags='-fno-strict-aliasing -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations' \
--layout=system")
shelltools.cd("..")
--layout=system \
--with-mpi")
def install():
pisitools.dobin("b2")
pisitools.dobin("tools/build/src/engine/bjam")
shelltools.copytree("tools/boostbook/xsl", "%s/usr/share/boostbook/xsl" % get.installDIR())
shelltools.copytree("tools/boostbook/dtd", "%s/usr/share/boostbook" % get.installDIR())
shelltools.system("./b2 install threading=multi link=shared")
shelltools.cd("tools/build")
shelltools.system("./b2 install")
shelltools.cd("..")
shelltools.cd("../boost-%s-38" % get.srcVERSION())
pisitools.dobin("b2")
pisitools.dobin("tools/build/src/engine/bjam")
shelltools.copytree("tools/boostbook/xsl", "%s/usr/share/boostbook/xsl" % get.installDIR())
shelltools.copytree("tools/boostbook/dtd", "%s/usr/share/boostbook" % get.installDIR())
shelltools.system("./b2 install threading=multi link=shared")
# some packages need this library as : libboost_python3.so
pisitools.dosym("/usr/lib/libboost_python38.so.1.72.0", "/usr/lib/libboost_python3.so")
pisitools.dosym("/usr/lib/libboost_python38.so.1.75.0", "/usr/lib/libboost_python3.so")
shelltools.touch("__init__.py")
pisitools.insinto("/usr/lib/python3.8/site-packages/openmpi/boost", "__init__.py")
pisitools.domove("/usr/lib/boost-python3.8/mpi.so", "/usr/lib/python3.8/site-packages/boost/")
pisitools.removeDir("/usr/lib/boost-python3.8")
@@ -1,29 +0,0 @@
From 06ccdfee76fe487a141b95848d1c866890f15d88 Mon Sep 17 00:00:00 2001
From: Evangelos Foutras <evangelos@foutrelis.com>
Date: Thu, 6 Nov 2014 09:19:26 +0200
Subject: [PATCH] Add missing include to signals2/trackable.hpp
boost::weak_ptr started being used in commit a0bf2d1 (Disconnect slots
associated with signals2::trackable immediately) but the matching header
wasn't included.
https://svn.boost.org/trac/boost/ticket/10100#comment:7
---
include/boost/signals2/trackable.hpp | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/boost/signals2/trackable.hpp b/include/boost/signals2/trackable.hpp
index dba001d..64e8489 100644
--- a/include/boost/signals2/trackable.hpp
+++ b/include/boost/signals2/trackable.hpp
@@ -18,6 +18,7 @@
#include <boost/assert.hpp>
#include <boost/shared_ptr.hpp>
+#include <boost/weak_ptr.hpp>
namespace boost {
namespace signals2 {
--
2.1.3
+216
View File
@@ -0,0 +1,216 @@
From 5bd5bfb978df5f345518d2444d8f2ddba849d8d6 Mon Sep 17 00:00:00 2001
From: Hans Dembinski <HDembinski@users.noreply.github.com>
Date: Mon, 7 Dec 2020 15:12:20 +0100
Subject: [PATCH] Bug-fix for one-sided cropping and clarify how cropping works
(#302)
---
boost/histogram/algorithm/reduce.hpp | 28 +++++++--
libs/histogram/test/algorithm_reduce_test.cpp | 63 ++++++++++++++++----
2 files changed, 77 insertions(+), 14 deletions(-)
diff --git a/include/boost/histogram/algorithm/reduce.hpp b/include/boost/histogram/algorithm/reduce.hpp
index a5d2fffa6..0646db34e 100644
--- a/boost/histogram/algorithm/reduce.hpp
+++ b/boost/histogram/algorithm/reduce.hpp
@@ -111,7 +111,14 @@ inline reduce_command crop(unsigned iaxis, double lower, double upper) {
Command is applied to corresponding axis in order of reduce arguments.
Works like `shrink` (see shrink documentation for details), but counts in removed bins
- are discarded, whether underflow and overflow bins are present or not.
+ are discarded, whether underflow and overflow bins are present or not. If the cropped
+ range goes beyond the axis range, then the content of the underflow
+ or overflow bin which overlaps with the range is kept.
+
+ If the counts in an existing underflow or overflow bin are discared by the crop, the
+ corresponding memory cells are not physically removed. Only their contents are set to
+ zero. This technical limitation may be lifted in the future, then crop may completely
+ remove the cropped memory cells.
@param lower bin which contains lower is first to be kept.
@param upper bin which contains upper is last to be kept, except if upper is equal to
@@ -323,6 +330,8 @@ inline reduce_command slice_and_rebin(axis::index_type begin, axis::index_type e
exception. Histograms with non-reducible axes can still be reduced along the
other axes that are reducible.
+ An overload allows one to pass reduce_command as positional arguments.
+
@param hist original histogram.
@param options iterable sequence of reduce commands: `shrink`, `slice`, `rebin`,
`shrink_and_rebin`, or `slice_and_rebin`. The element type of the iterable should be
@@ -343,14 +352,16 @@ Histogram reduce(const Histogram& hist, const Iterable& options) {
auto& o = opts[iaxis];
o.is_ordered = axis::traits::ordered(a_in);
if (o.merge > 0) { // option is set?
- o.use_underflow_bin = !o.crop && AO::test(axis::option::underflow);
- o.use_overflow_bin = !o.crop && AO::test(axis::option::overflow);
+ o.use_underflow_bin = AO::test(axis::option::underflow);
+ o.use_overflow_bin = AO::test(axis::option::overflow);
return detail::static_if_c<axis::traits::is_reducible<A>::value>(
[&o](const auto& a_in) {
if (o.range == reduce_command::range_t::none) {
+ // no range restriction, pure rebin
o.begin.index = 0;
o.end.index = a_in.size();
} else {
+ // range striction, convert values to indices as needed
if (o.range == reduce_command::range_t::values) {
const auto end_value = o.end.value;
o.begin.index = axis::traits::index(a_in, o.begin.value);
@@ -359,7 +370,14 @@ Histogram reduce(const Histogram& hist, const Iterable& options) {
if (axis::traits::value_as<double>(a_in, o.end.index) != end_value)
++o.end.index;
}
- // limit [begin, end] to [0, size()]
+
+ // crop flow bins if index range does not include them
+ if (o.crop) {
+ o.use_underflow_bin &= o.begin.index < 0;
+ o.use_overflow_bin &= o.end.index > a_in.size();
+ }
+
+ // now limit [begin, end] to [0, size()]
if (o.begin.index < 0) o.begin.index = 0;
if (o.end.index > a_in.size()) o.end.index = a_in.size();
}
@@ -435,6 +453,8 @@ Histogram reduce(const Histogram& hist, const Iterable& options) {
the other axes. Trying to reducing a non-reducible axis triggers an invalid_argument
exception.
+ An overload allows one to pass an iterable of reduce_command.
+
@param hist original histogram.
@param opt first reduce command; one of `shrink`, `slice`, `rebin`,
`shrink_and_rebin`, or `slice_or_rebin`.
diff --git a/test/algorithm_reduce_test.cpp b/test/algorithm_reduce_test.cpp
index 6ea42fadf..c6b4df4a4 100644
--- a/libs/histogram/test/algorithm_reduce_test.cpp
+++ b/libs/histogram/test/algorithm_reduce_test.cpp
@@ -105,15 +105,16 @@ void run_tests() {
BOOST_TEST_EQ(reduce(h, crop(0, 1.999)).axis(), ID(0, 2));
}
+ // shrink and rebin
{
auto h = make_s(Tag(), std::vector<int>(), R(4, 1, 5, "1"), R(3, -1, 2, "2"));
/*
matrix layout:
- x
+ x ->
y 1 0 1 0
- 1 1 0 0
- 0 2 1 3
+ | 1 1 0 0
+ v 0 2 1 3
*/
h.at(0, 0) = 1;
h.at(0, 1) = 1;
@@ -122,11 +123,13 @@ void run_tests() {
h.at(2, 0) = 1;
h.at(2, 2) = 1;
h.at(3, 2) = 3;
+ h.at(-1, -1) = 1; // underflow
+ h.at(4, 3) = 1; // overflow
// should do nothing, index order does not matter
auto hr = reduce(h, shrink(1, -1, 2), rebin(0, 1));
BOOST_TEST_EQ(hr.rank(), 2);
- BOOST_TEST_EQ(sum(hr), 10);
+ BOOST_TEST_EQ(sum(hr), 12);
BOOST_TEST_EQ(hr.axis(0), R(4, 1, 5, "1"));
BOOST_TEST_EQ(hr.axis(1), R(3, -1, 2, "2"));
BOOST_TEST_EQ(hr, h);
@@ -138,7 +141,7 @@ void run_tests() {
// shrinking along first axis
hr = reduce(h, shrink(0, 2, 4));
BOOST_TEST_EQ(hr.rank(), 2);
- BOOST_TEST_EQ(sum(hr), 10);
+ BOOST_TEST_EQ(sum(hr), 12);
BOOST_TEST_EQ(hr.axis(0), R(2, 2, 4, "1"));
BOOST_TEST_EQ(hr.axis(1), R(3, -1, 2, "2"));
BOOST_TEST_EQ(hr.at(-1, 0), 1); // underflow
@@ -164,7 +167,7 @@ void run_tests() {
hr = reduce(h, shrink_and_rebin(0, 2, 5, 2), rebin(1, 3));
BOOST_TEST_EQ(hr.rank(), 2);
- BOOST_TEST_EQ(sum(hr), 10);
+ BOOST_TEST_EQ(sum(hr), 12);
BOOST_TEST_EQ(hr.axis(0), R(1, 2, 4, "1"));
BOOST_TEST_EQ(hr.axis(1), R(1, -1, 2, "2"));
BOOST_TEST_EQ(hr.at(-1, 0), 2); // underflow
@@ -184,16 +187,16 @@ void run_tests() {
BOOST_TEST_EQ(hr4, hr);
}
- // crop
+ // crop and rebin
{
auto h = make_s(Tag(), std::vector<int>(), R(4, 1, 5), R(3, 1, 4));
/*
matrix layout:
- x
+ x ->
y 1 0 1 0
- 1 1 0 0
- 0 2 1 3
+ | 1 1 0 0
+ v 0 2 1 3
*/
h.at(0, 0) = 1;
h.at(0, 1) = 1;
@@ -202,6 +205,9 @@ void run_tests() {
h.at(2, 0) = 1;
h.at(2, 2) = 1;
h.at(3, 2) = 3;
+ h.at(-1, -1) = 1; // underflow
+ h.at(4, 3) = 1; // overflow
+
/*
crop first and last column in x and y
@@ -231,6 +237,43 @@ void run_tests() {
BOOST_TEST_EQ(hr, hr4);
}
+ // one-sided crop
+ {
+ auto h = make_s(Tag(), std::vector<int>(), ID(1, 4));
+ std::fill(h.begin(), h.end(), 1);
+ // underflow: 1
+ // index 0, x 1: 1
+ // index 1, x 2: 1
+ // index 2, x 3: 1
+ // overflow: 1
+ BOOST_TEST_EQ(sum(h), 5);
+ BOOST_TEST_EQ(h.size(), 5);
+
+ // keep underflow
+ auto hr1 = reduce(h, crop(0, 3));
+ BOOST_TEST_EQ(hr1, reduce(h, slice(-1, 2, slice_mode::crop)));
+ BOOST_TEST_EQ(sum(hr1), 3);
+ BOOST_TEST_EQ(hr1.size(), 4); // flow bins are not physically removed, only zeroed
+
+ // remove underflow
+ auto hr2 = reduce(h, crop(1, 3));
+ BOOST_TEST_EQ(hr2, reduce(h, slice(0, 2, slice_mode::crop)));
+ BOOST_TEST_EQ(sum(hr2), 2);
+ BOOST_TEST_EQ(hr2.size(), 4); // flow bins are not physically removed, only zeroed
+
+ // keep overflow
+ auto hr3 = reduce(h, crop(2, 5));
+ BOOST_TEST_EQ(hr3, reduce(h, slice(1, 4, slice_mode::crop)));
+ BOOST_TEST_EQ(sum(hr3), 3);
+ BOOST_TEST_EQ(hr3.size(), 4); // flow bins are not physically removed, only zeroed
+
+ // remove overflow
+ auto hr4 = reduce(h, crop(2, 4));
+ BOOST_TEST_EQ(hr4, reduce(h, slice(1, 3, slice_mode::crop)));
+ BOOST_TEST_EQ(sum(hr4), 2);
+ BOOST_TEST_EQ(hr4.size(), 4); // flow bins are not physically removed, only zeroed
+ }
+
// mixed axis types
{
R r(5, 0.0, 5.0);
@@ -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;
@@ -0,0 +1,17 @@
From b29603fa88a614835359168e70b5a44eae8e642c Mon Sep 17 00:00:00 2001
From: Rene Rivera <grafikrobot@gmail.com>
Date: Sat, 26 Sep 2020 18:02:59 -0500
Subject: [PATCH] Fix path to bootstrap for back compat.
fixes #650
--- a/tools/build/src/engine/startup.cpp
+++ b/tools/build/src/engine/startup.cpp
@@ -195,7 +195,7 @@ bool b2::startup::bootstrap(FRAME *frame)
{
const std::string path{
b2::paths::normalize(
- b2_exe_path + "/../../share/boost-build/" + boost_build_jam)};
+ b2_exe_path + "/../../share/boost-build/src/kernel/" + boost_build_jam)};
if (b2::filesys::is_file(path))
b2_file_path = path;
}
@@ -1,354 +0,0 @@
From 150c4e94e3f6aadc84f551accdb49b6658bfb539 Mon Sep 17 00:00:00 2001
From: K-ballo <k@fusionfenix.com>
Date: Wed, 29 Apr 2015 13:11:41 -0300
Subject: [PATCH] Fix for bind<void>(mf) ambiguous resolution error
---
include/boost/bind/bind.hpp | 2 ++
include/boost/bind/bind_mf_cc.hpp | 54 ++++++++++++++++++++++++++-------------
test/bind_void_mf_test.cpp | 27 ++++++++++++++++++++
3 files changed, 65 insertions(+), 18 deletions(-)
diff --git a/include/boost/bind/bind.hpp b/include/boost/bind/bind.hpp
index 924d055..fd05131 100644
--- a/include/boost/bind/bind.hpp
+++ b/include/boost/bind/bind.hpp
@@ -29,6 +29,8 @@
#include <boost/bind/arg.hpp>
#include <boost/detail/workaround.hpp>
#include <boost/visit_each.hpp>
+#include <boost/core/enable_if.hpp>
+#include <boost/core/is_same.hpp>
// Borland-specific bug, visit_each() silently fails to produce code
diff --git a/include/boost/bind/bind_mf_cc.hpp b/include/boost/bind/bind_mf_cc.hpp
index 9c3d290..e149384 100644
--- a/include/boost/bind/bind_mf_cc.hpp
+++ b/include/boost/bind/bind_mf_cc.hpp
@@ -36,8 +36,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class A1>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf0)<R, T>, typename _bi::list_av_1<A1>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (), A1 a1)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (), A1 a1)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf0)<R, T> F;
typedef typename _bi::list_av_1<A1>::type list_type;
@@ -46,8 +47,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class A1>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf0)<R, T>, typename _bi::list_av_1<A1>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) () const, A1 a1)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) () const, A1 a1)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf0)<R, T> F;
typedef typename _bi::list_av_1<A1>::type list_type;
@@ -81,8 +83,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1,
class A1, class A2>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf1)<R, T, B1>, typename _bi::list_av_2<A1, A2>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1), A1 a1, A2 a2)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1), A1 a1, A2 a2)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf1)<R, T, B1> F;
typedef typename _bi::list_av_2<A1, A2>::type list_type;
@@ -92,8 +95,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1,
class A1, class A2>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf1)<R, T, B1>, typename _bi::list_av_2<A1, A2>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1) const, A1 a1, A2 a2)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1) const, A1 a1, A2 a2)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf1)<R, T, B1> F;
typedef typename _bi::list_av_2<A1, A2>::type list_type;
@@ -127,8 +131,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1, class B2,
class A1, class A2, class A3>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf2)<R, T, B1, B2>, typename _bi::list_av_3<A1, A2, A3>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2), A1 a1, A2 a2, A3 a3)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2), A1 a1, A2 a2, A3 a3)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf2)<R, T, B1, B2> F;
typedef typename _bi::list_av_3<A1, A2, A3>::type list_type;
@@ -138,8 +143,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1, class B2,
class A1, class A2, class A3>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf2)<R, T, B1, B2>, typename _bi::list_av_3<A1, A2, A3>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2) const, A1 a1, A2 a2, A3 a3)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2) const, A1 a1, A2 a2, A3 a3)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf2)<R, T, B1, B2> F;
typedef typename _bi::list_av_3<A1, A2, A3>::type list_type;
@@ -173,8 +179,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3,
class A1, class A2, class A3, class A4>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf3)<R, T, B1, B2, B3>, typename _bi::list_av_4<A1, A2, A3, A4>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3), A1 a1, A2 a2, A3 a3, A4 a4)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3), A1 a1, A2 a2, A3 a3, A4 a4)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf3)<R, T, B1, B2, B3> F;
typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type;
@@ -184,8 +191,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3,
class A1, class A2, class A3, class A4>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf3)<R, T, B1, B2, B3>, typename _bi::list_av_4<A1, A2, A3, A4>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3) const, A1 a1, A2 a2, A3 a3, A4 a4)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3) const, A1 a1, A2 a2, A3 a3, A4 a4)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf3)<R, T, B1, B2, B3> F;
typedef typename _bi::list_av_4<A1, A2, A3, A4>::type list_type;
@@ -219,8 +227,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4,
class A1, class A2, class A3, class A4, class A5>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf4)<R, T, B1, B2, B3, B4>, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf4)<R, T, B1, B2, B3, B4> F;
typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type;
@@ -230,8 +239,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4,
class A1, class A2, class A3, class A4, class A5>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf4)<R, T, B1, B2, B3, B4>, typename _bi::list_av_5<A1, A2, A3, A4, A5>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf4)<R, T, B1, B2, B3, B4> F;
typedef typename _bi::list_av_5<A1, A2, A3, A4, A5>::type list_type;
@@ -265,8 +275,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5,
class A1, class A2, class A3, class A4, class A5, class A6>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf5)<R, T, B1, B2, B3, B4, B5>, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf5)<R, T, B1, B2, B3, B4, B5> F;
typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type;
@@ -276,8 +287,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5,
class A1, class A2, class A3, class A4, class A5, class A6>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf5)<R, T, B1, B2, B3, B4, B5>, typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf5)<R, T, B1, B2, B3, B4, B5> F;
typedef typename _bi::list_av_6<A1, A2, A3, A4, A5, A6>::type list_type;
@@ -311,8 +323,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5, class B6,
class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf6)<R, T, B1, B2, B3, B4, B5, B6>, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf6)<R, T, B1, B2, B3, B4, B5, B6> F;
typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type;
@@ -322,8 +335,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5, class B6,
class A1, class A2, class A3, class A4, class A5, class A6, class A7>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf6)<R, T, B1, B2, B3, B4, B5, B6>, typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf6)<R, T, B1, B2, B3, B4, B5, B6> F;
typedef typename _bi::list_av_7<A1, A2, A3, A4, A5, A6, A7>::type list_type;
@@ -357,8 +371,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5, class B6, class B7,
class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf7)<R, T, B1, B2, B3, B4, B5, B6, B7>, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf7)<R, T, B1, B2, B3, B4, B5, B6, B7> F;
typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type;
@@ -368,8 +383,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5, class B6, class B7,
class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf7)<R, T, B1, B2, B3, B4, B5, B6, B7>, typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf7)<R, T, B1, B2, B3, B4, B5, B6, B7> F;
typedef typename _bi::list_av_8<A1, A2, A3, A4, A5, A6, A7, A8>::type list_type;
@@ -403,8 +419,9 @@ template<class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8,
class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(mf8)<R, T, B1, B2, B3, B4, B5, B6, B7, B8>, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8), A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9)
{
typedef _mfi::BOOST_BIND_MF_NAME(mf8)<R, T, B1, B2, B3, B4, B5, B6, B7, B8> F;
typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type;
@@ -414,8 +431,9 @@ template<class Rt2, class R, class T,
template<class Rt2, class R, class T,
class B1, class B2, class B3, class B4, class B5, class B6, class B7, class B8,
class A1, class A2, class A3, class A4, class A5, class A6, class A7, class A8, class A9>
+ typename boost::enable_if_c<!boost::core::is_same<Rt2, R>::value,
_bi::bind_t<Rt2, _mfi::BOOST_BIND_MF_NAME(cmf8)<R, T, B1, B2, B3, B4, B5, B6, B7, B8>, typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type>
- BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9)
+ >::type BOOST_BIND(R (BOOST_BIND_MF_CC T::*f) (B1, B2, B3, B4, B5, B6, B7, B8) const, A1 a1, A2 a2, A3 a3, A4 a4, A5 a5, A6 a6, A7 a7, A8 a8, A9 a9)
{
typedef _mfi::BOOST_BIND_MF_NAME(cmf8)<R, T, B1, B2, B3, B4, B5, B6, B7, B8> F;
typedef typename _bi::list_av_9<A1, A2, A3, A4, A5, A6, A7, A8, A9>::type list_type;
diff --git a/boost/libs/bind/test/bind_void_mf_test.cpp b/boost/libs/bind/test/bind_void_mf_test.cpp
index 62c2dcd..e66a9c8 100644
--- a/boost/libs/bind/test/bind_void_mf_test.cpp
+++ b/boost/libs/bind/test/bind_void_mf_test.cpp
@@ -47,30 +47,39 @@ struct X
int f0() { f1(17); return 0; }
int g0() const { g1(17); return 0; }
+ void h0() { h1(17); }
int f1(int a1) { hash = (hash * 17041 + a1) % 32768; return 0; }
int g1(int a1) const { hash = (hash * 17041 + a1 * 2) % 32768; return 0; }
+ void h1(int a1) { hash = (hash * 17041 + a1 * 2) % 32768; }
int f2(int a1, int a2) { f1(a1); f1(a2); return 0; }
int g2(int a1, int a2) const { g1(a1); g1(a2); return 0; }
+ void h2(int a1, int a2) { h1(a1); h1(a2); }
int f3(int a1, int a2, int a3) { f2(a1, a2); f1(a3); return 0; }
int g3(int a1, int a2, int a3) const { g2(a1, a2); g1(a3); return 0; }
+ void h3(int a1, int a2, int a3) { h2(a1, a2); h1(a3); }
int f4(int a1, int a2, int a3, int a4) { f3(a1, a2, a3); f1(a4); return 0; }
int g4(int a1, int a2, int a3, int a4) const { g3(a1, a2, a3); g1(a4); return 0; }
+ void h4(int a1, int a2, int a3, int a4) { h3(a1, a2, a3); h1(a4); }
int f5(int a1, int a2, int a3, int a4, int a5) { f4(a1, a2, a3, a4); f1(a5); return 0; }
int g5(int a1, int a2, int a3, int a4, int a5) const { g4(a1, a2, a3, a4); g1(a5); return 0; }
+ void h5(int a1, int a2, int a3, int a4, int a5) { h4(a1, a2, a3, a4); h1(a5); }
int f6(int a1, int a2, int a3, int a4, int a5, int a6) { f5(a1, a2, a3, a4, a5); f1(a6); return 0; }
int g6(int a1, int a2, int a3, int a4, int a5, int a6) const { g5(a1, a2, a3, a4, a5); g1(a6); return 0; }
+ void h6(int a1, int a2, int a3, int a4, int a5, int a6) { h5(a1, a2, a3, a4, a5); h1(a6); }
int f7(int a1, int a2, int a3, int a4, int a5, int a6, int a7) { f6(a1, a2, a3, a4, a5, a6); f1(a7); return 0; }
int g7(int a1, int a2, int a3, int a4, int a5, int a6, int a7) const { g6(a1, a2, a3, a4, a5, a6); g1(a7); return 0; }
+ void h7(int a1, int a2, int a3, int a4, int a5, int a6, int a7) { h6(a1, a2, a3, a4, a5, a6); h1(a7); }
int f8(int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8) { f7(a1, a2, a3, a4, a5, a6, a7); f1(a8); return 0; }
int g8(int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8) const { g7(a1, a2, a3, a4, a5, a6, a7); g1(a8); return 0; }
+ void h8(int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8) { h7(a1, a2, a3, a4, a5, a6, a7); h1(a8); }
};
void member_function_test()
@@ -88,6 +97,8 @@ void member_function_test()
bind<void>(&X::g0, x)();
bind<void>(&X::g0, ref(x))();
+ bind<void>(&X::h0, x)();
+
// 1
bind<void>(&X::f1, &x, 1)();
@@ -97,6 +108,8 @@ void member_function_test()
bind<void>(&X::g1, x, 1)();
bind<void>(&X::g1, ref(x), 1)();
+ bind<void>(&X::h1, x, 1)();
+
// 2
bind<void>(&X::f2, &x, 1, 2)();
@@ -106,6 +119,8 @@ void member_function_test()
bind<void>(&X::g2, x, 1, 2)();
bind<void>(&X::g2, ref(x), 1, 2)();
+ bind<void>(&X::h2, x, 1, 2)();
+
// 3
bind<void>(&X::f3, &x, 1, 2, 3)();
@@ -115,6 +130,8 @@ void member_function_test()
bind<void>(&X::g3, x, 1, 2, 3)();
bind<void>(&X::g3, ref(x), 1, 2, 3)();
+ bind<void>(&X::h3, x, 1, 2, 3)();
+
// 4
bind<void>(&X::f4, &x, 1, 2, 3, 4)();
@@ -124,6 +141,8 @@ void member_function_test()
bind<void>(&X::g4, x, 1, 2, 3, 4)();
bind<void>(&X::g4, ref(x), 1, 2, 3, 4)();
+ bind<void>(&X::h4, x, 1, 2, 3, 4)();
+
// 5
bind<void>(&X::f5, &x, 1, 2, 3, 4, 5)();
@@ -133,6 +152,8 @@ void member_function_test()
bind<void>(&X::g5, x, 1, 2, 3, 4, 5)();
bind<void>(&X::g5, ref(x), 1, 2, 3, 4, 5)();
+ bind<void>(&X::h5, x, 1, 2, 3, 4, 5)();
+
// 6
bind<void>(&X::f6, &x, 1, 2, 3, 4, 5, 6)();
@@ -142,6 +163,8 @@ void member_function_test()
bind<void>(&X::g6, x, 1, 2, 3, 4, 5, 6)();
bind<void>(&X::g6, ref(x), 1, 2, 3, 4, 5, 6)();
+ bind<void>(&X::h6, x, 1, 2, 3, 4, 5, 6)();
+
// 7
bind<void>(&X::f7, &x, 1, 2, 3, 4, 5, 6, 7)();
@@ -151,6 +174,8 @@ void member_function_test()
bind<void>(&X::g7, x, 1, 2, 3, 4, 5, 6, 7)();
bind<void>(&X::g7, ref(x), 1, 2, 3, 4, 5, 6, 7)();
+ bind<void>(&X::h7, x, 1, 2, 3, 4, 5, 6, 7)();
+
// 8
bind<void>(&X::f8, &x, 1, 2, 3, 4, 5, 6, 7, 8)();
@@ -160,6 +185,8 @@ void member_function_test()
bind<void>(&X::g8, x, 1, 2, 3, 4, 5, 6, 7, 8)();
bind<void>(&X::g8, ref(x), 1, 2, 3, 4, 5, 6, 7, 8)();
+ bind<void>(&X::h8, x, 1, 2, 3, 4, 5, 6, 7, 8)();
+
BOOST_TEST( x.hash == 23558 );
}
--
2.4.1
@@ -1,102 +0,0 @@
From a44c228e28d3d82137e9efe376b425013aa59f0a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bart=C5=82omiej=20Piotrowski?= <bpiotrowski@archlinux.org>
Date: Tue, 16 May 2017 15:08:59 +0200
Subject: [PATCH] Restore boost/serialization/detail/get_data.hpp
This reverts commit d558b6da917ecae1036adf9b22a0741c78f627ff.
---
include/boost/serialization/detail/get_data.hpp | 59 +++++++++++++++++++++++++
1 file changed, 59 insertions(+)
create mode 100644 include/boost/serialization/detail/get_data.hpp
diff --git a/include/boost/serialization/detail/get_data.hpp b/include/boost/serialization/detail/get_data.hpp
new file mode 100644
index 00000000..37da7fc3
--- /dev/null
+++ b/include/boost/serialization/detail/get_data.hpp
@@ -0,0 +1,59 @@
+// (C) Copyright 2005 Matthias Troyer
+// Use, modification and distribution is subject to the Boost Software
+// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+// See http://www.boost.org for updates, documentation, and revision history.
+
+#ifndef BOOST_SERIALIZATION_DETAIL_GET_DATA_HPP
+#define BOOST_SERIALIZATION_DETAIL_GET_DATA_HPP
+
+// MS compatible compilers support #pragma once
+#if defined(_MSC_VER)
+# pragma once
+#endif
+
+#if defined(__SGI_STL_PORT) || defined(_STLPORT_VERSION)
+#define STD _STLP_STD
+#else
+#define STD std
+#endif
+
+#include <vector>
+#include <valarray>
+
+namespace boost {
+namespace serialization {
+namespace detail {
+
+template <class T, class Allocator>
+T* get_data(STD::vector<T,Allocator>& v)
+{
+ return v.empty() ? 0 : &(v[0]);
+}
+
+template <class T, class Allocator>
+T* get_data(STD::vector<T,Allocator> const & v)
+{
+ return get_data(const_cast<STD::vector<T,Allocator>&>(v));
+}
+
+template <class T>
+T* get_data(STD::valarray<T>& v)
+{
+ return v.size()==0 ? 0 : &(v[0]);
+}
+
+template <class T>
+const T* get_data(STD::valarray<T> const& v)
+{
+ return get_data(const_cast<STD::valarray<T>&>(v));
+}
+
+} // detail
+} // serialization
+} // boost
+
+#undef STD
+
+#endif // BOOST_SERIALIZATION_DETAIL_GET_DATA_HPP
--
2.13.0
From 1d86261581230e2dc5d617a9b16287d326f3e229 Mon Sep 17 00:00:00 2001
From: Robert Ramey <ramey@rrsd.com>
Date: Wed, 1 Feb 2017 16:43:59 -0800
Subject: [PATCH] correct error which appeared when compiling non c++ compliant
code for arrays
---
include/boost/serialization/array.hpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/include/boost/serialization/array.hpp b/include/boost/serialization/array.hpp
index 61708b3..612d1a6 100644
--- a/include/boost/serialization/array.hpp
+++ b/include/boost/serialization/array.hpp
@@ -23,6 +23,8 @@ namespace std{
} // namespace std
#endif
+#include <boost/serialization/array_wrapper.hpp>
+
#ifndef BOOST_NO_CXX11_HDR_ARRAY
#include <array>
@@ -1,54 +0,0 @@
From a332112317450457c715675686386ec81214b863 Mon Sep 17 00:00:00 2001
From: Axel Huebl <axel.huebl@plasma.ninja>
Date: Fri, 18 Dec 2015 10:27:04 +0100
Subject: [PATCH] Fix Trac 11852: GCC & CUDA __float128
Fix trac issue
https://svn.boost.org/trac/boost/ticket/11852
Similar to
https://svn.boost.org/trac/boost/ticket/8048
`__float128` is still unsupported when compiling with nvcc
(tested with `CUDA 7.5.18`). First noticed with the latest
release (`1.60.0`) and `GCC 4.8.5` but should affect all
previous releases depending on used modules.
In my case, I triggered it with the components
`program_options regex filesystem system thread math_tr1`
enabled .
---
include/boost/config/compiler/gcc.hpp | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/include/boost/config/compiler/gcc.hpp b/include/boost/config/compiler/gcc.hpp
index d9dd59d..8683dbd 100644
--- a/include/boost/config/compiler/gcc.hpp
+++ b/include/boost/config/compiler/gcc.hpp
@@ -134,7 +134,7 @@
// Recent GCC versions have __int128 when in 64-bit mode.
//
// We disable this if the compiler is really nvcc as it
-// doesn't actually support __int128 as of CUDA_VERSION=5000
+// doesn't actually support __int128 as of CUDA_VERSION=7500
// even though it defines __SIZEOF_INT128__.
// See https://svn.boost.org/trac/boost/ticket/8048
// Only re-enable this for nvcc if you're absolutely sure
@@ -148,12 +148,16 @@
// include a std lib header to detect this - not ideal, but we'll
// be including <cstddef> later anyway when we select the std lib.
//
+// Nevertheless, as of CUDA 7.5, using __float128 with the host
+// compiler is still not supported.
+// See https://svn.boost.org/trac/boost/ticket/11852
+//
#ifdef __cplusplus
#include <cstddef>
#else
#include <stddef.h>
#endif
-#if defined(_GLIBCXX_USE_FLOAT128) && !defined(__STRICT_ANSI__)
+#if defined(_GLIBCXX_USE_FLOAT128) && !defined(__STRICT_ANSI__) && !defined(__CUDACC__)
# define BOOST_HAS_FLOAT128
#endif
@@ -1,14 +0,0 @@
diff -Nuar a/bootstrap.sh b/bootstrap.sh
--- a/bootstrap.sh 2016-12-22 15:33:11.000000000 +0300
+++ b/bootstrap.sh 2017-11-09 14:38:57.766903693 +0300
@@ -17,8 +17,8 @@
INCLUDEDIR=
LIBS=""
PYTHON=python
-PYTHON_VERSION=
-PYTHON_ROOT=
+PYTHON_VERSION=2.7
+PYTHON_ROOT=3.6
ICU_ROOT=
# Handle case where builtin shell version of echo command doesn't
+24 -11
View File
@@ -13,22 +13,25 @@
<IsA>library</IsA>
<Summary>Peer-reviewed portable C++ source libraries</Summary>
<Description>Boost provides free portable peer-reviewed C++ libraries. The emphasis is on portable libraries which work well with the C++ Standard Library.</Description>
<Archive sha1sum="6109efd3bdd8b9220d7d85b5e125f7f28721b9a9" type="tarbz2">https://dl.bintray.com/boostorg/release/1.75.0/source/boost_1_75_0.tar.bz2</Archive>
<Archive sha1sum="6109efd3bdd8b9220d7d85b5e125f7f28721b9a9" type="tarbz2">https://boostorg.jfrog.io/artifactory/main/release/1.75.0/source/boost_1_75_0.tar.bz2</Archive>
<BuildDependencies>
<Dependency>bzip2</Dependency>
<Dependency>xz-devel</Dependency>
<Dependency>zstd-devel</Dependency>
<Dependency>zlib-devel</Dependency>
<Dependency>icu4c-devel</Dependency>
<Dependency>python-devel</Dependency>
<Dependency>python3-devel</Dependency>
<!-- <Dependency>python-devel</Dependency> -->
<Dependency>python3-devel</Dependency> -->
<!-- libsxlt is needed for xsltproc -->
<Dependency>libxslt</Dependency>
<!--Dependency>openmpi-devel</Dependency-->
<Dependency>python-numpy</Dependency>
<Dependency>python3-numpy</Dependency>
<Dependency>libxslt-devel</Dependency>
<Dependency>openmpi-devel</Dependency>
<!-- <Dependency>python-numpy</Dependency> --> -->
<Dependency>python3-numpy</Dependency> -->
</BuildDependencies>
<Patches>
<!--<Patch>pythonfix.patch</Patch> -->
<Patch>a31e5cffa85f.patch</Patch>
<Patch>5bd5bfb9.patch</Patch>
<Patch>b29603fa.patch</Patch>
</Patches>
</Source>
@@ -36,15 +39,17 @@
<Name>boost</Name>
<Summary>Peer-reviewed portable C++ source libraries</Summary>
<RuntimeDependencies>
<Dependency>xz</Dependency>
<Dependency>zlib</Dependency>
<Dependency>zstd</Dependency>
<Dependency>bzip2</Dependency>
<Dependency>icu4c</Dependency>
<Dependency>libgcc</Dependency>
<!--Dependency>openmpi</Dependency-->
<Dependency>openmpi</Dependency>
</RuntimeDependencies>
<Files>
<Path fileType="data">/usr/share/boostbook</Path>
<Path fileType="data">/usr/share/boost-build</Path>
<Path fileType="executable">/usr/bin</Path>
<Path fileType="doc">/usr/share/doc</Path>
<Path fileType="library">/usr/lib</Path>
@@ -65,7 +70,7 @@
</Files>
</Package>
<Package>
<!--Package>
<Name>boost-python</Name>
<Summary>A C++ library which enables seamless interoperability between C++ and the Python</Summary>
<RuntimeDependencies>
@@ -76,7 +81,7 @@
<Path fileType="library">/usr/lib/libboost_numpy27.so*</Path>
<Path fileType="library">/usr/lib/libboost_python27.so*</Path>
</Files>
</Package>
</Package-->
<Package>
<Name>boost-python3</Name>
@@ -86,12 +91,20 @@
<Dependency>libgcc</Dependency>
</RuntimeDependencies>
<Files>
<Path fileType="library">/usr/lib/python3.8</Path>
<Path fileType="library">/usr/lib/libboost_numpy38.so*</Path>
<Path fileType="library">/usr/lib/libboost_python38.so*</Path>
</Files>
</Package>
<History>
<Update release="15">
<Date>2021-07-07</Date>
<Version>1.75.0</Version>
<Comment>Rebuild boost-build</Comment>
<Name>Mustafa Cinasal</Name>
<Email>muscnsl@gmail.com</Email>
</Update>
<Update release="14">
<Date>2021-03-10</Date>
<Version>1.75.0</Version>