Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni via buildroot <buildroot@buildroot.org>
To: buildroot@buildroot.org
Cc: Jean Burgat <jeanburgat33@gmail.com>,
	James Hilliard <james.hilliard1@gmail.com>,
	Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
	Adrian Perez de Castro <aperez@igalia.com>
Subject: [Buildroot] [PATCH] package/hidapi: propagate dependencies of libgudev
Date: Sun, 13 Sep 2026 14:01:00 +0200	[thread overview]
Message-ID: <20260913120101.1646000-1-thomas.petazzoni@bootlin.com> (raw)

Since hidapi was introduced in commit
6267f34afdd06ad848bbf7a2975cb279132b6ba0, it forgot to propagate some
dependencies of libgudev (which existed back then). Initially libgudev
was only needed when BR2_INIT_SYSTEMD=y, but still the dependencies
were not propagated for the systemd case.

Anyway, since e739dd5a11f5b2bd9648a45623bc174adae42b6e, libgudev is a
mandatory dependency of hidapi, independently from the selected init
system.

We make sure to propagate all dependencies of libgudev to hidapi, and
propagate them to the reverse dependencies of hidapi.

Fixes: 6267f34afdd06ad848bbf7a2975cb279132b6ba0 ("hidapi: new package")
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
 package/hidapi/Config.in         | 8 ++++++--
 package/libmanette/Config.in     | 4 ++--
 package/openfpgaloader/Config.in | 9 +++++++--
 package/openocd/Config.in        | 9 +++++++++
 package/python-hid/Config.in     | 8 ++++++--
 5 files changed, 30 insertions(+), 8 deletions(-)

diff --git a/package/hidapi/Config.in b/package/hidapi/Config.in
index 1d3c86b677..fa44288917 100644
--- a/package/hidapi/Config.in
+++ b/package/hidapi/Config.in
@@ -3,6 +3,8 @@ config BR2_PACKAGE_HIDAPI
 	depends on BR2_PACKAGE_HAS_UDEV
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
+	depends on BR2_USE_MMU # libgudev
+	depends on BR2_USE_WCHAR # libgudev
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_LIBGUDEV
 	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
@@ -15,7 +17,9 @@ config BR2_PACKAGE_HIDAPI
 
 	  http://github.com/libusb/hidapi/
 
-comment "hidapi needs udev /dev management and a toolchain w/ NPTL, gcc >= 4.9"
+comment "hidapi needs udev /dev management and a toolchain w/ NPTL, gcc >= 4.9, wchar"
+	depends on BR2_USE_MMU
 	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || \
 		!BR2_PACKAGE_HAS_UDEV || \
-		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 || \
+		!BR2_USE_WCHAR
diff --git a/package/libmanette/Config.in b/package/libmanette/Config.in
index 873f8d8b0b..d4f45e25ad 100644
--- a/package/libmanette/Config.in
+++ b/package/libmanette/Config.in
@@ -1,7 +1,7 @@
 config BR2_PACKAGE_LIBMANETTE
 	bool "libmanette"
-	depends on BR2_USE_MMU # libglib2
-	depends on BR2_USE_WCHAR # libglib2 -> gettext
+	depends on BR2_USE_MMU # libglib2, hidapi
+	depends on BR2_USE_WCHAR # libglib2, hidapi
 	depends on BR2_PACKAGE_HAS_UDEV # hidapi
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # hidapi
 	depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_4_16
diff --git a/package/openfpgaloader/Config.in b/package/openfpgaloader/Config.in
index bd83ad415b..80305f1eba 100644
--- a/package/openfpgaloader/Config.in
+++ b/package/openfpgaloader/Config.in
@@ -17,12 +17,17 @@ config BR2_PACKAGE_OPENFPGALOADER_CMSIS
 	depends on BR2_PACKAGE_HAS_UDEV # hidapi
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # hidapi
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # hidapi -> libusb
+	depends on BR2_USE_MMU # hidapi
+	depends on BR2_USE_WCHAR # hidapi
 	select BR2_PACKAGE_HIDAPI
 	help
 	  openfpgaloader CMSIS-DAP support
 
