direct-io.hg

changeset 7947:dd50b17dc60f

Changes check for "udev", so that it works on debian sid (that does not
have /sbin/udev anymore).

Signed-off-by: Murillo F. Bernardes <mfb@br.ibm.com>
author emellor@leeni.uk.xensource.com
date Mon Nov 21 17:03:21 2005 +0100 (2005-11-21)
parents ff18a169e866
children 27a2cb379c8f
files install.sh tools/check/check_hotplug
line diff
     1.1 --- a/install.sh	Mon Nov 21 16:56:39 2005 +0100
     1.2 +++ b/install.sh	Mon Nov 21 17:03:21 2005 +0100
     1.3 @@ -27,7 +27,10 @@ echo "Installing Xen from '$src' to '$ds
     1.4  cp -fdRL $src/etc/init.d/* $dst/etc/init.d/
     1.5  echo "All done."
     1.6  
     1.7 -if [ -x /sbin/udev ] && [ ! -z `/sbin/udev -V` ] && [ `/sbin/udev -V` -ge 059 ]; then
     1.8 +[ -x "$(which udevinfo)" ] && \
     1.9 +  UDEV_VERSION=$(udevinfo -V | sed -e 's/^.*\s\([0-9]\+\)[^0-9]*/\1/')
    1.10 +
    1.11 +if [ -n "$UDEV_VERSION" ] && [ $UDEV_VERSION -ge 059 ]; then
    1.12    cp -f $src/etc/udev/rules.d/*.rules $dst/etc/udev/rules.d/
    1.13  else
    1.14    cp -f $src/etc/hotplug/*.agent $dst/etc/hotplug/
     2.1 --- a/tools/check/check_hotplug	Mon Nov 21 16:56:39 2005 +0100
     2.2 +++ b/tools/check/check_hotplug	Mon Nov 21 17:03:21 2005 +0100
     2.3 @@ -6,8 +6,10 @@ function error {
     2.4     echo '  *** Check for the hotplug scripts (hotplug) FAILED'
     2.5     exit 1
     2.6  }
     2.7 +[ -x "$(which udevinfo)" ] && \
     2.8 +  UDEV_VERSION=$(udevinfo -V | sed -e 's/^.*\s\([0-9]\+\)[^0-9]*/\1/')
     2.9  
    2.10 -if [ -x /sbin/udev ] && [ ! -z `/sbin/udev -V` ] && [ `/sbin/udev -V` -ge 059 ]; then
    2.11 +if [ -n "$UDEV_VERSION" ] && [ $UDEV_VERSION -ge 059 ]; then
    2.12    exit 0
    2.13  fi
    2.14