Ports: Update boost to 1.92.0

This commit is contained in:
Linus Groh authored and Lucas Chollet committed 2026-09-23 21:08:37 +02:00
1 parent abd41e812d
commit 34f10a00a8
7 files changed
+61 -113

No files matched your search

+1 -1
View File
@@ -22,7 +22,7 @@ This list is also available at [ports.serenityos.net](https://ports.serenityos.n
| [`binutils`](binutils/) | GNU Binutils | 2.46.0 | https://www.gnu.org/software/binutils/ |
| [`bison`](bison/) | GNU Bison | 3.8.2 | https://www.gnu.org/software/bison/ |
| [`bochs`](bochs/) | Bochs x86 PC emulator | 3.1 | https://sourceforge.net/projects/bochs/ |
| [`boost`](boost/) | Boost C++ libraries | 1.83.0 | https://www.boost.org/ |
| [`boost`](boost/) | Boost C++ libraries | 1.92.0 | https://www.boost.org/ |
| [`brogue`](brogue/) | BrogueCE | 1.15.1 | https://github.com/tmewett/BrogueCE |
| [`brotli`](brotli/) | Brotli | 1.2.0 | https://github.com/google/brotli |
| [`byacc`](byacc/) | Berkeley Yacc | 20260126 | https://invisible-island.net/byacc/byacc.html |
+11 -16
View File
@@ -1,6 +1,6 @@
#!/usr/bin/env -S bash ../.port_include.sh
port='boost'
version='1.83.0'
version='1.92.0'
useconfigure='true'
depends=(
'zlib'
@@ -10,26 +10,21 @@ depends=(
'libicu'
)
files=(
"https://github.com/boostorg/boost/releases/download/boost-${version}/boost-${version}.tar.gz#0c6049764e80aa32754acd7d4f179fd5551d8172a83b71532ae093e7384e98da"
"https://github.com/boostorg/boost/releases/download/boost-${version}/boost-${version}-cmake.tar.gz#f51707c27359a0df0cac1beada86de31bb5eed5e8285592dadec384df99c2984"
)
bjamopts=(
'--user-config=user-config.jam'
'toolset=gcc'
'target-os=serenity'
configopts=(
"-DCMAKE_TOOLCHAIN_FILE=${SERENITY_BUILD_DIR}/CMakeToolchain.txt"
'-DBOOST_ENABLE_MPI=OFF'
'-DBOOST_ENABLE_PYTHON=OFF'
# boost_stacktrace_from_exception uses dlsym(RTLD_NEXT, ...), which we don't have.
'-DBOOST_STACKTRACE_ENABLE_FROM_EXCEPTION=OFF'
'-DBUILD_TESTING=OFF'
)
configure() {
run ./bootstrap.sh \
--with-icu="${DESTDIR}/usr/local" \
--prefix="${DESTDIR}/usr/local" \
--without-libraries='python'
echo "using gcc : : ${CXX} ;" > "${workdir}/user-config.jam"
}
build() {
run ./b2 "${bjamopts[@]}"
run cmake "${configopts[@]}"
}
install() {
run ./b2 "${bjamopts[@]}" install
run make "${installopts[@]}" install
}
@@ -6,14 +6,11 @@ Subject: [PATCH] Add platform support for SerenityOS
---
.../config/detail/select_platform_config.hpp | 5 ++++
.../boost/config/platform/serenity.hpp | 26 +++++++++++++++++++
tools/build/src/tools/features/os-feature.jam | 4 +--
tools/build/src/tools/gcc.jam | 4 ++-
tools/build/src/tools/python.jam | 1 +
5 files changed, 37 insertions(+), 3 deletions(-)
2 files changed, 31 insertions(+)
create mode 100644 libs/config/include/boost/config/platform/serenity.hpp
diff --git a/libs/config/include/boost/config/detail/select_platform_config.hpp b/libs/config/include/boost/config/detail/select_platform_config.hpp
index dbff74aaf74ea59eaf204f463bf2b37df9c432a5..3b664107303df336bab8010caad42ddaed24550e 100644
index dbff74aaf74ea59eaf204f463bf2b37df9c432a5..d280ed5c02ff90b5eb0dfef3948d17a2d4310109 100644
--- a/libs/config/include/boost/config/detail/select_platform_config.hpp
+++ b/libs/config/include/boost/config/detail/select_platform_config.hpp
@@ -93,6 +93,10 @@
@@ -37,7 +34,7 @@ index dbff74aaf74ea59eaf204f463bf2b37df9c432a5..3b664107303df336bab8010caad42dda
diff --git a/libs/config/include/boost/config/platform/serenity.hpp b/libs/config/include/boost/config/platform/serenity.hpp
new file mode 100644
index 0000000000000000000000000000000000000000..89d09ca6b01626691ed2c45184bd8d322973df49
index 0000000000000000000000000000000000000000..ecde1fe0e4adf068aaf44aee75757a26df5e1af9
--- /dev/null
+++ b/libs/config/include/boost/config/platform/serenity.hpp
@@ -0,0 +1,26 @@
@@ -67,66 +64,3 @@ index 0000000000000000000000000000000000000000..89d09ca6b01626691ed2c45184bd8d32
+
+// boilerplate code:
+#include <boost/config/detail/posix_features.hpp>
diff --git a/tools/build/src/tools/features/os-feature.jam b/tools/build/src/tools/features/os-feature.jam
index ced1fc1ff803383138e755efebef95983b85e0bd..5e0fc3998b86313a873a0549c95394e7723a9713 100644
--- a/tools/build/src/tools/features/os-feature.jam
+++ b/tools/build/src/tools/features/os-feature.jam
@@ -10,7 +10,7 @@ import os ;
.os-names =
aix android appletv bsd cygwin darwin freebsd haiku hpux iphone linux
netbsd openbsd osf qnx qnxnto sgi solaris unix unixware windows vms vxworks
- freertos
+ freertos serenity
# Not actually an OS -- used for targeting bare metal where object
# format is ELF. This catches both -elf and -eabi gcc targets as well
@@ -79,7 +79,7 @@ feature.set-default host-os : [ default-host-os ] ;
*Allowed values:* `aix`, `android`, `appletv`, `bsd`, `cygwin`, `darwin`,
`freebsd`, `haiku`, `hpux`, `iphone`, `linux`, `netbsd`, `openbsd`, `osf`,
`qnx`, `qnxnto`, `sgi`, `solaris`, `unix`, `unixware`, `windows`, `vms`,
-`vxworks`, `freertos`.
+`vxworks`, `freertos`, `serenity`.
+
Specifies the operating system for which the code is to be generated. The
compiler you used should be the compiler for that operating system. This option
diff --git a/tools/build/src/tools/gcc.jam b/tools/build/src/tools/gcc.jam
index 834f5e1bf6ddb080127a9e17e566571a39b8fef3..9e18425d018866a0590e5205258ba4b2b099f6ec 100644
--- a/tools/build/src/tools/gcc.jam
+++ b/tools/build/src/tools/gcc.jam
@@ -203,6 +203,7 @@ rule init ( version ? : command * : options * : requirement * )
case *mingw* : target-os ?= windows ;
case *cygwin* : target-os ?= cygwin ;
case *linux* : target-os ?= linux ;
+ case *serenity* : target-os ?= serenity ;
# TODO: finish this list.
}
}
@@ -391,6 +392,7 @@ local rule compile-link-flags ( * )
threading-flags <target-os>cygwin/<threadapi>pthread : -pthread ;
threading-flags <target-os>solaris : -pthreads : rt ;
threading-flags <target-os>qnx : -pthread ;
+ threading-flags <target-os>serenity ;
local bsd = [ MATCH ^(.*bsd)$ : $(all-os) ] ;
threading-flags <target-os>$(bsd) : -pthread ;
@@ -398,7 +400,7 @@ local rule compile-link-flags ( * )
# iOS doesn't need pthread flag according to the https://developer.apple.com/library/archive/documentation/System/Conceptual/ManPages_iPhoneOS/man3/pthread.3.html
# The default system libraries include pthread functions. No additional libraries or CFLAGS are necessary to use this API.
local no-threading = android beos haiku sgi darwin vxworks iphone appletv ;
- local threading-generic-os = [ set.difference $(all-os) : $(no-threading) $(bsd) windows cygwin solaris qnx ] ;
+ local threading-generic-os = [ set.difference $(all-os) : $(no-threading) $(bsd) windows cygwin solaris qnx serenity ] ;
threading-flags <target-os>$(threading-generic-os) : -pthread : rt ;
}
diff --git a/tools/build/src/tools/python.jam b/tools/build/src/tools/python.jam
index 0dfc750a220b82ad47d67d3f28bf5bdaf2fb2455..b0f6c2c6c29d03c1f86ff650158a4b04b1e0822c 100644
--- a/tools/build/src/tools/python.jam
+++ b/tools/build/src/tools/python.jam
@@ -654,6 +654,7 @@ local rule system-library-dependencies ( target-os )
case darwin : return ;
case windows : return ;
case haiku : return ;
+ case serenity : return ;
case hpux : return <library>rt ;
case *bsd : return <library>pthread <toolset>gcc:<library>util ;
@@ -8,15 +8,15 @@ Subject: [PATCH] Fix building Boost.Interprocess
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libs/interprocess/include/boost/interprocess/detail/workaround.hpp b/libs/interprocess/include/boost/interprocess/detail/workaround.hpp
index 01b6c6eb05dddff8c8b6fbb0c5c279deb971b7c2..6fc793b6009c24f2db4fc6b1aefb2d4d3eb4cfae 100644
index b9438a5f1722d5e4c79f72d895a0f7e20ab01538..b02e25c242ce3957e0aab4de5387a64553c58f4e 100644
--- a/libs/interprocess/include/boost/interprocess/detail/workaround.hpp
+++ b/libs/interprocess/include/boost/interprocess/detail/workaround.hpp
@@ -37,7 +37,7 @@
@@ -41,7 +41,7 @@
//////////////////////////////////////////////////////
//Check for XSI shared memory objects. They are available in nearly all UNIX platforms
//////////////////////////////////////////////////////
- #if !defined(__QNXNTO__) && !defined(__ANDROID__) && !defined(__HAIKU__) && !(__VXWORKS__)
+ #if !defined(__QNXNTO__) && !defined(__ANDROID__) && !defined(__HAIKU__) && !(__VXWORKS__) && !defined(__serenity__)
- #if !defined(__QNXNTO__) && !defined(__ANDROID__) && !defined(__HAIKU__) && !defined(__VXWORKS__) && !defined(__EMSCRIPTEN__)
+ #if !defined(__QNXNTO__) && !defined(__ANDROID__) && !defined(__HAIKU__) && !defined(__VXWORKS__) && !defined(__EMSCRIPTEN__) && !defined(__serenity__)
#define BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS
#endif
@@ -0,0 +1,40 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Linus Groh <[email protected]>
Date: Mon, 21 Sep 2026 21:52:43 +0100
Subject: [PATCH] Don't use wordexp on SerenityOS
---
libs/process/src/shell.cpp | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/libs/process/src/shell.cpp b/libs/process/src/shell.cpp
index bf4bbfd8315946608593ca9a032a0f9687c2df20..a7a13f792332eb8e2f749f6231bcf68db57da8bf 100644
--- a/libs/process/src/shell.cpp
+++ b/libs/process/src/shell.cpp
@@ -19,7 +19,7 @@
#if defined(BOOST_PROCESS_V2_WINDOWS)
#include <windows.h>
#include <shellapi.h>
-#elif !defined(__OpenBSD__) && !defined(__ANDROID__)
+#elif !defined(__OpenBSD__) && !defined(__ANDROID__) && !defined(__serenity__)
#include <wordexp.h>
#endif
@@ -30,7 +30,7 @@ BOOST_PROCESS_V2_DECL const error_category& get_shell_category()
{
return system_category();
}
-#elif !defined(__OpenBSD__) && !defined(__ANDROID__)
+#elif !defined(__OpenBSD__) && !defined(__ANDROID__) && !defined(__serenity__)
struct shell_category_t final : public error_category
{
@@ -99,7 +99,7 @@ auto shell::args() const-> args_type
return input_.c_str();
}
-#elif !defined(__OpenBSD__) && !defined(__ANDROID__)
+#elif !defined(__OpenBSD__) && !defined(__ANDROID__) && !defined(__serenity__)
void shell::parse_()
{
@@ -1,21 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Gunnar Beutner <[email protected]>
Date: Sun, 23 Oct 2022 12:00:56 +0200
Subject: [PATCH] Fix building Boost.Python
---
tools/build/src/tools/python.jam | 1 +
1 file changed, 1 insertion(+)
diff --git a/tools/build/src/tools/python.jam b/tools/build/src/tools/python.jam
index b0f6c2c6c29d03c1f86ff650158a4b04b1e0822c..824d1455dd086d36f9e561e961bab1fb73ece37c 100644
--- a/tools/build/src/tools/python.jam
+++ b/tools/build/src/tools/python.jam
@@ -716,6 +716,7 @@ local rule configure ( version ? : cmd-or-prefix ? : includes * : libraries ? :
local interpreter-cmd ;
local target-os = [ feature.get-values target-os : $(condition) ] ;
+ target-os = "serenity" ; # FIXME
target-os ?= [ feature.defaults target-os ] ;
target-os = $(target-os:G=) ;
+2 -2
View File
@@ -10,8 +10,8 @@ Add platform support for SerenityOS
Fix building Boost.Interprocess
## `0003-Fix-building-Boost.Python.patch`
## `0003-Don-t-use-wordexp-on-SerenityOS.patch`
Fix building Boost.Python
Don't use wordexp on SerenityOS