public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/bluez] rawhide: hid2hci: don't fail %post when udevadm is unavailable
@ 2026-11-02 22:00 Michel Lind
0 siblings, 0 replies; only message in thread
From: Michel Lind @ 2026-11-02 22:00 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/bluez
Branch : rawhide
Commit : 72cc379054d7d42c9bdd972b9c03005066ee7409
Author : Michel Lind <salimma@fedoraproject.org>
Date : 2026-11-02T21:26:13+00:00
Stats : +11/-2 in 1 file(s)
URL : https://src.fedoraproject.org/rpms/bluez/c/72cc379054d7d42c9bdd972b9c03005066ee7409?branch=rawhide
Log:
hid2hci: don't fail %post when udevadm is unavailable
The hid2hci %post scriptlet calls /sbin/udevadm, which is provided by
systemd-udev, but nothing requires that package. In a minimal root
(e.g. mock --postinst) the scriptlet fails with exit status 127 and the
transaction is reported as failed.
Retriggering USB devices is only a convenience so the new rule applies
to already-connected devices, so skip it when udevadm is not installed
and tolerate it failing (e.g. in containers with a read-only /sys).
Add an ordering hint so udevadm is available when both are installed
in the same transaction.
Assisted-by: Claude Code:claude-opus-5-5
---
diff --git a/bluez.spec b/bluez.spec
index 8b9e4a7..e202ddc 100644
--- a/bluez.spec
+++ b/bluez.spec
@@ -12,7 +12,7 @@
Name: bluez
Version: 5.87%{?shortcommit:^%{gitdate}git%{shortcommit}}
-Release: 3%{?dist}
+Release: 4%{?dist}
Summary: Bluetooth utilities
License: GPL-2.0-or-later
URL: http://www.bluez.org/
@@ -102,6 +102,8 @@ use in Bluetooth applications.
%package hid2hci
Summary: Put HID proxying bluetooth HCI's into HCI mode
Requires: bluez%{?_isa} = %{version}-%{release}
+# Order after udev when both are installed, without depending on it
+OrderWithRequires(post): systemd-udev
%description hid2hci
Most allinone PC's and bluetooth keyboard / mouse sets which include a
@@ -220,7 +222,11 @@ install emulator/btvirt ${RPM_BUILD_ROOT}/%{_libexecdir}/bluetooth/
%systemd_postun_with_restart bluetooth.service
%post hid2hci
-/sbin/udevadm trigger --subsystem-match=usb
+# udevadm is not installed in minimal roots (containers, mock)
+if command -v udevadm >/dev/null; then
+ # retrigger is best-effort, e.g. /sys may be read-only in containers
+ udevadm trigger --subsystem-match=usb || :
+fi
%post mesh
%systemd_user_post bluetooth-mesh.service
@@ -343,6 +349,9 @@ install emulator/btvirt ${RPM_BUILD_ROOT}/%{_libexecdir}/bluetooth/
%{_userunitdir}/obex.service
%changelog
+* Mon Nov 02 2026 Michel Lind <salimma@fedoraproject.org> - 5.87^20260918gitb5ed56d8c-4
+- hid2hci: don't fail %%post when udevadm is unavailable
+
* Fri Sep 18 2026 Peter Robinson <pbrobinson@fedoraproject.org> - 5.87^20260918gitb5ed56d8c-3
- Update to the latest b5ed56d8c snapshot
- Update the snapshot naming to current spec
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-02 22:00 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-02 22:00 [rpms/bluez] rawhide: hid2hci: don't fail %post when udevadm is unavailable Michel Lind
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox