From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 145D015806E for ; Sun, 14 May 2023 09:45:50 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 0ACB5E07EA; Sun, 14 May 2023 09:45:49 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id E123FE07EA for ; Sun, 14 May 2023 09:45:48 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id BB0C6340E69 for ; Sun, 14 May 2023 09:45:47 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 1FA8A7F5 for ; Sun, 14 May 2023 09:45:46 +0000 (UTC) From: "Viorel Munteanu" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Viorel Munteanu" Message-ID: <1684057334.1457787d90a518a22fe1afcd2c91ca5a05df24eb.ceamac@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/librdkafka/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-libs/librdkafka/Manifest dev-libs/librdkafka/librdkafka-2.1.0.ebuild X-VCS-Directories: dev-libs/librdkafka/ X-VCS-Committer: ceamac X-VCS-Committer-Name: Viorel Munteanu X-VCS-Revision: 1457787d90a518a22fe1afcd2c91ca5a05df24eb X-VCS-Branch: master Date: Sun, 14 May 2023 09:45:46 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: d714c665-3145-4893-ae44-38a105a952d5 X-Archives-Hash: 7b7740115697300c55522a4f1316da6f commit: 1457787d90a518a22fe1afcd2c91ca5a05df24eb Author: Miezhiko gmail com> AuthorDate: Wed Apr 19 14:35:07 2023 +0000 Commit: Viorel Munteanu gentoo org> CommitDate: Sun May 14 09:42:14 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1457787d dev-libs/librdkafka: new version 2.1.0 Signed-off-by: Miezhiko gmail.com> Closes: https://github.com/gentoo/gentoo/pull/30651 Signed-off-by: Viorel Munteanu gentoo.org> dev-libs/librdkafka/Manifest | 1 + dev-libs/librdkafka/librdkafka-2.1.0.ebuild | 106 ++++++++++++++++++++++++++++ 2 files changed, 107 insertions(+) diff --git a/dev-libs/librdkafka/Manifest b/dev-libs/librdkafka/Manifest index da52a2e0337a..dbe431ffa583 100644 --- a/dev-libs/librdkafka/Manifest +++ b/dev-libs/librdkafka/Manifest @@ -1 +1,2 @@ DIST librdkafka-1.8.2.tar.gz 4097028 BLAKE2B 37a3190417e973ea4629012e358ff61cda45eb0134448dd0054fd1f1cac57f3543b133331b0b0d518f219f30f79f7665a214c75084d6a8474687b7e686395724 SHA512 8c8ae291129b78e3b8367307ad1b1715af1438cd76d7160d64d13a58adf84c7c9f51efeba4656f55e101c25e4cb744db0d8bb5c01a2decb229e4567d16bdcb22 +DIST librdkafka-2.1.0.tar.gz 4276259 BLAKE2B 3b0f50bcebdc8115790622a6124e12bc8c2b36fe170484788fc1d2d01a5e9696d7cc988c5eea9efd0922ac5c70c8ab02fc4a574d0bd03bed74b22db2b5bef5a0 SHA512 eeefa8833e7c178015ff8d0914d927d1bf4e09a75c5f227ba75e527f9bfc46407798d69642b5db3edafb93fcdbe56e8b506df826d01c7793af0f11e96c38caed diff --git a/dev-libs/librdkafka/librdkafka-2.1.0.ebuild b/dev-libs/librdkafka/librdkafka-2.1.0.ebuild new file mode 100644 index 000000000000..99a1329b06bf --- /dev/null +++ b/dev-libs/librdkafka/librdkafka-2.1.0.ebuild @@ -0,0 +1,106 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI="8" + +PYTHON_COMPAT=( python3_{9..11} ) + +inherit python-any-r1 toolchain-funcs + +DESCRIPTION="Apache Kafka C/C++ client library" +HOMEPAGE="https://github.com/edenhill/librdkafka" + +if [[ ${PV} == "9999" ]]; then + EGIT_REPO_URI="https://github.com/edenhill/${PN}.git" + + inherit git-r3 +else + SRC_URI="https://github.com/edenhill/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86" +fi + +LICENSE="BSD-2" + +# subslot = soname version +SLOT="0/1" + +IUSE="lz4 sasl ssl static-libs zstd" + +LIB_DEPEND=" + lz4? ( app-arch/lz4:=[static-libs(+)] ) + sasl? ( dev-libs/cyrus-sasl:=[static-libs(+)] ) + ssl? ( dev-libs/openssl:0=[static-libs(+)] ) + zstd? ( app-arch/zstd:=[static-libs(+)] ) + sys-libs/zlib:=[static-libs(+)] +" + +BDEPEND=" + virtual/pkgconfig + ${PYTHON_DEPS} +" + +RDEPEND="!static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )" + +DEPEND=" + ${RDEPEND} + static-libs? ( ${LIB_DEPEND} ) +" + +pkg_setup() { + python-any-r1_pkg_setup +} + +src_prepare() { + default + + if [[ ${PV} != "9999" ]]; then + sed -i \ + -e "s/^\(export RDKAFKA_GITVER=\).*/\1\"${PV}@release\"/" \ + tests/run-test.sh || die + fi +} + +src_configure() { + tc-export AR CC CXX LD NM OBJDUMP PKG_CONFIG STRIP + + local myeconf=( + --prefix="${EPREFIX}/usr" + --build="${CBUILD}" + --host="${CHOST}" + --mandir="${EPREFIX}/usr/share/man" + --infodir="${EPREFIX}/usr/share/info" + --datadir="${EPREFIX}/usr/share" + --sysconfdir="${EPREFIX}/etc" + --localstatedir="${EPREFIX}/var" + --libdir="${EPREFIX}/usr/$(get_libdir)" + --no-cache + --no-download + --disable-debug-symbols + $(use_enable lz4) + $(use_enable sasl) + $(usex static-libs '--enable-static' '') + $(use_enable ssl) + $(use_enable zstd) + ) + + ./configure ${myeconf[@]} || die +} + +src_test() { + # Simulate CI so we do not fail when tests are running longer than expected, + # https://github.com/edenhill/librdkafka/blob/v1.6.1/tests/0062-stats_event.c#L101-L116 + local -x CI=true + + emake -C tests run_local +} + +src_install() { + emake -j1 \ + DESTDIR="${D}" \ + docdir="/usr/share/doc/${PF}" \ + install + + if ! use static-libs; then + find "${ED}" -type f \( -name "*.a" -o -name "*.la" \) -delete || die + fi +}