summaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp
diff options
context:
space:
mode:
authorTeresa Remmet <t.remmet@phytec.de>2024-09-06 09:25:16 +0200
committerSteve Sakoman <steve@sakoman.com>2024-10-18 06:04:41 -0700
commitf9fd48d759186f2e5f4659a3185570c2971e8622 (patch)
tree5cec6afcd5653f136baad6c95012e352ca97c5f7 /meta/recipes-bsp
parente6acba1518756304c6ef7770bbc7812fb2cb882b (diff)
downloadpoky-f9fd48d759186f2e5f4659a3185570c2971e8622.tar.gz
recipes-bsp: usbutils: Fix usb-devices command using busybox
Unknown find parameter -printf makes usb-devices script unusable with busybox. Replace the parameter to fix this issue. (From OE-Core rev: bb7dad01066d22c3cc4465bdf39ec4e310821d15) Signed-off-by: Teresa Remmet <t.remmet@phytec.de> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit c7c9f827e914b7c27856d995da553a2e41372321) Signed-off-by: Steve Sakoman <steve@sakoman.com>
Diffstat (limited to 'meta/recipes-bsp')
-rwxr-xr-xmeta/recipes-bsp/usbutils/usbutils/0001-usb-devices-Fix-usb-devices-with-busybox.patch37
-rw-r--r--meta/recipes-bsp/usbutils/usbutils_017.bb1
2 files changed, 38 insertions, 0 deletions
diff --git a/meta/recipes-bsp/usbutils/usbutils/0001-usb-devices-Fix-usb-devices-with-busybox.patch b/meta/recipes-bsp/usbutils/usbutils/0001-usb-devices-Fix-usb-devices-with-busybox.patch
new file mode 100755
index 0000000000..dbe5d7c18b
--- /dev/null
+++ b/meta/recipes-bsp/usbutils/usbutils/0001-usb-devices-Fix-usb-devices-with-busybox.patch
@@ -0,0 +1,37 @@
1From da155d965a34b5c5770dc30fa52eb7ef405f3a30 Mon Sep 17 00:00:00 2001
2From: Teresa Remmet <t.remmet@phytec.de>
3Date: Thu, 5 Sep 2024 08:37:48 +0200
4Subject: [PATCH] usb-devices: Fix usb-devices with busybox
5
6The busybox find command is missing the -printf parameter leading to
7the error:
8
9find: unrecognized: -printf
10
11Replace the parameter with sed.
12
13This patch was originally created by Daniel Fancsali.
14
15Upstream-Status: Backport [https://github.com/gregkh/usbutils/commit/da155d965a34b5c5770dc30fa52eb7ef405f3a30]
16
17Signed-off-by: Teresa Remmet <t.remmet@phytec.de>
18---
19 usb-devices | 2 +-
20 1 file changed, 1 insertion(+), 1 deletion(-)
21
22diff --git a/usb-devices b/usb-devices
23index 5f60ad5a1ed0..51f48b4ad628 100755
24--- a/usb-devices
25+++ b/usb-devices
26@@ -192,7 +192,7 @@ if [ ! -d /sys/bus ]; then
27 exit 1
28 fi
29
30-for device in $(find /sys/bus/usb/devices -name 'usb*' -printf '%f\n' | sort -V)
31+for device in $(find /sys/bus/usb/devices -name 'usb*' | sed -E 's#^.*/##g' | sort -V)
32 do
33 print_device "/sys/bus/usb/devices/$device" 0 0 0
34 done
35--
362.34.1
37
diff --git a/meta/recipes-bsp/usbutils/usbutils_017.bb b/meta/recipes-bsp/usbutils/usbutils_017.bb
index a2e340ea4f..83d5c7287d 100644
--- a/meta/recipes-bsp/usbutils/usbutils_017.bb
+++ b/meta/recipes-bsp/usbutils/usbutils_017.bb
@@ -13,6 +13,7 @@ DEPENDS = "libusb1 virtual/libiconv udev"
13 13
14SRC_URI = "${KERNELORG_MIRROR}/linux/utils/usb/usbutils/usbutils-${PV}.tar.gz \ 14SRC_URI = "${KERNELORG_MIRROR}/linux/utils/usb/usbutils/usbutils-${PV}.tar.gz \
15 file://0001-usbutils.pc.in-Fix-Cflags-entry.patch \ 15 file://0001-usbutils.pc.in-Fix-Cflags-entry.patch \
16 file://0001-usb-devices-Fix-usb-devices-with-busybox.patch \
16 " 17 "
17SRC_URI[sha256sum] = "f704c4cb78a060db88b43aac6ebfd3d93c2c5cf1d6dd0e42936faaf00814ab00" 18SRC_URI[sha256sum] = "f704c4cb78a060db88b43aac6ebfd3d93c2c5cf1d6dd0e42936faaf00814ab00"
18 19