commit: 61e8aec7a404a47df8da672719a5924fc45bcf4d Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Fri Sep 2 20:34:41 2022 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Fri Sep 2 20:34:41 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=61e8aec7
dev-libs/protobuf: sync live ebuild Bug: https://bugs.gentoo.org/868105 Signed-off-by: Sam James <sam <AT> gentoo.org> dev-libs/protobuf/protobuf-9999.ebuild | 31 ++++++++++++++++++++++++++++--- 1 file changed, 28 insertions(+), 3 deletions(-) diff --git a/dev-libs/protobuf/protobuf-9999.ebuild b/dev-libs/protobuf/protobuf-9999.ebuild index ced1c5bfaba7..0e620717ec44 100644 --- a/dev-libs/protobuf/protobuf-9999.ebuild +++ b/dev-libs/protobuf/protobuf-9999.ebuild @@ -1,7 +1,7 @@ # Copyright 2008-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI="7" +EAPI=8 inherit autotools elisp-common flag-o-matic multilib-minimal toolchain-funcs @@ -18,11 +18,11 @@ if [[ "${PV}" == "9999" ]]; then SRC_URI="" else SRC_URI="https://github.com/protocolbuffers/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos" fi LICENSE="BSD" SLOT="0/31" -KEYWORDS="" IUSE="emacs examples static-libs test zlib" RESTRICT="!test? ( test )" @@ -35,18 +35,43 @@ RDEPEND="emacs? ( app-editors/emacs:* ) PATCHES=( "${FILESDIR}/${PN}-3.19.0-disable_no-warning-test.patch" "${FILESDIR}/${PN}-3.19.0-system_libraries.patch" - "${FILESDIR}/${PN}-3.16.0-protoc_input_output_files.patch" + "${FILESDIR}/${PN}-3.20.1-protoc_input_output_files.patch" ) DOCS=(CHANGES.txt CONTRIBUTORS.txt README.md) src_prepare() { default + + # https://github.com/protocolbuffers/protobuf/issues/7413 + sed -e "/^AC_PROG_CXX_FOR_BUILD$/d" -i configure.ac || die + + # https://github.com/protocolbuffers/protobuf/issues/8082 + sed -e "/^TEST_F(IoTest, LargeOutput) {$/,/^}$/d" -i src/google/protobuf/io/zero_copy_stream_unittest.cc || die + + # https://github.com/protocolbuffers/protobuf/issues/8459 + sed \ + -e "/^TEST(ArenaTest, BlockSizeSmallerThanAllocation) {$/a\\ if (sizeof(void*) == 4) {\n GTEST_SKIP();\n }" \ + -e "/^TEST(ArenaTest, SpaceAllocated_and_Used) {$/a\\ if (sizeof(void*) == 4) {\n GTEST_SKIP();\n }" \ + -i src/google/protobuf/arena_unittest.cc || die + + # https://github.com/protocolbuffers/protobuf/issues/8460 + sed -e "/^TEST(AnyTest, TestPackFromSerializationExceedsSizeLimit) {$/a\\ if (sizeof(void*) == 4) {\n GTEST_SKIP();\n }" -i src/google/protobuf/any_test.cc || die + + # https://github.com/protocolbuffers/protobuf/issues/9433 + sed -e "/^[[:space:]]*static_assert(alignof(U) <= 8, \"\");$/d" -i src/google/protobuf/descriptor.cc || die + eautoreconf } src_configure() { append-cppflags -DGOOGLE_PROTOBUF_NO_RTTI + + if tc-ld-is-gold; then + # https://sourceware.org/bugzilla/show_bug.cgi?id=24527 + tc-ld-disable-gold + fi + multilib-minimal_src_configure }