public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: David Ward <david.ward@ll.mit.edu>
To: git-commits@fedoraproject.org
Subject: [rpms/NetworkManager] rawhide: spec: fix scriptlet dependencies
Date: Mon, 06 Jul 2026 07:29:26 GMT [thread overview]
Message-ID: <178332296624.1.5925800735361967634.rpms-NetworkManager-0c40505512b6@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/NetworkManager
Branch : rawhide
Commit : 0c40505512b66d37cc8e2965226fc7eab7bd8640
Author : David Ward <david.ward@ll.mit.edu>
Date : 2026-06-06T08:06:07-04:00
Stats : +8/-5 in 1 file(s)
URL : https://src.fedoraproject.org/rpms/NetworkManager/c/0c40505512b66d37cc8e2965226fc7eab7bd8640?branch=rawhide
Log:
spec: fix scriptlet dependencies
Adjust %postun to handle missing udev, in the same way %post does.
This permits installation inside a container without udev.
/usr/sbin/update-alternatives is needed for the initscripts-updown
subpackage only.
---
diff --git a/NetworkManager.spec b/NetworkManager.spec
index c8bec57..8cb2d64 100644
--- a/NetworkManager.spec
+++ b/NetworkManager.spec
@@ -168,10 +168,7 @@ Source10: 24-clat-auto.conf
Patch1: 0001-nmtui-fix-wrong-use-of-assertions-in-bond-page.patch
Requires(post): systemd
-Requires(post): systemd-udev
-Requires(post): /usr/sbin/update-alternatives
Requires(preun): systemd
-Requires(preun): /usr/sbin/update-alternatives
Requires(postun): systemd
Requires: dbus >= %{dbus_version}
@@ -556,6 +553,8 @@ Group: System Environment/Base
BuildArch: noarch
Requires: NetworkManager
Requires: /usr/bin/nmcli
+Requires(post): /usr/sbin/update-alternatives
+Requires(preun): /usr/sbin/update-alternatives
Obsoletes: NetworkManager < %{obsoletes_initscripts_updown}
%description initscripts-updown
@@ -837,8 +836,12 @@ fi
%postun
-/usr/bin/udevadm control --reload-rules || :
-/usr/bin/udevadm trigger --subsystem-match=net || :
+# skip triggering if udevd isn't even accessible, e.g. containers or
+# rpm-ostree-based systems
+if [ -S /run/udev/control ]; then
+ /usr/bin/udevadm control --reload-rules || :
+ /usr/bin/udevadm trigger --subsystem-match=net || :
+fi
%firewalld_reload
%systemd_postun %{systemd_units}
reply other threads:[~2026-07-06 7:29 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=178332296624.1.5925800735361967634.rpms-NetworkManager-0c40505512b6@fedoraproject.org \
--to=david.ward@ll.mit.edu \
--cc=git-commits@fedoraproject.org \
/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