diff options
author | 2023-01-21 21:40:39 +0000 | |
---|---|---|
committer | 2023-01-21 21:57:35 +0000 | |
commit | 2503b56f8a968294d095ecdcb95ad504a6280c85 (patch) | |
tree | ab8cd80926858e77dea073911b83c73e9ff0774e /dev-cpp/folly/files | |
parent | net-misc/openssh: backport getentropy & sandbox writev patches (diff) | |
download | gentoo-2503b56f8a968294d095ecdcb95ad504a6280c85.tar.gz gentoo-2503b56f8a968294d095ecdcb95ad504a6280c85.tar.bz2 gentoo-2503b56f8a968294d095ecdcb95ad504a6280c85.zip |
dev-cpp/folly: add 2023.01.16.00
Signed-off-by: Sam James <[email protected]>
Diffstat (limited to 'dev-cpp/folly/files')
-rw-r--r-- | dev-cpp/folly/files/folly-2023.01.16.00-gcc13.patch | 23 | ||||
-rw-r--r-- | dev-cpp/folly/files/folly-2023.01.16.00-liburing.patch | 54 |
2 files changed, 77 insertions, 0 deletions
diff --git a/dev-cpp/folly/files/folly-2023.01.16.00-gcc13.patch b/dev-cpp/folly/files/folly-2023.01.16.00-gcc13.patch new file mode 100644 index 000000000000..0fed0efeb505 --- /dev/null +++ b/dev-cpp/folly/files/folly-2023.01.16.00-gcc13.patch @@ -0,0 +1,23 @@ +--- a/folly/system/AtFork.cpp ++++ b/folly/system/AtFork.cpp +@@ -14,6 +14,8 @@ + * limitations under the License. + */ + ++#include <stdexcept> ++ + #include <folly/system/AtFork.h> + + #include <folly/ScopeGuard.h> +diff --git a/folly/system/AtFork.cpp b/folly/system/AtFork.cpp +index be613c7..a557033 100644 +--- a/folly/system/AtFork.cpp ++++ b/folly/system/AtFork.cpp +@@ -15,6 +15,7 @@ + */ + + #include <stdexcept> ++#include <system_error> + + #include <folly/system/AtFork.h> + diff --git a/dev-cpp/folly/files/folly-2023.01.16.00-liburing.patch b/dev-cpp/folly/files/folly-2023.01.16.00-liburing.patch new file mode 100644 index 000000000000..e2a692cea50c --- /dev/null +++ b/dev-cpp/folly/files/folly-2023.01.16.00-liburing.patch @@ -0,0 +1,54 @@ +https://bugs.gentoo.org/891633 +https://github.com/facebook/folly/issues/1908 +https://github.com/facebook/folly/commit/259c9d6a4f0eb6d80e0263c2fe5d1af5bff116dc + +From 259c9d6a4f0eb6d80e0263c2fe5d1af5bff116dc Mon Sep 17 00:00:00 2001 +From: Dylan Yudaken <[email protected]> +Date: Mon, 16 Jan 2023 01:20:04 -0800 +Subject: [PATCH] io_uring: implement io_uring_enable_rings locally (#1915) + +Summary: +Pull Request resolved: https://github.com/facebook/folly/pull/1915 + +io_uring_enable_rings was missing from liburing upstream (see https://github.com/axboe/liburing/issues/773) which is breaking the open source build. See https://github.com/facebook/folly/issues/1908 + +Instead just implement it locally, as it's trivial + +Reviewed By: dmm-fb + +Differential Revision: D42497664 + +fbshipit-source-id: 7241785a36046e867f907bfe74623aaeb38c4b70 +--- a/folly/experimental/io/IoUringBackend.cpp ++++ b/folly/experimental/io/IoUringBackend.cpp +@@ -56,6 +56,20 @@ namespace folly { + + namespace { + ++#if FOLLY_IO_URING_UP_TO_DATE ++int ioUringEnableRings(FOLLY_MAYBE_UNUSED struct io_uring* ring) { ++ // Ideally this would call ::io_uring_enable_rings directly which just runs ++ // the below however this was missing from a stable version of liburing, which ++ // means that some distributions were not able to compile it. see ++ // https://github.com/axboe/liburing/issues/773 ++ ++ // since it is so simple, just implement it here until the fix rolls out to an ++ // acceptable number of OSS distributions. ++ return ::io_uring_register( ++ ring->ring_fd, IORING_REGISTER_ENABLE_RINGS, nullptr, 0); ++} ++#endif ++ + struct SignalRegistry { + struct SigInfo { + struct sigaction sa_ {}; +@@ -1360,7 +1374,7 @@ void IoUringBackend::delayedInit() { + if (usingDeferTaskrun_) { + // usingDeferTaskrun_ is guarded already on having an up to date liburing + #if FOLLY_IO_URING_UP_TO_DATE +- int ret = ::io_uring_enable_rings(&ioRing_); ++ int ret = ioUringEnableRings(&ioRing_); + if (ret) { + LOG(ERROR) << "io_uring_enable_rings gave " << folly::errnoStr(-ret); + } + |