diff options
author | Arsen Arsenović <arsen@gentoo.org> | 2023-04-18 16:11:33 +0200 |
---|---|---|
committer | Arsen Arsenović <arsen@gentoo.org> | 2023-04-18 16:14:18 +0200 |
commit | 03a4af32d14d3b7841ada238dad68311a2bf09a9 (patch) | |
tree | 01e63f2aa77cc55d9dde8dd81b6ba28231391ccd /dev-cpp | |
parent | sci-mathematics/lean: fix build with GCC 13 (diff) | |
download | gentoo-03a4af32d14d3b7841ada238dad68311a2bf09a9.tar.gz gentoo-03a4af32d14d3b7841ada238dad68311a2bf09a9.tar.bz2 gentoo-03a4af32d14d3b7841ada238dad68311a2bf09a9.zip |
dev-cpp/msgpack-cxx: Fix building on GCC13
Closes: https://bugs.gentoo.org/895690
Signed-off-by: Arsen Arsenović <arsen@gentoo.org>
Diffstat (limited to 'dev-cpp')
-rw-r--r-- | dev-cpp/msgpack-cxx/files/msgpack-cxx-6.0.0-gcc13.patch | 49 | ||||
-rw-r--r-- | dev-cpp/msgpack-cxx/msgpack-cxx-6.0.0.ebuild | 4 |
2 files changed, 53 insertions, 0 deletions
diff --git a/dev-cpp/msgpack-cxx/files/msgpack-cxx-6.0.0-gcc13.patch b/dev-cpp/msgpack-cxx/files/msgpack-cxx-6.0.0-gcc13.patch new file mode 100644 index 000000000000..3e0b67675e2d --- /dev/null +++ b/dev-cpp/msgpack-cxx/files/msgpack-cxx-6.0.0-gcc13.patch @@ -0,0 +1,49 @@ +From 2dd3dbc85f5c3ab789792844e50f7423bdb1d3f9 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Arsen=20Arsenovi=C4=87?= <arsen@gentoo.org> +Date: Tue, 18 Apr 2023 15:50:52 +0200 +Subject: [PATCH] test: Add missing rebind to allocators + +See https://gcc.gnu.org/gcc-13/porting_to.html +--- +https://github.com/msgpack/msgpack-c/pull/1065 + + test/msgpack_cpp11.cpp | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/test/msgpack_cpp11.cpp b/test/msgpack_cpp11.cpp +index 2a856cb8..6b04e5a1 100644 +--- a/test/msgpack_cpp11.cpp ++++ b/test/msgpack_cpp11.cpp +@@ -252,6 +252,9 @@ struct equal_to : std::equal_to<Key> { + template <class Key> + struct set_allocator : std::allocator<Key> { + using std::allocator<Key>::allocator; ++ ++ template<class U> ++ struct rebind { using other = set_allocator<U>; }; + }; + + // C++ named requirement Allocator implies that the first template type +@@ -262,6 +265,9 @@ struct set_allocator : std::allocator<Key> { + template <typename KeyValuePair> + struct map_allocator_impl : std::allocator<KeyValuePair> { + using std::allocator<KeyValuePair>::allocator; ++ ++ template<class U> ++ struct rebind { using other = map_allocator_impl<U>; }; + }; + + template <class Key, class T> +@@ -270,6 +276,9 @@ using map_allocator = map_allocator_impl<std::pair<const Key, T>>; + template <class T> + struct allocator : std::allocator<T> { + using std::allocator<T>::allocator; ++ ++ template<class U> ++ struct rebind { using other = allocator<U>; }; + }; + + } // namespace test +-- +2.40.0 + diff --git a/dev-cpp/msgpack-cxx/msgpack-cxx-6.0.0.ebuild b/dev-cpp/msgpack-cxx/msgpack-cxx-6.0.0.ebuild index 8e3609f7d111..d28443c3f1fa 100644 --- a/dev-cpp/msgpack-cxx/msgpack-cxx-6.0.0.ebuild +++ b/dev-cpp/msgpack-cxx/msgpack-cxx-6.0.0.ebuild @@ -24,6 +24,10 @@ DEPEND="${RDEPEND}" BDEPEND="doc? ( app-doc/doxygen[dot] ) test? ( sys-libs/zlib )" +PATCHES=( + "${FILESDIR}"/"${PN}"-6.0.0-gcc13.patch +) + src_configure() { local mycmakeargs=( -DMSGPACK_BUILD_EXAMPLES=OFF |