-comment "openfpgaloader CMSIS-DAP needs udev /dev management and a toolchain w/ NPTL threads"
-	depends on !BR2_PACKAGE_HAS_UDEV || !BR2_TOOLCHAIN_HAS_THREADS_NPTL
+comment "openfpgaloader CMSIS-DAP needs udev /dev management and a toolchain w/ NPTL threads, gcc >= 4.9, wchar"
+	depends on BR2_USE_MMU
+	depends on !BR2_PACKAGE_HAS_UDEV || !BR2_TOOLCHAIN_HAS_THREADS_NPTL || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 || \
+		!BR2_USE_WCHAR
 
 config BR2_PACKAGE_OPENFPGALOADER_LIBGPIOD
 	bool "libgpiod support"
diff --git a/package/openocd/Config.in b/package/openocd/Config.in
index a7e068f10d..2c2f6fe7aa 100644
--- a/package/openocd/Config.in
+++ b/package/openocd/Config.in
@@ -16,12 +16,21 @@ config BR2_PACKAGE_OPENOCD_CMSIS_DAP
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # libusb
 	depends on BR2_PACKAGE_HAS_UDEV # hidapi
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # hidapi
+	depends on BR2_USE_MMU # hidapi
+	depends on BR2_USE_WCHAR # hidapi
 	select BR2_PACKAGE_LIBUSB
 	select BR2_PACKAGE_HIDAPI
 	help
 	  Enable support for CMSIS-DAP compliant debuggers (i.e
 	  Atmel/Microchip EDBG, etc.)
 
+comment "CMSIS-DAP support needs udev, toolchain w/ NPTL, gcc >= 4.9, wchar"
+	depends on BR2_USE_MMU
+	depends on !BR2_PACKAGE_HAS_UDEV || \
+		!BR2_TOOLCHAIN_HAS_THREADS_NPTL || \
+		!BR2_USE_WCHAR || \
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
 config BR2_PACKAGE_OPENOCD_FTDI
 	bool "MPSSE mode of FTDI based devices"
 	depends on BR2_TOOLCHAIN_HAS_THREADS # libusb
diff --git a/package/python-hid/Config.in b/package/python-hid/Config.in
index 3a9e16c9f4..e46a5c2000 100644
--- a/package/python-hid/Config.in
+++ b/package/python-hid/Config.in
@@ -3,13 +3,17 @@ config BR2_PACKAGE_PYTHON_HID
 	depends on BR2_PACKAGE_HAS_UDEV # hidapi
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # hidapi
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # hidapi
+	depends on BR2_USE_MMU # hidapi
+	depends on BR2_USE_WCHAR # hidapi
 	select BR2_PACKAGE_HIDAPI
 	help
 	  ctypes bindings for hidapi.
 
 	  https://github.com/apmorton/pyhidapi
 
-comment "python-hid needs udev /dev management and a toolchain w/ NPTL, gcc >= 4.9"
+comment "python-hid needs udev /dev management and a toolchain w/ NPTL, gcc >= 4.9, wchar"
+	depends on BR2_USE_MMU
 	depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || \
 		!BR2_PACKAGE_HAS_UDEV || \
-		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+		!BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 || \
+		!BR2_USE_WCHAR
-- 
2.55.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

             reply	other threads:[~2026-09-13 12:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-13 12:01 Thomas Petazzoni via buildroot [this message]
2026-09-13 15:14 ` [Buildroot] [PATCH] package/hidapi: propagate dependencies of libgudev Julien Olivain via buildroot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260913120101.1646000-1-thomas.petazzoni@bootlin.com \
    --to=buildroot@buildroot.org \
    --cc=aperez@igalia.com \
    --cc=james.hilliard1@gmail.com \
    --cc=jeanburgat33@gmail.com \
    --cc=thomas.petazzoni@bootlin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox