commit:     34c9343ee73f1192ecc2d7dd42c502a030695e91
Author:     Yixun Lan <dlan <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 23 02:15:14 2024 +0000
Commit:     Yixun Lan <dlan <AT> gentoo <DOT> org>
CommitDate: Sat Mar 23 02:15:28 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=34c9343e

dev-libs/libgpiod: add 2.1.1

fix missing dev-cpp/catch if USE=cxx,test enabled

Closes: https://bugs.gentoo.org/927400
Signed-off-by: Yixun Lan <dlan <AT> gentoo.org>

 dev-libs/libgpiod/Manifest              |  1 +
 dev-libs/libgpiod/libgpiod-2.1.1.ebuild | 67 +++++++++++++++++++++++++++++++++
 2 files changed, 68 insertions(+)

diff --git a/dev-libs/libgpiod/Manifest b/dev-libs/libgpiod/Manifest
index df8f7e562b7f..cc79e073bb6f 100644
--- a/dev-libs/libgpiod/Manifest
+++ b/dev-libs/libgpiod/Manifest
@@ -1,3 +1,4 @@
 DIST libgpiod-1.6.3.tar.xz 326068 BLAKE2B 
eda5409f2db3914ede92690589643211eca3002f8dc53a7c48213602f28158084c8eb8061319923f7a51c7d91650ff58b81b059323b5b9133a28b0bb04f6904d
 SHA512 
f7e48662d02904f3f25976d61aa2cf4af0b8a52f65f184f23dfb6916bde9b86634b211f2696d3459a4f902ba5a79621b2fc47d18d487fd7a159018fe8933e370
 DIST libgpiod-1.6.4.tar.xz 334552 BLAKE2B 
3bf52dab263638967e0f59c858e22f3d8ec1c9565ba1edd665dff580a883fbc6aa49a944e6df4da8fca9c2df873e222ed4e055c9792ee27d4562b3c2d0c65b79
 SHA512 
23ea27147039ae34505263dbfbb3ca9985fc671d26e489ccaf150543d4e853f709393f46a8a5a1e682fa91378163bd2db6c689159ef73c3a8d1eeea422eacda0
+DIST libgpiod-2.1.1.tar.xz 421164 BLAKE2B 
940f2af832a0fc39accecd9cf76864d05f961c0d2e4899d09dc07670bb2a8d8c2704fa43e29e2163f2b486ba65cadce2114f96cf0e7637afece99c543852305f
 SHA512 
d396f1b8f632c3592b2be37e23e5052f4050ab5c1a9de77de5f97ce50fa3115c119dd69b0bbcf59621e92b775bfc81f18a65cca1e57e022752d28c0e01baff6f
 DIST libgpiod-2.1.tar.xz 421132 BLAKE2B 
97f43854070f19b37f4041c08d33c8156d69a3acd73845849f843223d159602ad8aa59096e1c8a3428bf16488272353a5747c6c95b9f729cb11e53ceeb6b29c2
 SHA512 
1c20a93fb2a6cf66f4690a5784ac1aeb077ca3da23c1942448f045972092468480e13b13174f327b3b7252bef5f23ffd226c990f11529b1151ba2dc318a47e52

diff --git a/dev-libs/libgpiod/libgpiod-2.1.1.ebuild 
b/dev-libs/libgpiod/libgpiod-2.1.1.ebuild
new file mode 100644
index 000000000000..f9552379a641
--- /dev/null
+++ b/dev-libs/libgpiod/libgpiod-2.1.1.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools linux-info
+
+DESCRIPTION="C library and tools for interacting with the linux GPIO character 
device"
+HOMEPAGE="https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git/";
+SRC_URI="https://mirrors.edge.kernel.org/pub/software/libs/libgpiod/${P}.tar.xz";
+
+LICENSE="LGPL-2.1"
+# Reflects the ABI of libgpiod.so
+SLOT="0/3"
+KEYWORDS="~amd64 ~arm ~arm64 ~riscv ~x86"
+IUSE="+tools cxx python test"
+RESTRICT="!test? ( test )"
+
+#  --enable-tests          enable libgpiod tests [default=no]
+#  --enable-bindings-cxx   enable C++ bindings [default=no]
+#  --enable-bindings-python
+#  --enable-bindings-rust
+DEPEND="
+       test? (
+               >=dev-libs/glib-2.50
+               >=sys-apps/kmod-18
+               >=sys-apps/util-linux-2.33.1
+               >=virtual/libudev-215
+               cxx? ( <dev-cpp/catch-3.5:0 )
+       )
+"
+
+PATCHES=(
+       # bug 913899
+       "${FILESDIR}"/${PN}-2.1-libtool.patch
+)
+
+pkg_setup() {
+       CONFIG_CHECK="~GPIO_CDEV_V1"
+       linux-info_pkg_setup
+}
+
+src_prepare() {
+       default
+       eautoreconf
+}
+
+src_configure() {
+       local myconf=(
+               $(use_enable tools)
+               $(use_enable cxx bindings-cxx)
+               $(use_enable test tests)
+               $(use_enable python bindings-python)
+               --enable-examples
+               --disable-profiling
+               --disable-bindings-rust
+       )
+
+       econf "${myconf[@]}"
+}
+
+src_install() {
+       default
+
+       find "${D}" -name '*.la' -type f -delete || die
+       find "${D}" -name "*.a" -delete || die
+}

Reply via email to