Skip to content

Commit

Permalink
dev-libs/msgpack: fix building with GCC-6.
Browse files Browse the repository at this point in the history
Gentoo-Bug: https://bugs.gentoo.org/623492

Package-Manager: Portage-2.3.6, Repoman-2.3.2
Closes: gentoo#5206
  • Loading branch information
Peter-Levine authored and monsieurp committed Jul 25, 2017
1 parent a82d114 commit 42a9bc1
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
22 changes: 22 additions & 0 deletions dev-libs/msgpack/files/msgpack-1.1.0-gcc6.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
Bug: https://bugs.gentoo.org/623492
Backported from: https://github.com/msgpack/msgpack-c/commit/66a5fcf8f1a9e57b02904a6ac55a86a9c74ea1de

--- a/include/msgpack/adaptor/detail/cpp11_msgpack_tuple.hpp
+++ b/include/msgpack/adaptor/detail/cpp11_msgpack_tuple.hpp
@@ -46,13 +46,14 @@
public:
using base = std::tuple<Types...>;

- using base::base;

- tuple() = default;
tuple(tuple const&) = default;
tuple(tuple&&) = default;

template<typename... OtherTypes>
+ tuple(OtherTypes&&... other):base(std::forward<OtherTypes>(other)...) {}
+
+ template<typename... OtherTypes>
tuple(tuple<OtherTypes...> const& other):base(static_cast<std::tuple<OtherTypes...> const&>(other)) {}
template<typename... OtherTypes>
tuple(tuple<OtherTypes...> && other):base(static_cast<std::tuple<OtherTypes...> &&>(other)) {}
6 changes: 5 additions & 1 deletion dev-libs/msgpack/msgpack-1.1.0.ebuild
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Copyright 1999-2015 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=5

inherit cmake-multilib

if [[ ${PV} == 9999 ]]; then
Expand All @@ -27,9 +28,11 @@ DEPEND="
"

DOCS=( README.md )

PATCHES=(
"${FILESDIR}"/${PN}-1.0.0-cflags.patch
"${FILESDIR}"/${PN}-1.0.0-static.patch
"${FILESDIR}"/${P}-gcc6.patch
)

src_configure() {
Expand All @@ -38,5 +41,6 @@ src_configure() {
$(cmake-utils_use static-libs MSGPACK_STATIC)
$(cmake-utils_use test MSGPACK_BUILD_TESTS)
)

cmake-multilib_src_configure
}

0 comments on commit 42a9bc1

Please sign in to comment.