diff options
Diffstat (limited to 'sys-fs/eudev/eudev-9999.ebuild')
-rw-r--r-- | sys-fs/eudev/eudev-9999.ebuild | 51 |
1 files changed, 16 insertions, 35 deletions
diff --git a/sys-fs/eudev/eudev-9999.ebuild b/sys-fs/eudev/eudev-9999.ebuild index a8c3469fe613..eb72776654db 100644 --- a/sys-fs/eudev/eudev-9999.ebuild +++ b/sys-fs/eudev/eudev-9999.ebuild @@ -1,8 +1,8 @@ # Copyright 1999- Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/eudev-9999.ebuild,v 1.28 2013/06/07 02:16:45 blueness Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/eudev/eudev-9999.ebuild,v 1.29 2013/06/09 11:00:15 blueness Exp $ -EAPI=5 +EAPI="5" KV_min=2.6.31 @@ -55,20 +55,11 @@ RDEPEND="${COMMON_DEPEND} PDEPEND=">=virtual/udev-180 openrc? ( >=sys-fs/udev-init-scripts-18 )" -udev_check_KV() -{ - if kernel_is lt ${KV_min//./ } - then - return 1 - fi - return 0 -} - pkg_pretend() { if ! use rule-generator; then ewarn - ewarn "As of 2013-01-29, eudev-9999 provides the new interface renaming functionality," + ewarn "As of 2013-01-29, ${P} provides the new interface renaming functionality," ewarn "as described in the URL below:" ewarn "http://www.freedesktop.org/wiki/Software/systemd/PredictableNetworkInterfaceNames" ewarn @@ -85,36 +76,25 @@ pkg_pretend() pkg_setup() { - # required kernel options - CONFIG_CHECK="~BLK_DEV_BSG ~DEVTMPFS ~!IDE ~INOTIFY_USER ~SIGNALFD ~!SYSFS_DEPRECATED ~!SYSFS_DEPRECATED_V2" - ERROR_DEVTMPFS="DEVTMPFS is not set in this kernel. Udev will not run." - linux-info_pkg_setup + get_running_version - if ! udev_check_KV; then - eerror - eerror "Your kernel version (${KV_FULL}) is too old to run ${P}" - eerror "It must be at least ${KV_min}!" - eerror - fi + # These are required kernel options, but we don't error out on them + # because you can build under one kernel and run under another. + CONFIG_CHECK="~BLK_DEV_BSG ~DEVTMPFS ~!IDE ~INOTIFY_USER ~SIGNALFD ~!SYSFS_DEPRECATED ~!SYSFS_DEPRECATED_V2" - KV_FULL_SRC=${KV_FULL} - get_running_version - if ! udev_check_KV - then - eerror - eerror "Your running kernel version (${KV_FULL}) is too old" - eerror "for this version of udev." - eerror "You must upgrade your kernel or downgrade udev." - eerror + if kernel_is lt ${KV_min//./ }; then + ewarn + ewarn "Your current running kernel version ${KV_FULL} is too old to run ${P}." + ewarn "Make sure to run udev under kernel version ${KV_min} or above." + ewarn fi } src_prepare() { # change rules back to group uucp instead of dialout for now - sed -e 's/GROUP="dialout"/GROUP="uucp"/' \ - -i rules/*.rules \ + sed -e 's/GROUP="dialout"/GROUP="uucp"/' -i rules/*.rules \ || die "failed to change group dialout to uucp" epatch_user @@ -201,8 +181,8 @@ pkg_postinst() rmdir "${EROOT}"dev/loop 2>/dev/null if [[ -d ${EROOT}dev/loop ]] then - ewarn "Please make sure you remove /dev/loop," - ewarn "else losetup may be confused when looking for unused devices." + ewarn "Please make sure you remove /dev/loop, else losetup" + ewarn "may be confused when looking for unused devices." fi # 64-device-mapper.rules now gets installed by sys-fs/device-mapper @@ -233,4 +213,5 @@ pkg_postinst() elog "For more information on eudev on Gentoo, writing udev rules, and" elog "fixing known issues visit:" elog " http://www.gentoo.org/doc/en/udev-guide.xml" + elog } |