diff options
author | 2011-06-02 20:26:43 +0000 | |
---|---|---|
committer | 2011-06-02 20:26:43 +0000 | |
commit | 5f24166a75a9295222dac808d586122c21bb3db5 (patch) | |
tree | e07e490bc3a84d41fa6e64041f2ff558d6edc6ac /sys-fs | |
parent | Version bump (diff) | |
download | gentoo-2-5f24166a75a9295222dac808d586122c21bb3db5.tar.gz gentoo-2-5f24166a75a9295222dac808d586122c21bb3db5.tar.bz2 gentoo-2-5f24166a75a9295222dac808d586122c21bb3db5.zip |
Add udev to the sysinit runlevel for the stages, bug #369037
(Portage version: 2.2.0_alpha37/cvs/Linux i686)
Diffstat (limited to 'sys-fs')
-rw-r--r-- | sys-fs/udev/ChangeLog | 6 | ||||
-rw-r--r-- | sys-fs/udev/udev-164-r2.ebuild | 25 | ||||
-rw-r--r-- | sys-fs/udev/udev-9999.ebuild | 25 |
3 files changed, 39 insertions, 17 deletions
diff --git a/sys-fs/udev/ChangeLog b/sys-fs/udev/ChangeLog index cd014ba4c3de..d5bc9f1652f3 100644 --- a/sys-fs/udev/ChangeLog +++ b/sys-fs/udev/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for sys-fs/udev # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.576 2011/06/01 11:43:21 klausman Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/ChangeLog,v 1.577 2011/06/02 20:26:43 williamh Exp $ + + 02 Jun 2011; William Hubbs <williamh@gentoo.org> udev-164-r2.ebuild, + udev-9999.ebuild: + Add udev to the sysinit runlevel for the stages, bug #369037 01 Jun 2011; Tobias Klausmann <klausman@gentoo.org> udev-164-r2.ebuild: Stable on alpha, bug #352827 diff --git a/sys-fs/udev/udev-164-r2.ebuild b/sys-fs/udev/udev-164-r2.ebuild index 746e3ca503b4..2c85dd524778 100644 --- a/sys-fs/udev/udev-164-r2.ebuild +++ b/sys-fs/udev/udev-164-r2.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-164-r2.ebuild,v 1.4 2011/06/01 11:43:21 klausman Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-164-r2.ebuild,v 1.5 2011/06/02 20:26:43 williamh Exp $ EAPI="1" @@ -374,14 +374,24 @@ restart_udevd() { } postinst_init_scripts() { - # FIXME: we may need some code that detects if this is a system bootstrap - # and auto-enables udev then - # + local enable_postmount=false + # FIXME: inconsistent handling of init-scripts here # * udev is added to sysinit in openrc-ebuild # * we add udev-postmount to default in here # + # If we are building stages, add udev to the sysinit runlevel automatically. + if use build + then + if [[ -x "${ROOT}"/etc/init.d/udev \ + && -d "${ROOT}"/etc/runlevels/sysinit ]] + then + ln -s "${ROOT}"/etc/init.d/udev "${ROOT}"/etc/runlevels/sysinit/udev + fi + enable_postmount=true + fi + # migration to >=openrc-0.4 if [[ -e "${ROOT}"/etc/runlevels/sysinit && ! -e "${ROOT}"/etc/runlevels/sysinit/udev ]] then @@ -400,11 +410,10 @@ postinst_init_scripts() { # already enabled? [[ -e "${ROOT}"/etc/runlevels/default/udev-postmount ]] && return - local enable_postmount=0 - [[ -e "${ROOT}"/etc/runlevels/sysinit/udev ]] && enable_postmount=1 - [[ "${ROOT}" = "/" && -d /dev/.udev/ ]] && enable_postmount=1 + [[ -e "${ROOT}"/etc/runlevels/sysinit/udev ]] && enable_postmount=true + [[ "${ROOT}" = "/" && -d /dev/.udev/ ]] && enable_postmount=true - if [[ ${enable_postmount} = 1 ]] + if $enable_postmount then local initd=udev-postmount diff --git a/sys-fs/udev/udev-9999.ebuild b/sys-fs/udev/udev-9999.ebuild index a6a70094cd79..c9f3816c7a53 100644 --- a/sys-fs/udev/udev-9999.ebuild +++ b/sys-fs/udev/udev-9999.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-9999.ebuild,v 1.37 2011/05/14 14:00:34 zzam Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/udev/udev-9999.ebuild,v 1.38 2011/06/02 20:26:43 williamh Exp $ EAPI="1" @@ -357,14 +357,24 @@ restart_udevd() { } postinst_init_scripts() { - # FIXME: we may need some code that detects if this is a system bootstrap - # and auto-enables udev then - # + local enable_postmount=false + # FIXME: inconsistent handling of init-scripts here # * udev is added to sysinit in openrc-ebuild # * we add udev-postmount to default in here # + # If we are building stages, add udev to the sysinit runlevel automatically. + if use build + then + if [[ -x "${ROOT}"/etc/init.d/udev \ + && -d "${ROOT}"/etc/runlevels/sysinit ]] + then + ln -s "${ROOT}"/etc/init.d/udev "${ROOT}"/etc/runlevels/sysinit/udev + fi + enable_postmount=true + fi + # migration to >=openrc-0.4 if [[ -e "${ROOT}"/etc/runlevels/sysinit && ! -e "${ROOT}"/etc/runlevels/sysinit/udev ]] then @@ -383,11 +393,10 @@ postinst_init_scripts() { # already enabled? [[ -e "${ROOT}"/etc/runlevels/default/udev-postmount ]] && return - local enable_postmount=0 - [[ -e "${ROOT}"/etc/runlevels/sysinit/udev ]] && enable_postmount=1 - [[ "${ROOT}" = "/" && -d /dev/.udev/ ]] && enable_postmount=1 + [[ -e "${ROOT}"/etc/runlevels/sysinit/udev ]] && enable_postmount=true + [[ "${ROOT}" = "/" && -d /dev/.udev/ ]] && enable_postmount=true - if [[ ${enable_postmount} = 1 ]] + if $enable_postmount then local initd=udev-postmount |