This commit updates Boost to version 1.72.0 There are no new libraries in this release. Note: - This commit also adds a post-release patch to fix an issue with Boost.Coroutine More info about Boost 1.72.0 can be found at the usual place [1]. [1]: https://www.boost.org/users/history/version_1_72_0.html Signed-off-by: Carlos Miguel Ferreira <carlosmf.pt@gmail.com>lilik-openwrt-22.03
@ -1,71 +0,0 @@ | |||
From 83b989ecee478be083db8dc0cc7a5387615bd3cb Mon Sep 17 00:00:00 2001 | |||
From: Andrey Semashev <andrey.semashev@gmail.com> | |||
Date: Wed, 31 Jul 2019 16:28:05 +0300 | |||
Subject: [PATCH] Added support for utimensat for better POSIX.1-2008 | |||
compliance. | |||
POSIX.1-2008 marks utime as obsolete and replaces it with utimensat. | |||
uClibc-ng has an option for removing utime, including the corresponding | |||
header. | |||
Closes https://github.com/boostorg/filesystem/pull/115. | |||
--- | |||
libs/filesystem/src/operations.cpp | 24 ++++++++++++++++++++++-- | |||
1 file changed, 22 insertions(+), 2 deletions(-) | |||
diff --git a/src/operations.cpp b/src/operations.cpp | |||
index 9bba1cf7a..038109d35 100644 | |||
--- a/libs/filesystem/src/operations.cpp | |||
+++ b/libs/filesystem/src/operations.cpp | |||
@@ -62,7 +62,7 @@ | |||
#endif | |||
#ifndef _POSIX_PTHREAD_SEMANTICS | |||
-# define _POSIX_PTHREAD_SEMANTICS // Sun readdir_r()needs this | |||
+# define _POSIX_PTHREAD_SEMANTICS // Sun readdir_r() needs this | |||
#endif | |||
#include <boost/filesystem/operations.hpp> | |||
@@ -119,7 +119,9 @@ using std::wstring; | |||
# include <dirent.h> | |||
# include <unistd.h> | |||
# include <fcntl.h> | |||
-# include <utime.h> | |||
+# if _POSIX_C_SOURCE < 200809L | |||
+# include <utime.h> | |||
+# endif | |||
# include "limits.h" | |||
# else // BOOST_WINDOW_API | |||
@@ -1459,6 +1461,22 @@ namespace detail | |||
system::error_code* ec) | |||
{ | |||
# ifdef BOOST_POSIX_API | |||
+# if _POSIX_C_SOURCE >= 200809L | |||
+ | |||
+ struct timespec times[2] = {}; | |||
+ | |||
+ // Keep the last access time unchanged | |||
+ times[0].tv_nsec = UTIME_OMIT; | |||
+ | |||
+ times[1].tv_sec = new_time; | |||
+ | |||
+ if (BOOST_UNLIKELY(::utimensat(AT_FDCWD, p.c_str(), times, 0) != 0)) | |||
+ { | |||
+ error(BOOST_ERRNO, p, ec, "boost::filesystem::last_write_time"); | |||
+ return; | |||
+ } | |||
+ | |||
+# else // _POSIX_C_SOURCE >= 200809L | |||
struct stat path_stat; | |||
if (error(::stat(p.c_str(), &path_stat)!= 0, | |||
@@ -1470,6 +1488,8 @@ namespace detail | |||
error(::utime(p.c_str(), &buf)!= 0 ? BOOST_ERRNO : 0, | |||
p, ec, "boost::filesystem::last_write_time"); | |||
+# endif // _POSIX_C_SOURCE >= 200809L | |||
+ | |||
# else | |||
handle_wrapper hw( |
@ -0,0 +1,49 @@ | |||
From 436e1dbe6fcd31523d261d18ad011392f1d6fbbc Mon Sep 17 00:00:00 2001 | |||
From: Oliver Kowalke <oliver.kowalke@gmail.com> | |||
Date: Sun, 1 Dec 2019 20:40:28 +0100 | |||
Subject: [PATCH] Revert "Cease dependence on Range" | |||
This reverts commit 0c556bb59241e682bbcd3f572815149c5a9b17db. | |||
see #44 (One test fails to compile after boostorg/coroutine submodule updated) | |||
--- | |||
boost/coroutine/asymmetric_coroutine.hpp | 12 +++--------- | |||
1 file changed, 3 insertions(+), 9 deletions(-) | |||
diff --git a/boost/coroutine/asymmetric_coroutine.hpp b/boost/coroutine/asymmetric_coroutine.hpp | |||
index ea96981..640896f 100644 | |||
--- a/boost/coroutine/asymmetric_coroutine.hpp | |||
+++ b/boost/coroutine/asymmetric_coroutine.hpp | |||
@@ -14,6 +14,7 @@ | |||
#include <boost/assert.hpp> | |||
#include <boost/config.hpp> | |||
#include <boost/move/move.hpp> | |||
+#include <boost/range.hpp> | |||
#include <boost/throw_exception.hpp> | |||
#include <boost/utility/explicit_operator_bool.hpp> | |||
@@ -2354,19 +2355,12 @@ end( push_coroutine< R > & c) | |||
} | |||
-// forward declaration of Boost.Range traits to break dependency on it | |||
-template<typename C, typename Enabler> | |||
-struct range_mutable_iterator; | |||
- | |||
-template<typename C, typename Enabler> | |||
-struct range_const_iterator; | |||
- | |||
template< typename Arg > | |||
-struct range_mutable_iterator< coroutines::push_coroutine< Arg >, void > | |||
+struct range_mutable_iterator< coroutines::push_coroutine< Arg > > | |||
{ typedef typename coroutines::push_coroutine< Arg >::iterator type; }; | |||
template< typename R > | |||
-struct range_mutable_iterator< coroutines::pull_coroutine< R >, void > | |||
+struct range_mutable_iterator< coroutines::pull_coroutine< R > > | |||
{ typedef typename coroutines::pull_coroutine< R >::iterator type; }; | |||
} | |||
-- | |||
2.24.1 | |||
@ -0,0 +1,30 @@ | |||
From 5f19fd7dc6c4dd37fb0409f08a0b7dbb887dd516 Mon Sep 17 00:00:00 2001 | |||
From: Rosen Penev <rosenp@gmail.com> | |||
Date: Thu, 19 Dec 2019 17:46:46 -0800 | |||
Subject: [PATCH] roots: Fix fma_workaround | |||
fma takes three parameters, not one. | |||
Signed-off-by: Rosen Penev <rosenp@gmail.com> | |||
--- | |||
include/boost/math/tools/roots.hpp | 6 +++--- | |||
1 file changed, 3 insertions(+), 3 deletions(-) | |||
diff --git a/boost/math/tools/roots.hpp b/boost/math/tools/roots.hpp | |||
index 8b3ab7eb9..5d7936bb2 100644 | |||
--- a/boost/math/tools/roots.hpp | |||
+++ b/boost/math/tools/roots.hpp | |||
@@ -861,10 +861,10 @@ Complex complex_newton(F g, Complex guess, int max_iterations = std::numeric_lim | |||
namespace detail | |||
{ | |||
#if defined(BOOST_GNU_STDLIB) && !defined(_GLIBCXX_USE_C99_MATH_TR1) | |||
-float fma_workaround(float f) { return ::fmaf(f); } | |||
-double fma_workaround(double f) { return ::fma(f); } | |||
+inline float fma_workaround(float x, float y, float z) { return ::fmaf(x, y, z); } | |||
+inline double fma_workaround(double x, double y, double z) { return ::fma(x, y, z); } | |||
#ifndef BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS | |||
-long double fma_workaround(long double f) { return ::fmal(f); } | |||
+inline long double fma_workaround(long double x, long double y, long double z) { return ::fmal(x, y, z); } | |||
#endif | |||
#endif | |||
template<class T> |
@ -0,0 +1,17 @@ | |||
Index: boost_1_72_0/boost/math/tools/roots.hpp | |||
=================================================================== | |||
--- boost_1_72_0.orig/boost/math/tools/roots.hpp | |||
+++ boost_1_72_0/boost/math/tools/roots.hpp | |||
@@ -884,7 +884,11 @@ inline T discriminant(T const& a, T cons | |||
template<class T> | |||
std::pair<T, T> quadratic_roots_imp(T const& a, T const& b, T const& c) | |||
{ | |||
- using std::copysign; | |||
+ #if defined(BOOST_GNU_STDLIB) && !defined(_GLIBCXX_USE_C99_MATH_TR1) | |||
+ using boost::math::copysign; | |||
+ #else | |||
+ using std::copysign; | |||
+ #endif | |||
using std::sqrt; | |||
if constexpr (std::is_floating_point<T>::value) | |||
{ |