Fix buildsystem to detect udev > version 124
PATCH 1/1 Fix buildsystem to detect udev > version 124
udev removed the udevinfo symlink from versions higher than 123 and xens build-system could not detect if udev is in place and has the required version. Attached patch fixes this.
tools/hotplug/Linux/Makefile +7 -1
@@ -28,6 +28,12 @@ XEN_SCRIPT_DATA += vtpm-migration.sh vtp XEN_HOTPLUG_DIR = /etc/hotplug XEN_HOTPLUG_SCRIPTS = xen-backend.agent +ifeq ($(shell [ -x /sbin/udevadm ] && echo 1),1) +UDEVINFO = /sbin/udevadm +else +UDEVINFO = /usr/bin/udevinfo +endif + UDEV_RULES_DIR = /etc/udev UDEV_RULES = xen-backend.rules xend.rules
@@ -36,7 +43,7 @@ DE = $(if $(DESTDIR),$(shell readlink -f ifeq ($(findstring $(DI),$(DE)),$(DI)) HOTPLUGS=install-hotplug install-udev else -ifeq ($(shell [ -x /usr/bin/udevinfo ] && [ `/usr/bin/udevinfo -V | sed -e 's/^[^0-9]* \([0-9]\{1,\}\)[^0-9]\{0,\}/\1/'` -ge 059 ] && echo 1),1) +ifeq ($(shell [ -x $(UDEVINFO) -a `$(UDEVINFO) -V | sed -e 's/^[^0-9]* \([0-9]\{1,\}\)[^0-9]\{0,\}/\1/'` -ge 059 ] && echo 1),1) HOTPLUGS=install-udev else HOTPLUGS=install-hotplug
tools/check/check_udev +4 -2
@@ -8,8 +8,10 @@ OpenBSD|NetBSD|FreeBSD) has_or_fail vnconfig ;; Linux) - has_or_fail udevinfo - [ "`udevinfo -V | awk '{print $NF}'`" -ge 59 ] 2>/dev/null || \ + has /sbin/udevadm && udevver=`/sbin/udevadm -V` + [ -z "$udevver" ] && has_or_fail udevinfo && \ + udevver=`udevinfo -V | awk '{print $NF}'` + [ "$udevver" -ge 59 ] 2>/dev/null || \ has hotplug || \ fail "udev is too old, upgrade to version 59 or later" ;;
install.sh +2 -0
@@ -30,6 +30,8 @@ echo "Installing Xen from '$src' to '$ds [ -x "$(which udevinfo)" ] && \ UDEV_VERSION=$(udevinfo -V | sed -e 's/^[^0-9]* \([0-9]\{1,\}\)[^0-9]\{0,\}/\1/') +[ -z "$UDEV_VERSION" -a -x /sbin/udevadm ] && UDEV_VERSION=$(/sbin/udevadm -V) + if [ -n "$UDEV_VERSION" ] && [ $UDEV_VERSION -ge 059 ]; then echo " - installing for udev-based system" rm -rf "$tmp/etc/hotplug"
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 3 lines · Marc - A. Dahlhaus [ Administration | Westermann GmbH ]
udev removed the udevinfo symlink from versions higher than 123 and xens build-system could not detect if udev is in place and has the required version. Attached patch fixes this.
I am building xen-3.4-test tree on Ubuntu 9.04. Booting process reports error like:
....
udev: starting version 141
udev: deprecated sysfs layout; update the kernel or disable CONFIG_SYSFS_DEPRECATED;....
....
Is that true that your patch is to fix this problem?
I tried, but the problem still persists. Any idea?
Thanks,
J
Hello Jun,
(adding list back to CC)
Am Donnerstag, den 25.06.2009, 16:27 +0900 schrieb Jun Koi:
Quoted 30 lines
Quoted 18 lines · Marc - A. Dahlhaus [ Administration | Westermann GmbH ]
Hello Jun,
Am Donnerstag, den 25.06.2009, 14:10 +0900 schrieb Jun Koi:
Quoted 15 lines
Quoted 3 lines · Marc - A. Dahlhaus [ Administration | Westermann GmbH ]
udev removed the udevinfo symlink from versions higher than 123 and xens build-system could not detect if udev is in place and has the required version. Attached patch fixes this.
I am building xen-3.4-test tree on Ubuntu 9.04. Booting process reports error like:
....
udev: starting version 141
udev: deprecated sysfs layout; update the kernel or disableCONFIG_SYSFS_DEPRECATED;....
....Quoted 9 lines
Quoted 1 line
Is that true that your patch is to fix this problem?
No!
What you hit here is a deprecated sysfs layout of your running kernel that udev will not support for some functionality it has. You need to upgrade to a newer kernel to get around this error. Please read udevs documentation for more details about this...
Quoted 7 lines
Yes, but the problem is that I want to run 2.6.18.8-xen kernel :-(
I am not sure if I downgrade Ubuntu to 8.10 would solve the problem. This is really frustrated!
Thanks,
J
You could downgrade your udev or upgrade your kernel (which i would prefer here) but i doubt that you really need the functionality that udev only gets out of newer sysfs layouts.
By the way, the warning doesn't hurt at this point as your system runs fine...
Just keep in mind that 2.6.18 kernel is stoneaged and that a newer kernel would get around this warning.
have fun,
Marc