Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] package/boost: bump version to 1.77.0
@ 2021-08-17 20:01 Michael Nosthoff via buildroot
  2021-08-18 10:23 ` Thomas Petazzoni
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Nosthoff via buildroot @ 2021-08-17 20:01 UTC (permalink / raw)
  To: buildroot; +Cc: Michael Nosthoff

* drop 0001-fenv.patch, issue [0] was marked fixed since boost 1.64 (commit [1])
* drop upstreamed patch 0002
* filesystem now depends on boost-atomic
* math broke the build without atomic ints, disable for now. reported at [2].

[0] https://svn.boost.org/trac/boost/ticket/11756
[1] https://github.com/boostorg/test/commit/cb2a1c2488dc77b9baf1b05781208a9639dfcd69
[2] https://github.com/boostorg/math/issues/673

Signed-off-by: Michael Nosthoff <buildroot@heine.tech>

---

compile-tested with these defconfigs:

BR2_arm=y
BR2_cortex_a15=y
BR2_ARM_FPU_NEON=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_ARMV7_EABIHF_UCLIBC_BLEEDING_EDGE=y
BR2_PACKAGE_BOOST=y
BR2_PACKAGE_BOOST_CONTRACT=y
BR2_PACKAGE_BOOST_COROUTINE=y
BR2_PACKAGE_BOOST_EXCEPTION=y
BR2_PACKAGE_BOOST_FIBER=y
BR2_PACKAGE_BOOST_GRAPH=y
BR2_PACKAGE_BOOST_GRAPH_PARALLEL=y
BR2_PACKAGE_BOOST_IOSTREAMS=y
BR2_PACKAGE_BOOST_JSON=y
BR2_PACKAGE_BOOST_LOCALE=y
BR2_PACKAGE_BOOST_LOG=y
BR2_PACKAGE_BOOST_MATH=y
BR2_PACKAGE_BOOST_MPI=y
BR2_PACKAGE_BOOST_NOWIDE=y
BR2_PACKAGE_BOOST_PROGRAM_OPTIONS=y
BR2_PACKAGE_BOOST_RANDOM=y
BR2_PACKAGE_BOOST_SERIALIZATION=y
BR2_PACKAGE_BOOST_STACKTRACE=y
BR2_PACKAGE_BOOST_TEST=y
BR2_PACKAGE_BOOST_TYPE_ERASURE=y
BR2_PACKAGE_BOOST_WAVE=y

BR2_nios2=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
BR2_PACKAGE_BOOST=y
BR2_PACKAGE_BOOST_CONTRACT=y
BR2_PACKAGE_BOOST_DATE_TIME=y
BR2_PACKAGE_BOOST_EXCEPTION=y
BR2_PACKAGE_BOOST_GRAPH=y
BR2_PACKAGE_BOOST_GRAPH_PARALLEL=y
BR2_PACKAGE_BOOST_IOSTREAMS=y
BR2_PACKAGE_BOOST_JSON=y
BR2_PACKAGE_BOOST_LOCALE=y
BR2_PACKAGE_BOOST_MPI=y
BR2_PACKAGE_BOOST_NOWIDE=y
BR2_PACKAGE_BOOST_PROGRAM_OPTIONS=y
BR2_PACKAGE_BOOST_RANDOM=y
BR2_PACKAGE_BOOST_SERIALIZATION=y
BR2_PACKAGE_BOOST_STACKTRACE=y
BR2_PACKAGE_BOOST_TEST=y

BR2_sh=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_SH_SH4_UCLIBC_STABLE=y
BR2_PACKAGE_BOOST=y
BR2_PACKAGE_BOOST_CONTRACT=y
BR2_PACKAGE_BOOST_EXCEPTION=y
BR2_PACKAGE_BOOST_GRAPH=y
BR2_PACKAGE_BOOST_GRAPH_PARALLEL=y
BR2_PACKAGE_BOOST_IOSTREAMS=y
BR2_PACKAGE_BOOST_JSON=y
BR2_PACKAGE_BOOST_LOCALE=y
BR2_PACKAGE_BOOST_LOG=y
BR2_PACKAGE_BOOST_MATH=y
BR2_PACKAGE_BOOST_MPI=y
BR2_PACKAGE_BOOST_NOWIDE=y
BR2_PACKAGE_BOOST_PROGRAM_OPTIONS=y
BR2_PACKAGE_BOOST_RANDOM=y
BR2_PACKAGE_BOOST_SERIALIZATION=y
BR2_PACKAGE_BOOST_STACKTRACE=y
BR2_PACKAGE_BOOST_TEST=y
BR2_PACKAGE_BOOST_TYPE_ERASURE=y
BR2_PACKAGE_BOOST_WAVE=y

BR2_microblazeel=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_PACKAGE_BOOST=y
BR2_PACKAGE_BOOST_CONTRACT=y
BR2_PACKAGE_BOOST_EXCEPTION=y
BR2_PACKAGE_BOOST_GRAPH=y
BR2_PACKAGE_BOOST_GRAPH_PARALLEL=y
BR2_PACKAGE_BOOST_IOSTREAMS=y
BR2_PACKAGE_BOOST_JSON=y
BR2_PACKAGE_BOOST_LOCALE=y
BR2_PACKAGE_BOOST_LOG=y
BR2_PACKAGE_BOOST_MATH=y
BR2_PACKAGE_BOOST_MPI=y
BR2_PACKAGE_BOOST_NOWIDE=y
BR2_PACKAGE_BOOST_PROGRAM_OPTIONS=y
BR2_PACKAGE_BOOST_RANDOM=y
BR2_PACKAGE_BOOST_SERIALIZATION=y
BR2_PACKAGE_BOOST_STACKTRACE=y
BR2_PACKAGE_BOOST_TEST=y
BR2_PACKAGE_BOOST_TYPE_ERASURE=y
BR2_PACKAGE_BOOST_WAVE=y

BR2_arm=y
BR2_cortex_a15=y
BR2_ARM_FPU_NEON=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y
BR2_PACKAGE_BOOST=y
BR2_PACKAGE_BOOST_FILESYSTEM=y
---
 package/boost/0001-fenv.patch                 | 37 ----------------
 ...2-src-event-cpp-fix-build-on-riscv32.patch | 42 -------------------
 package/boost/Config.in                       |  3 ++
 package/boost/boost.hash                      |  4 +-
 package/boost/boost.mk                        |  2 +-
 5 files changed, 6 insertions(+), 82 deletions(-)
 delete mode 100644 package/boost/0001-fenv.patch
 delete mode 100644 package/boost/0002-src-event-cpp-fix-build-on-riscv32.patch

diff --git a/package/boost/0001-fenv.patch b/package/boost/0001-fenv.patch
deleted file mode 100644
index 9dc7848c93..0000000000
--- a/package/boost/0001-fenv.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-Disable fenv.h in certain configurations
-
-The boost build system does not properly test whether fenv.h is
-available, and if it is, if it supports all the features used by
-Boost. This causes build failures with uClibc (reported upstream at
-https://svn.boost.org/trac/boost/ticket/11756) but also with glibc on
-specific architectures that don't have a full fenv implementation,
-such as NIOSII or Microblaze.
-
-To address this, we forcefully disable the use of fenv support in the
-affected configurations.
-
-Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
-[Thomas: add Microblaze/NIOSII exclusions.]
-Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-
-Index: b/boost/config/platform/linux.hpp
-===================================================================
---- a/boost/config/platform/linux.hpp
-+++ b/boost/config/platform/linux.hpp
-@@ -48,6 +48,16 @@
- #endif
- 
- //
-+// uClibc has no support for fenv.h, and also a few architectures
-+// don't have fenv.h support at all (or incomplete support) even with
-+// glibc.
-+
-+//
-+#if defined(__UCLIBC__) || defined(__nios2__) || defined(__microblaze__)
-+#  define BOOST_NO_FENV_H
-+#endif
-+
-+//
- // If glibc is past version 2 then we definitely have
- // gettimeofday, earlier versions may or may not have it:
- //
diff --git a/package/boost/0002-src-event-cpp-fix-build-on-riscv32.patch b/package/boost/0002-src-event-cpp-fix-build-on-riscv32.patch
deleted file mode 100644
index f1b84284ee..0000000000
--- a/package/boost/0002-src-event-cpp-fix-build-on-riscv32.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From d2061419501bdd6761e9380ed5b91233f6c4e67e Mon Sep 17 00:00:00 2001
-From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-Date: Fri, 21 May 2021 21:30:04 +0200
-Subject: [PATCH] src/event.cpp: fix build on riscv32
-
-riscv32 fails to build because __NR_futex is not defined on this
-architecture:
-
-libs/log/src/event.cpp: In member function 'void boost::log::v2_mt_posix::aux::futex_based_event::wait()':
-libs/log/src/event.cpp:38:29: error: '__NR_futex' was not declared in this scope
-   38 | #define BOOST_LOG_SYS_FUTEX __NR_futex
-      |                             ^~~~~~~~~~
-
-Fixes:
- - http://autobuild.buildroot.org/results/8c8135fd7c0517c66c9b3975c494da6d7934cc1b
-
-Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
-[Retrieved from:
-https://github.com/boostorg/log/commit/d2061419501bdd6761e9380ed5b91233f6c4e67e]
----
- src/event.cpp | 7 ++++++-
- 1 file changed, 6 insertions(+), 1 deletion(-)
-
-diff --git a/libs/log/src/event.cpp b/libs/log/src/event.cpp
-index 5485154d7..f576648c6 100644
---- a/libs/log/src/event.cpp
-+++ b/libs/log/src/event.cpp
-@@ -34,8 +34,13 @@
- // Some Android NDKs (Google NDK and older Crystax.NET NDK versions) don't define SYS_futex
- #if defined(SYS_futex)
- #define BOOST_LOG_SYS_FUTEX SYS_futex
--#else
-+#elif defined(__NR_futex)
- #define BOOST_LOG_SYS_FUTEX __NR_futex
-+// riscv32 defines a different system call instead of __NR_futex
-+#elif defined(__NR_futex_time64)
-+#define BOOST_LOG_SYS_FUTEX __NR_futex_time64
-+#else
-+#error "Unable to find a suitable futex"
- #endif
- 
- #if defined(FUTEX_WAIT_PRIVATE)
diff --git a/package/boost/Config.in b/package/boost/Config.in
index 9248c574f4..d9ce841a92 100644
--- a/package/boost/Config.in
+++ b/package/boost/Config.in
@@ -163,6 +163,8 @@ comment "boost-fiber needs a toolchain not affected by GCC bug 64735"
 
 config BR2_PACKAGE_BOOST_FILESYSTEM
 	bool "boost-filesystem"
+	depends on BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS # boost-atomic
+	select BR2_PACKAGE_BOOST_ATOMIC
 	select BR2_PACKAGE_BOOST_SYSTEM
 	help
 	  The Boost Filesystem Library provides portable facilities to
@@ -252,6 +254,7 @@ comment "boost-log needs a toolchain not affected by GCC bug 64735"
 
 config BR2_PACKAGE_BOOST_MATH
 	bool "boost-math"
+	depends on BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS
 	help
 	  Boost.Math includes several contributions in the domain of
 	  mathematics:
diff --git a/package/boost/boost.hash b/package/boost/boost.hash
index e6d44a76b6..96419506cd 100644
--- a/package/boost/boost.hash
+++ b/package/boost/boost.hash
@@ -1,5 +1,5 @@
-# From https://www.boost.org/users/history/version_1_74_0.html
-sha256  953db31e016db7bb207f11432bef7df100516eeb746843fa0486a222e3fd49cb  boost_1_75_0.tar.bz2
+# From https://www.boost.org/users/history/version_1_77_0.html
+sha256  fc9f85fc030e233142908241af7a846e60630aa7388de9a5fafb1f3a26840854  boost_1_77_0.tar.bz2
 
 # Locally computed
 sha256  c9bff75738922193e67fa726fa225535870d2aa1059f91452c411736284ad566  LICENSE_1_0.txt
diff --git a/package/boost/boost.mk b/package/boost/boost.mk
index e72ddf897c..98ec30f98f 100644
--- a/package/boost/boost.mk
+++ b/package/boost/boost.mk
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-BOOST_VERSION = 1.75.0
+BOOST_VERSION = 1.77.0
 BOOST_SOURCE = boost_$(subst .,_,$(BOOST_VERSION)).tar.bz2
 BOOST_SITE = https://boostorg.jfrog.io/artifactory/main/release/$(BOOST_VERSION)/source
 BOOST_INSTALL_STAGING = YES
-- 
2.32.0

_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [Buildroot] [PATCH] package/boost: bump version to 1.77.0
  2021-08-17 20:01 [Buildroot] [PATCH] package/boost: bump version to 1.77.0 Michael Nosthoff via buildroot
@ 2021-08-18 10:23 ` Thomas Petazzoni
  2021-08-18 20:38   ` Michael Nosthoff via buildroot
  0 siblings, 1 reply; 3+ messages in thread
From: Thomas Petazzoni @ 2021-08-18 10:23 UTC (permalink / raw)
  To: Michael Nosthoff via buildroot; +Cc: Michael Nosthoff, buildroot

Hello Michael,

On Tue, 17 Aug 2021 22:01:39 +0200
Michael Nosthoff via buildroot <buildroot@busybox.net> wrote:

>  config BR2_PACKAGE_BOOST_FILESYSTEM
>  	bool "boost-filesystem"
> +	depends on BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS # boost-atomic

Unfortunately, if you add such a dependency, you need to look at all
the place where you have a "select BR2_PACKAGE_BOOST_FILESYSTEM" or a
"select BR2_PACKAGE_BOOST_ATOMIC" and make sure they have a "depends on
BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS". And recursively,
any package selecting those packages will also need to have this
"depends on" added.

For example: package/cc-tool/Config.in selects
BR2_PACKAGE_BOOST_FILESYSTEM, so it now needs to have this depends on
BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS.

In other words, if you can get a fix for this, it would make this
version bump a lot simpler :-)

Thanks!

Thomas
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Buildroot] [PATCH] package/boost: bump version to 1.77.0
  2021-08-18 10:23 ` Thomas Petazzoni
