commit:     b0107b13bdcbc0ce056b5b53d62347693d574c07
Author:     Viorel Munteanu <ceamac <AT> gentoo <DOT> org>
AuthorDate: Mon Mar  9 16:16:37 2026 +0000
Commit:     Viorel Munteanu <ceamac <AT> gentoo <DOT> org>
CommitDate: Mon Mar  9 16:25:09 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b0107b13

sci-libs/libsigrok: fix build with USE=-serial

Add patch from upstream to fix the build by disabling a component when
no serial USE flag is enabled (serial, bluetooth or hidapi).

Can fix without revbump, it does not affect the path that was building
succesfully.

Closes: https://bugs.gentoo.org/957126
Signed-off-by: Viorel Munteanu <ceamac <AT> gentoo.org>

 .../files/libsigrok-0.6.0_pre20241020-serial.patch     | 18 ++++++++++++++++++
 sci-libs/libsigrok/libsigrok-0.6.0_pre20241020.ebuild  |  3 ++-
 2 files changed, 20 insertions(+), 1 deletion(-)

diff --git a/sci-libs/libsigrok/files/libsigrok-0.6.0_pre20241020-serial.patch 
b/sci-libs/libsigrok/files/libsigrok-0.6.0_pre20241020-serial.patch
new file mode 100644
index 000000000000..3fb259752f33
--- /dev/null
+++ b/sci-libs/libsigrok/files/libsigrok-0.6.0_pre20241020-serial.patch
@@ -0,0 +1,18 @@
+https://bugs.gentoo.org/957126
+https://github.com/sigrokproject/libsigrok/commit/467c80149e1ce0cd9bc77517466cc6b8f4753d49
+
+From: Daniel Trnka <[email protected]>
+Date: Sun, 24 Nov 2024 14:11:46 +0100
+Subject: [PATCH] gwinstek-psp: Only build if serial_comm is enabled
+
+--- a/configure.ac
++++ b/configure.ac
+@@ -336,7 +336,7 @@ SR_DRIVER([GMC MH 1x/2x], [gmc-mh-1x-2x], [serial_comm])
+ SR_DRIVER([Great Scott Gadgets GreatFET One], [greatfet], [libusb])
+ SR_DRIVER([GW Instek GDS-800], [gwinstek-gds-800], [serial_comm])
+ SR_DRIVER([GW Instek GPD], [gwinstek-gpd], [serial_comm])
+-SR_DRIVER([GW Instek PSP], [gwinstek-psp])
++SR_DRIVER([GW Instek PSP], [gwinstek-psp], [serial_comm])
+ SR_DRIVER([Hameg HMO], [hameg-hmo])
+ SR_DRIVER([Hantek 4032L], [hantek-4032l], [libusb])
+ SR_DRIVER([Hantek 6xxx], [hantek-6xxx], [libusb])

diff --git a/sci-libs/libsigrok/libsigrok-0.6.0_pre20241020.ebuild 
b/sci-libs/libsigrok/libsigrok-0.6.0_pre20241020.ebuild
index 38c6be68fec8..276d540d1cb7 100644
--- a/sci-libs/libsigrok/libsigrok-0.6.0_pre20241020.ebuild
+++ b/sci-libs/libsigrok/libsigrok-0.6.0_pre20241020.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2025 Gentoo Authors
+# Copyright 1999-2026 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -87,6 +87,7 @@ BDEPEND="
 
 PATCHES=(
        "${FILESDIR}"/${PN}-0.6.0_pre20241020-swig.patch
+       "${FILESDIR}"/${PN}-0.6.0_pre20241020-serial.patch
 )
 
 pkg_setup() {

Reply via email to