Update to 1.81.1

This commit is contained in:
Liu Yuntao 2023-02-10 15:18:23 +08:00
parent 70cc0c2535
commit 91e1d35a18
8 changed files with 150 additions and 62 deletions

View File

@ -1,24 +0,0 @@
From 1dc6d74f2d673b7b82dd02ff8cdaf04b60fb5ff8 Mon Sep 17 00:00:00 2001
From: Denis Arnaud <denis.arnaud_github@m4x.org>
Date: Sun, 15 Aug 2021 17:05:31 +0200
Subject: [PATCH] Update call_method.hpp
Was missing from https://github.com/boostorg/python/pull/320
I've tested it on one of my projects with (that patch on) Boost.Python/Boost 1.76.0 and it works well. Without that patch, there is a deprecation error.
---
boost/python/call_method.hpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/boost/python/call_method.hpp b/boost/python/call_method.hpp
index 424077eab4..2f360791d7 100644
--- a/boost/python/call_method.hpp
+++ b/boost/python/call_method.hpp
@@ -59,7 +59,7 @@ call_method(PyObject* self, char const* name
)
{
PyObject* const result =
- PyEval_CallMethod(
+ PyObject_CallMethod(
self
, const_cast<char*>(name)
, const_cast<char*>("(" BOOST_PP_REPEAT_1ST(N, BOOST_PYTHON_FIXED, "O") ")")

View File

@ -1,31 +0,0 @@
From 935aa0f43bd0eab6375a9b10c8c0c886be52dc40 Mon Sep 17 00:00:00 2001
From: Liu Zixian <liuzixian4@huawei.com>
Date: Fri, 2 Dec 2022 16:05:30 +0800
Subject: [PATCH] skip gcc known issue
Signed-off-by: Liu Zixian <liuzixian4@huawei.com>
---
libs/config/test/config_test.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libs/config/test/config_test.cpp b/libs/config/test/config_test.cpp
index b04e74e14..d717e93e5 100644
--- a/libs/config/test/config_test.cpp
+++ b/libs/config/test/config_test.cpp
@@ -1381,11 +1381,13 @@ int main( int, char *[] )
std::cerr << "Failed test for BOOST_NO_CXX11_CHAR32_T at: " << __FILE__ << ":" << __LINE__ << std::endl;
++error_count;
}
+#ifndef __GNUC__
if(0 != boost_no_complete_value_initialization::test())
{
std::cerr << "Failed test for BOOST_NO_COMPLETE_VALUE_INITIALIZATION at: " << __FILE__ << ":" << __LINE__ << std::endl;
++error_count;
}
+#endif
if(0 != boost_no_cxx11_constexpr::test())
{
std::cerr << "Failed test for BOOST_NO_CXX11_CONSTEXPR at: " << __FILE__ << ":" << __LINE__ << std::endl;
--
2.36.1

View File

@ -0,0 +1,25 @@
From f58f3df2bf54fd820bd2c043e5000a7c90144804 Mon Sep 17 00:00:00 2001
From: Liu Zixian <liuzixian4@huawei.com>
Date: Thu, 15 Dec 2022 21:31:43 -0500
Subject: [PATCH] Don't run performance test in CI
---
libs/graph/test/Jamfile.v2 | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/libs/graph/test/Jamfile.v2 b/libs/graph/test/Jamfile.v2
index a0c15ca7b..c882916a7 100644
--- a/libs/graph/test/Jamfile.v2
+++ b/libs/graph/test/Jamfile.v2
@@ -47,7 +47,10 @@ alias graph_test_regular :
[ run undirected_dfs.cpp ]
[ compile dfs_cc.cpp ]
[ compile dijkstra_cc.cpp ]
- [ run dijkstra_heap_performance.cpp /boost/timer//boost_timer : 10000 ]
+
+ # Performance benchmark
+ #[ run dijkstra_heap_performance.cpp /boost/timer//boost_timer : 10000 ]
+
[ run dijkstra_no_color_map_compare.cpp : 10000 ]
[ run disjoint_set_test.cpp ]
[ run dominator_tree_test.cpp ]

View File

@ -0,0 +1,30 @@
From 4239d93dad32a11e4c3829050f8070d456266133 Mon Sep 17 00:00:00 2001
From: jzmaddock <john@johnmaddock.co.uk>
Date: Wed, 1 Jun 2022 19:35:36 +0100
Subject: [PATCH] Update multiprecision_float_test.cpp to not overflow type
double. Previously the max value for uint1024_t could just squeeze into a
double because truncation occurred during the conversion, now that cpp_int
performs correctly rounded conversions, overflow occurs, and the computation
fails. Changed the problem distribution to use a multiprecision weight type,
rather than double.
---
libs/random/test/multiprecision_float_test.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libs/random/test/multiprecision_float_test.cpp b/libs/random/test/multiprecision_float_test.cpp
index bc2a936..2b53483 100644
--- a/libs/random/test/multiprecision_float_test.cpp
+++ b/libs/random/test/multiprecision_float_test.cpp
@@ -77,7 +77,7 @@ typedef boost::mpl::list <
boost::random::lognormal_distribution<big_float>,
boost::random::normal_distribution<big_float>,
#ifndef BOOST_NO_CXX11_EXPLICIT_CONVERSION_OPERATORS
- boost::random::piecewise_constant_distribution<big_float>,
+ boost::random::piecewise_constant_distribution<big_float, big_float>,
boost::random::piecewise_linear_distribution<big_float>,
#endif
boost::random::student_t_distribution<big_float>,
--
2.33.0

View File

@ -0,0 +1,34 @@
From 7561690135c67ecf88c2133bad7680ebd2665c36 Mon Sep 17 00:00:00 2001
From: jzmaddock <john@johnmaddock.co.uk>
Date: Wed, 1 Jun 2022 19:32:55 +0100
Subject: [PATCH] Update multiprecision_int_test.cpp to not accidentality
overflow type double. Multiprecision now performs correct rounding when
converting to double - previously the max value for uint1024_t would just fit
in a double if it was truncated. But now that it's correctly rounded it
overflows and breaks the calculation.
---
libs/random/test/multiprecision_int_test.cpp | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/libs/random/test/multiprecision_int_test.cpp b/libs/random/test/multiprecision_int_test.cpp
index 41ec229..a861cca 100644
--- a/libs/random/test/multiprecision_int_test.cpp
+++ b/libs/random/test/multiprecision_int_test.cpp
@@ -215,8 +215,11 @@ BOOST_AUTO_TEST_CASE_TEMPLATE(discrete_distributions, distribution_type, other_d
distribution_type d2;
ss >> d2;
BOOST_CHECK(d == d2);
-
- boost::random::independent_bits_engine<boost::random::mt19937, std::numeric_limits<boost::multiprecision::uint1024_t>::digits, boost::multiprecision::uint1024_t > big_random;
+ //
+ // The number of digits in the independent_bits_engine must be low enough that we don't overflow
+ // when converting to a double (see other_distributions declared above).
+ //
+ boost::random::independent_bits_engine<boost::random::mt19937, std::numeric_limits<boost::multiprecision::uint1024_t>::digits - 2, boost::multiprecision::uint1024_t > big_random;
for(unsigned i = 0; i < 200; ++i)
{
result_type r = d(big_random);
--
2.33.0

View File

@ -0,0 +1,37 @@
From c3ada7a1b2b54f4b27585f72308a76984f8489b4 Mon Sep 17 00:00:00 2001
From: jzmaddock <john@johnmaddock.co.uk>
Date: Tue, 16 Mar 2021 10:47:16 +0000
Subject: [PATCH] Add missing #includes.
---
test/multiprecision_float_test.cpp | 1 +
test/multiprecision_int_test.cpp | 1 +
2 files changed, 2 insertions(+)
diff --git a/libs/random/test/multiprecision_float_test.cpp b/libs/random/test/multiprecision_float_test.cpp
index 904c59d..bc2a936 100644
--- a/libs/random/test/multiprecision_float_test.cpp
+++ b/libs/random/test/multiprecision_float_test.cpp
@@ -20,6 +20,7 @@
#include <boost/multiprecision/debug_adaptor.hpp>
#include <boost/scoped_ptr.hpp>
#include <boost/random.hpp>
+#include <boost/mpl/list.hpp>
#include <sstream>
diff --git a/libs/random/test/multiprecision_int_test.cpp b/libs/random/test/multiprecision_int_test.cpp
index 577e52a..41ec229 100644
--- a/libs/random/test/multiprecision_int_test.cpp
+++ b/libs/random/test/multiprecision_int_test.cpp
@@ -32,6 +32,7 @@
#include <boost/random/uniform_int.hpp>
#include <boost/random/uniform_smallint.hpp>
#include <boost/random/discrete_distribution.hpp>
+#include <boost/mpl/list.hpp>
#include <sstream>
typedef boost::mpl::list <
--
2.33.0

View File

@ -1,8 +1,8 @@
%global version_enc 1_80_0
%global version_enc 1_81_0
Name: boost
Version: 1.80.0
Release: 5
Version: 1.81.0
Release: 1
Summary: The free peer-reviewed portable C++ source libraries
License: BSL-1.0
URL: http://www.boost.org
@ -10,11 +10,14 @@ Source0: https://boostorg.jfrog.io/ui/native/main/release/%{version}/sour
# These following patches have been merged into boost develop branch
# Remove them at the next release
# https://github.com/boostorg/python/pull/373
Patch0: boost-1.78-python-Update-call_method-hpp.patch
# https://github.com/ned14/outcome/commit/66ebdd4e86ab593c8723ee69f6654260de19775e
Patch1: boost-1.80-outcome-Stop-Boost-regression-tests-complaining-about-no-test-tree.patch
Patch9000: boost-1.80-config-skip-gcc-known-issue.patch
# https://github.com/boostorg/graph/pull/318
Patch2: boost-1.81-graph-Dont-run-performance-test-in-CI.patch
# https://github.com/boostorg/random/pull/83
Patch3: boost-1.81-random-Update-multiprecision_float_test.cpp-to-not-overflow.patch
Patch4: boost-1.81-random-Update-multiprecision_int_test.cpp-to-not-accidental.patch
Patch5: boost-1.81-random-test-Add-missing-includes.patch
Requires: %{name}-atomic%{?_isa} = %{version}-%{release}
Requires: %{name}-chrono%{?_isa} = %{version}-%{release}
@ -43,6 +46,7 @@ Requires: %{name}-test%{?_isa} = %{version}-%{release}
Requires: %{name}-thread%{?_isa} = %{version}-%{release}
Requires: %{name}-timer%{?_isa} = %{version}-%{release}
Requires: %{name}-type_erasure%{?_isa} = %{version}-%{release}
Requires: %{name}-url%{?_isa} = %{version}-%{release}
Requires: %{name}-wave%{?_isa} = %{version}-%{release}
BuildRequires: gcc-c++
@ -236,6 +240,12 @@ Requires: boost-chrono%{?_isa} = %{version}-%{release}
%description type_erasure
Runtime polymorphism based on concepts.
%package url
Summary: Run-time component for boost url.
%description url
A library for parsing, modifying, and printing URLs using only C++11.
%package wave
Summary: Run-time component for boost wave.
Requires: boost-chrono%{?_isa} = %{version}-%{release}
@ -290,7 +300,7 @@ as that on the Boost web page (http://www.boost.org/doc/libs/%{version_enc}).
mkdir boost-doc boost-example
cp -r index.html boost.png rst.css boost.css doc more boost-doc
find libs -name doc -exec cp {} boost-doc --parents \;
find libs -name doc -exec cp {} boost-doc --parents -r \;
find libs -name example -exec cp {} boost-example --parents -r \;
%files
@ -415,6 +425,10 @@ find libs -name example -exec cp {} boost-example --parents -r \;
%license LICENSE_1_0.txt
%{_libdir}/libboost_type_erasure.so.%{version}
%files url
%license LICENSE_1_0.txt
%{_libdir}/libboost_url.so.%{version}
%files wave
%license LICENSE_1_0.txt
%{_libdir}/libboost_wave.so.%{version}
@ -430,6 +444,9 @@ find libs -name example -exec cp {} boost-example --parents -r \;
%{_libdir}/*.a
%changelog
* Mon Dec 19 2022 Liu Zixian <liuzixian4@huawei.com> - 1.81.0-1
- Update to 1.81.0
* Thu Dec 08 2022 Liu Zixian <liuzixian4@huawei.com> - 1.80.0-5
- statechart: avoid undefined behavior