@ 2021-08-18 20:38   ` Michael Nosthoff via buildroot
  0 siblings, 0 replies; 3+ messages in thread
From: Michael Nosthoff via buildroot @ 2021-08-18 20:38 UTC (permalink / raw)
  To: Thomas Petazzoni, Michael Nosthoff via buildroot,
	Fabrice Fontaine
  Cc: buildroot

Hi Thomas,

On 18.08.21 12:23, Thomas Petazzoni wrote:
> Hello Michael,
>
> On Tue, 17 Aug 2021 22:01:39 +0200
> Michael Nosthoff via buildroot <buildroot@busybox.net> wrote:
>
>>   config BR2_PACKAGE_BOOST_FILESYSTEM
>>   	bool "boost-filesystem"
>> +	depends on BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS # boost-atomic
> Unfortunately, if you add such a dependency, you need to look at all
> the place where you have a "select BR2_PACKAGE_BOOST_FILESYSTEM" or a
> "select BR2_PACKAGE_BOOST_ATOMIC" and make sure they have a "depends on
> BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS". And recursively,
> any package selecting those packages will also need to have this
> "depends on" added.

Damn, I forgot those dependencies. Fabrice added them for atomic and 
thread before.
It's not nice but it seems to be necessary since the dependency is now 
there.

>
> For example: package/cc-tool/Config.in selects
> BR2_PACKAGE_BOOST_FILESYSTEM, so it now needs to have this depends on
> BR2_TOOLCHAIN_SUPPORTS_ALWAYS_LOCKFREE_ATOMIC_INTS.
>
> In other words, if you can get a fix for this, it would make this
> version bump a lot simpler :-)

The culprit is this commit [1]. So if c++20 is not available it always 
falls back on boost-atomic.
 From the sheer size of the commit I don't think we can "fix" this from 
buildroot in a sensible way.

Luckily no packages depend on boost-math, where I hope this dependency 
can be fixed/removed.

Regards,
Michael

[1] 
https://github.com/boostorg/filesystem/commit/2dda038306fd2953c2bbd01a15795994fbc32af2

>
> Thanks!
>
> Thomas
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-08-18 20:38 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-08-17 20:01 [Buildroot] [PATCH] package/boost: bump version to 1.77.0 Michael Nosthoff via buildroot
2021-08-18 10:23 ` Thomas Petazzoni
2021-08-18 20:38   ` Michael Nosthoff via buildroot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox