diff options
author | Matthias Schwarzott <zzam@gentoo.org> | 2008-03-17 22:19:14 +0000 |
---|---|---|
committer | Matthias Schwarzott <zzam@gentoo.org> | 2008-03-17 22:19:14 +0000 |
commit | 858dacf07bb4ff55e7334623730363c48f1d44f3 (patch) | |
tree | bb8352bcd10bda9a687d5219d3e0774a583d9675 /sys-fs | |
parent | some cleaups + removed old versions. (diff) | |
download | historical-858dacf07bb4ff55e7334623730363c48f1d44f3.tar.gz historical-858dacf07bb4ff55e7334623730363c48f1d44f3.tar.bz2 historical-858dacf07bb4ff55e7334623730363c48f1d44f3.zip |
Version bump. udev works best with Kernel >=2.6.18 now. Fixes Bug #209733, Bug #208815 and more other stuff.
Package-Manager: portage-2.1.4.4
Diffstat (limited to 'sys-fs')
-rw-r--r-- | sys-fs/udev/ChangeLog | 8 | ||||
-rw-r--r-- | sys-fs/udev/Manifest | 10 | ||||
-rw-r--r-- | sys-fs/udev/udev-119.ebuild | 350 |
3 files changed, 363 insertions, 5 deletions
diff --git a/sys-fs/udev/ChangeLog b/sys-fs/udev/ChangeLog index 5de85b77868b..a1bc5e061c06 100644 --- a/sys-fs/udev/ChangeLog +++ b/sys-fs/udev/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for sys-fs/udev # Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.371 2008/02/08 10:39:24 zzam Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.372 2008/03/17 22:19:14 zzam Exp $ + +*udev-119 (17 Mar 2008) + + 17 Mar 2008; Matthias Schwarzott <zzam@gentoo.org> +udev-119.ebuild: + Version bump. udev works best with Kernel >=2.6.18 now. Fixes Bug #209733, + Bug #208815 and more other stuff. *udev-118-r3 (08 Feb 2008) diff --git a/sys-fs/udev/Manifest b/sys-fs/udev/Manifest index ff95c59b9d38..3081e82f9fca 100644 --- a/sys-fs/udev/Manifest +++ b/sys-fs/udev/Manifest @@ -73,6 +73,7 @@ DIST udev-115.tar.bz2 198893 RMD160 bf72a4e20b9ba50a5b0c3da09f77e67ec819b9fa SHA DIST udev-116.tar.bz2 199112 RMD160 8c084fe4034e007ca66f0c102f41e9ada17bc46a SHA1 d0c2782e7052289f915a61f9f292e70eac01ffd2 SHA256 a28b5dc28e0e6b1e812e5b051205eaf3d9c3d299f8aecf3f915df1b76cb3b8a2 DIST udev-117.tar.bz2 199961 RMD160 bce663cb6c2bdd449b67122e01c8da106feb7a1f SHA1 7b75e632b631445af863ce8a70557944f5093c58 SHA256 42ffd09f50f6a0e16d832dbe0e8f1b2aa558b8982d1dd767ddb23365f9736dee DIST udev-118.tar.bz2 199852 RMD160 1adcd06bbf8ecae59890981b38415eb4b72109c1 SHA1 3fad0dd51b7fd44108b68fd6b51d4d54011b16b9 SHA256 6a6af86778d7ee9d798d2822a2663c826478c89a7dae169ff9d6c453314788c4 +DIST udev-119.tar.bz2 201836 RMD160 b827a1a5697fa32e43dec0a08081e92e2eddda52 SHA1 ae0d35a99e9f1983c1069378fd9d561de26cee7e SHA256 3bbab9b7f5e733a4c0a1da164e58511608014a3c5f0a4e8487c90d10c2a57349 EBUILD udev-104-r12.ebuild 9575 RMD160 90e22d3b7c14fa689aee6e1fc9a4db3c3c4b1d7c SHA1 b17f7d0e4c3dd7d9d4cba2da8fb264f85d944ed6 SHA256 3cab1b3a2e6f09b8d4f641b6330b895e88eba8ba85ea78c7d650111f01ae6011 EBUILD udev-104-r13.ebuild 9759 RMD160 bd917ca461d1b41f5c70e76bb2fb91dd6e915ec8 SHA1 37036035973ba80ee4b2026e17cd3c0cc925fb63 SHA256 182bc888581ad607929955a3db83458659a8f0e4b285f2d7ef9d8a42a97be8d1 EBUILD udev-111-r1.ebuild 10326 RMD160 904b5df2788831b381bb6db3d4e66365a273883b SHA1 5e0f2f99ea0eb63f100e081ebdd5d539e3f2d8c9 SHA256 edb809a58e7e54d974d96ee3999b3fff0313bab1052fe05d06e805f85f8f5bd3 @@ -97,12 +98,13 @@ EBUILD udev-118-r1.ebuild 9546 RMD160 7fe0e1ecc4b424e7ad13ca3eaff4927af34e84da S EBUILD udev-118-r2.ebuild 9843 RMD160 344071fb8d41c9348286f12464abc56b74bd61f0 SHA1 05a4e160da6e112c41b3f83996f4863adbd5450f SHA256 dc4edd2ed5ceb87c50e8bd4126ec30472e3ecbd45b89dd48607995e51bca34d8 EBUILD udev-118-r3.ebuild 9843 RMD160 40c512642638fabe7b157365040001e142075af5 SHA1 ebf37f3821b233b97abbc11b02be17fe4f670897 SHA256 ae8ce0391dae4d381f76dc8ca005bcc2236f7fc8f3c481146a504373d7925c28 EBUILD udev-118.ebuild 9544 RMD160 72c7e3ea74d0e3681a7a76310f1f233454b247d1 SHA1 9689ed1182a612d4b31a3fbf344a3aa20a10353b SHA256 b51b5742df8e4c5e93ede735d3967cc922e25e0f3ddf4ef2df21b5b12f28c15e -MISC ChangeLog 74869 RMD160 5ba10f9e98482b8426cb788390071903256b52dd SHA1 5046bc829b89f07605c6f0138f990960d7ddc8f4 SHA256 0ee37ae442e39900b32c317548b3eec9172ce5949adbc039c12599653c22641e +EBUILD udev-119.ebuild 9863 RMD160 ccbc3432ac1efe0ec5dc522ff830a5b60405a2eb SHA1 ed38dd0c1272e5c0ae73c36313e5b68112d67659 SHA256 eb8ede8fa8fe38c1f887640d0492e4b488fd327958a09e7ce07da40d1e77a3f6 +MISC ChangeLog 75079 RMD160 3e5825eee9f77da32968b0bb046c29d14a56ba8a SHA1 080a2ac853536f931da46410b4b253b0e7837e6b SHA256 7d26946c6d85534c9591282163b4822a976f47ce8a311e9d9603cefb0cc3309f MISC metadata.xml 447 RMD160 d1ba09bd6a434b25c718673de9258cc544e090be SHA1 70c43d2863c09958849bfce8c5bb97d406a0662b SHA256 a9881de1424ac71191111bd30c7c1253589673b0cdce13c352204f1499e9d884 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.7 (GNU/Linux) -iD8DBQFHrDFlt2vP6XvVdOcRAhZ5AJ93jI/EaGAdXn3m7zFNGjisg6bN5ACeLFTT -W/vbOitfTjt/Cn+nMOQLJsQ= -=x2dR +iD8DBQFH3u5rt2vP6XvVdOcRAg/DAJ4q511QLeQZ4uWAjSSdySl19mJcXACeP5/t +wMwVb0H/ANye76yPjYUImT0= +=ORk5 -----END PGP SIGNATURE----- diff --git a/sys-fs/udev/udev-119.ebuild b/sys-fs/udev/udev-119.ebuild new file mode 100644 index 000000000000..950f96ea1758 --- /dev/null +++ b/sys-fs/udev/udev-119.ebuild @@ -0,0 +1,350 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-119.ebuild,v 1.1 2008/03/17 22:19:14 zzam Exp $ + +inherit eutils flag-o-matic multilib toolchain-funcs versionator + +DESCRIPTION="Linux dynamic and persistent device naming support (aka userspace devfs)" +HOMEPAGE="http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html" +SRC_URI="mirror://kernel/linux/utils/kernel/hotplug/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" +IUSE="selinux" + +DEPEND="selinux? ( sys-libs/libselinux )" +RDEPEND="!sys-apps/coldplug + !<sys-fs/device-mapper-1.02.19-r1" +RDEPEND="${DEPEND} ${RDEPEND} + >=sys-apps/baselayout-1.12.5" +# We need the lib/rcscripts/addon support +PROVIDE="virtual/dev-manager" + +pkg_setup() { + udev_helper_dir="/$(get_libdir)/udev" + + myconf= + extras="extras/ata_id \ + extras/cdrom_id \ + extras/edd_id \ + extras/firmware \ + extras/floppy \ + extras/path_id \ + extras/scsi_id \ + extras/usb_id \ + extras/volume_id \ + extras/collect \ + extras/rule_generator" + + use selinux && myconf="${myconf} USE_SELINUX=true" + + # comparing kernel version without linux-info.eclass to not pull + # virtual/linux-sources + + local KV=$(uname -r) + local KV_MAJOR=$(get_major_version ${KV}) + local KV_MINOR=$(get_version_component_range 2 ${KV}) + local KV_MICRO=$(get_version_component_range 3 ${KV}) + + local ok=0 + if [[ ${KV_MAJOR} == 2 && ${KV_MINOR} == 6 && ${KV_MICRO} -ge 18 ]] + then + ok=1 + fi + + if [[ ${ok} == 0 ]] + then + ewarn + ewarn "${P} does not support Linux kernel before version 2.6.15!" + ewarn "If you want to use udev reliable you should update" + ewarn "to at least kernel version 2.6.18!" + ewarn + ebeep + fi +} + +sed_helper_dir() { + sed -e "s#/lib/udev#${udev_helper_dir}#" -i "$@" +} + +src_unpack() { + unpack ${A} + + cd "${S}" + + # patches go here... + + # No need to clutter the logs ... + sed -ie '/^DEBUG/ c\DEBUG = false' Makefile + # Do not use optimization flags from the package + sed -ie 's|$(OPTIMIZATION)||g' Makefile + # Do not require xmlto to refresh manpages + sed -ie 's|$(MAN_PAGES)||g' Makefile + + # Make sure there is no sudden changes to upstream rules file + # (more for my own needs than anything else ...) + MD5=$(md5sum < "${S}/etc/udev/rules.d/50-udev-default.rules") + MD5=${MD5/ -/} + if [[ ${MD5} != db44f7e02100f57a555d48e2192c3f8d ]] + then + echo + eerror "50-udev-default.rules has been updated, please validate!" + die "50-udev-default.rules has been updated, please validate!" + fi + + sed_helper_dir \ + etc/udev/rules.d/50-udev-default.rules \ + extras/rule_generator/write_*_rules \ + udev_rules_parse.c \ + udev_rules.c + + # Use correct multilib dir + sed -i extras/volume_id/lib/Makefile \ + -e "/ =/s-/lib-/$(get_libdir)-" +} + +src_compile() { + filter-flags -fprefetch-loop-arrays + + if [[ -z ${extras} ]]; then + eerror "Variable extras is unset!" + eerror "It seems you suffer from Bug #190994" + die "Variable extras is unset!" + fi + + # Not everyone has full $CHOST-{ld,ar,etc...} yet + local mycross="" + type -p ${CHOST}-ar && mycross=${CHOST}- + + emake \ + EXTRAS="${extras}" \ + libudevdir=${udev_helper_dir} \ + CROSS_COMPILE=${mycross} \ + OPTFLAGS="" \ + ${myconf} || die "compiling udev failed" +} + +src_install() { + into / + emake \ + DESTDIR="${D}" \ + libudevdir=${udev_helper_dir} \ + EXTRAS="${extras}" \ + ${myconf} \ + install || die "make install failed" + + exeinto "${udev_helper_dir}" + newexe "${FILESDIR}"/net-118-r1.sh net.sh || die "net.sh not installed properly" + newexe "${FILESDIR}"/move_tmp_persistent_rules-112-r1.sh move_tmp_persistent_rules.sh \ + || die "move_tmp_persistent_rules.sh not installed properly" + doexe "${FILESDIR}"/write_root_link_rule \ + || die "write_root_link_rule not installed properly" + newexe "${FILESDIR}"/shell-compat-118-r3.sh shell-compat.sh \ + || die "shell-compat.sh not installed properly" + + keepdir "${udev_helper_dir}"/state + keepdir "${udev_helper_dir}"/devices + + # create symlinks for these utilities to /sbin + # where multipath-tools expect them to be (Bug #168588) + dosym "..${udev_helper_dir}/vol_id" /sbin/vol_id + dosym "..${udev_helper_dir}/scsi_id" /sbin/scsi_id + + # vol_id library (needed by mount and HAL) + into / + rm "${D}/$(get_libdir)"/libvolume_id.so* 2>/dev/null + dolib extras/volume_id/lib/*.so* || die "Failed installing libvolume_id.so" + into /usr + dolib extras/volume_id/lib/*.a || die "Failed installing libvolume_id.a" + + # handle static linking bug #4411 + rm -f "${D}/usr/$(get_libdir)/libvolume_id.so" + gen_usr_ldscript libvolume_id.so + + # Add gentoo stuff to udev.conf + echo "# If you need to change mount-options, do it in /etc/fstab" \ + >> "${D}"/etc/udev/udev.conf + + # Now installing rules + cd etc/udev + insinto /etc/udev/rules.d/ + + # Our rules files + doins gentoo/??-*.rules + doins packages/40-alsa.rules + + # Adding arch specific rules + if [[ -f packages/40-${ARCH}.rules ]] + then + doins "packages/40-${ARCH}.rules" + fi + cd "${S}" + + # our udev hooks into the rc system + insinto /$(get_libdir)/rcscripts/addons + newins "${FILESDIR}"/udev-start-118-r2.sh udev-start.sh + newins "${FILESDIR}"/udev-stop-118-r2.sh udev-stop.sh + + # The udev-post init-script + newinitd "${FILESDIR}"/udev-postmount-initd-111-r2 udev-postmount + + insinto /etc/modprobe.d + newins "${FILESDIR}"/blacklist-110 blacklist + doins "${FILESDIR}"/pnp-aliases + + # convert /lib/udev to real used dir + sed_helper_dir \ + "${D}/$(get_libdir)"/rcscripts/addons/*.sh \ + "${D}"/etc/init.d/udev* \ + "${D}"/etc/modprobe.d/* + + # documentation + dodoc ChangeLog FAQ README TODO RELEASE-NOTES + dodoc docs/{overview,udev_vs_devfs} + + cd docs/writing_udev_rules + mv index.html writing_udev_rules.html + dohtml *.html + + cd "${S}" + + newdoc extras/volume_id/README README_volume_id + + echo "CONFIG_PROTECT_MASK=\"/etc/udev/rules.d\"" > 20udev + doenvd 20udev +} + +pkg_preinst() { + if [[ -d ${ROOT}/lib/udev-state ]] + then + mv -f "${ROOT}"/lib/udev-state/* "${D}"/lib/udev/state/ + rm -r "${ROOT}"/lib/udev-state + fi + + if [[ -f ${ROOT}/etc/udev/udev.config && + ! -f ${ROOT}/etc/udev/udev.rules ]] + then + mv -f "${ROOT}"/etc/udev/udev.config "${ROOT}"/etc/udev/udev.rules + fi + + # delete the old udev.hotplug symlink if it is present + if [[ -h ${ROOT}/etc/hotplug.d/default/udev.hotplug ]] + then + rm -f "${ROOT}"/etc/hotplug.d/default/udev.hotplug + fi + + # delete the old wait_for_sysfs.hotplug symlink if it is present + if [[ -h ${ROOT}/etc/hotplug.d/default/05-wait_for_sysfs.hotplug ]] + then + rm -f "${ROOT}"/etc/hotplug.d/default/05-wait_for_sysfs.hotplug + fi + + # delete the old wait_for_sysfs.hotplug symlink if it is present + if [[ -h ${ROOT}/etc/hotplug.d/default/10-udev.hotplug ]] + then + rm -f "${ROOT}"/etc/hotplug.d/default/10-udev.hotplug + fi + + # is there a stale coldplug initscript? (CONFIG_PROTECT leaves it behind) + coldplug_stale="" + if [[ -f ${ROOT}/etc/init.d/coldplug ]] + then + coldplug_stale="1" + fi +} + +pkg_postinst() { + # people want reminders, I'll give them reminders. Odds are they will + # just ignore them anyway... + + if [[ ${coldplug_stale} == 1 ]] + then + ewarn "A stale coldplug init script found. You should run:" + ewarn + ewarn " rc-update del coldplug" + ewarn " rm -f /etc/init.d/coldplug" + ewarn + ewarn "udev now provides its own coldplug functionality." + fi + + # delete 40-scsi-hotplug.rules - all integrated in 50-udev.rules + if has_version "=sys-fs/udev-103-r3" && + [[ -e ${ROOT}/etc/udev/rules.d/40-scsi-hotplug.rules ]] + then + ewarn "Deleting stray 40-scsi-hotplug.rules" + ewarn "installed by sys-fs/udev-103-r3" + rm -f "${ROOT}"/etc/udev/rules.d/40-scsi-hotplug.rules + fi + + # Removing some device-nodes we thought we need some time ago + if [[ -d ${ROOT}/lib/udev/devices ]] + then + rm -f "${ROOT}"/lib/udev/devices/{null,zero,console,urandom} + fi + + # Removing some old file + if has_version "<sys-fs/udev-104-r5" + then + rm -f "${ROOT}"/etc/dev.d/net/hotplug.dev + rmdir --ignore-fail-on-non-empty "${ROOT}"/etc/dev.d/net 2>/dev/null + fi + + if has_version "<sys-fs/udev-106-r5" && + [[ -e ${ROOT}/etc/udev/rules.d/95-net.rules ]] + then + rm -f "${ROOT}"/etc/udev/rules.d/95-net.rules + fi + + # Try to remove /etc/dev.d as that is obsolete + if [[ -d ${ROOT}/etc/dev.d ]] + then + rmdir --ignore-fail-on-non-empty "${ROOT}"/etc/dev.d/default "${ROOT}"/etc/dev.d 2>/dev/null + if [[ -d ${ROOT}/etc/dev.d ]] + then + ewarn "You still have the directory /etc/dev.d on your system." + ewarn "This is no longer used by udev and can be removed." + fi + fi + + # 64-device-mapper.rules now gets installed by sys-fs/device-mapper + # remove it if user don't has sys-fs/device-mapper installed + if has_version "<sys-fs/udev-113" && + [[ -f ${ROOT}/etc/udev/rules.d/64-device-mapper.rules ]] && + ! has_version sys-fs/device-mapper + then + rm -f "${ROOT}"/etc/udev/rules.d/64-device-mapper.rules + einfo "Removed unneeded file 64-device-mapper.rules" + fi + + if [[ ${ROOT} == / ]] + then + # check if root of init-process is identical to ours + if [[ -r /proc/1/root && /proc/1/root/ -ef /proc/self/root/ ]] + then + einfo "restarting udevd now." + if [[ -n $(pidof udevd) ]] + then + killall -15 udevd &>/dev/null + sleep 1 + killall -9 udevd &>/dev/null + fi + /sbin/udevd --daemon + fi + fi + + ewarn "If you build an initramfs including udev, then please" + ewarn "make sure that the /sbin/udevadm binary gets included," + ewarn "as the helper apps udevinfo, udevtrigger, ... are now" + ewarn "only symlinks to udevadm." + + ewarn + ewarn "mount options for directory /dev are no longer" + ewarn "set in /etc/udev/udev.conf, but in /etc/fstab" + ewarn "as for other directories." + + elog + elog "For more information on udev on Gentoo, writing udev rules, and" + elog " fixing known issues visit:" + elog " http://www.gentoo.org/doc/en/udev-guide.xml" +} |