]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
fix(06dbus): do not hardcode path to dbus utils
authorAlexey Shabalin <shaba@altlinux.org>
Fri, 18 Dec 2020 02:01:39 +0000 (05:01 +0300)
committerJóhann B. Guðmundsson <johannbg@gmail.com>
Thu, 21 Jan 2021 16:53:30 +0000 (16:53 +0000)
modules.d/06dbus/module-setup.sh

index abf67a5b677c4bb595ce20aeba732fbf78ad2523..9a5c8121eaf130b450c1bf42fbec449e5e0d607e 100755 (executable)
@@ -26,20 +26,20 @@ install() {
   inst_multiple \
     $systemdsystemunitdir/dbus.service \
     $systemdsystemunitdir/dbus.socket \
-    /usr/bin/dbus-send \
-    /usr/bin/busctl
+    dbus-send \
+    busctl
   adjust_dependencies $systemdsystemunitdir/dbus.service
 
-  if [[ -e /usr/bin/dbus-daemon ]]; then
+  if type -P dbus-daemon >/dev/null; then
     inst_multiple \
-      /usr/bin/dbus-daemon
+      dbus-daemon
   fi
 
-  if [[ -e /usr/bin/dbus-broker ]]; then
+  if type -P dbus-broker >/dev/null; then
     inst_multiple \
       $systemdsystemunitdir/dbus-broker.service \
-      /usr/bin/dbus-broker \
-      /usr/bin/dbus-broker-launch
+      dbus-broker \
+      dbus-broker-launch
     adjust_dependencies $systemdsystemunitdir/dbus-broker.service
   fi