]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
dm: check for presence of dmsetup
authorHarald Hoyer <harald@redhat.com>
Fri, 8 Jun 2012 10:41:49 +0000 (12:41 +0200)
committerHarald Hoyer <harald@redhat.com>
Fri, 8 Jun 2012 10:41:49 +0000 (12:41 +0200)
modules.d/90dm/dm-shutdown.sh
modules.d/90dm/module-setup.sh

index 80d80d0efa189efa43c1c50e366f25cbf48de7e3..bf976376a6441509d5f1b2ecb38754c2a8652edd 100755 (executable)
@@ -13,4 +13,9 @@ _do_dm_shutdown() {
     fi
     return $ret
 }
-_do_dm_shutdown $1
+
+if command -v dmsetup >/dev/null; then
+    _do_dm_shutdown $1
+else
+    :
+fi
index bac854afb3094b296961012982abe08e3f1ebc18..4209537e116bb7c0892a80a9af5a643ca88b14e2 100755 (executable)
@@ -3,6 +3,7 @@
 # ex: ts=8 sw=4 sts=4 et filetype=sh
 
 check() {
+    type -P dmsetup >/dev/null || return 1
     return 255
 }