GRMLBASE/93-update-usbids: test for new update-usbids location in /usr/sbin
authorMichael Prokop <mika@grml.org>
Wed, 22 Nov 2017 13:12:06 +0000 (14:12 +0100)
committerMichael Prokop <mika@grml.org>
Wed, 22 Nov 2017 13:12:06 +0000 (14:12 +0100)
"Recent" versions of usbutils ship the update-usbids
binary in /usr/sbin and no longer in /usr/bin.

etc/grml/fai/config/scripts/GRMLBASE/93-update-usbids

index 6fc4a73..d2972d3 100755 (executable)
@@ -16,8 +16,8 @@ set -e
 
 [ -x $target/usr/bin/timeout ] && TIMEOUT="10" || TIMEOUT=""
 
-if ! [ -x $target/usr/bin/update-usbids ] ; then
-  echo "Warning: update-usbids not installed"
+if ! [ -x "${target}/usr/sbin/update-usbids" ] && ! [ -x "${target}/usr/bin/update-usbids" ] ; then
+  echo "Warning: update-usbids not installed (neither /usr/sbin/update-usbids nor /usr/bin/update-usbids exists)"
   exit 0
 fi