[oe] [PATCH] shadow: added new package shadow-group. Fix for build with uclibc.
Khem Raj
raj.khem at gmail.com
Thu Jun 10 22:51:52 UTC 2010
On Wed, Jun 9, 2010 at 12:48 PM, Roman I Khimov <khimov at altell.ru> wrote:
> From: Vladimir Sorokin <sorokin at altell.ru>
>
> shadow-group contains utilities (sg, newgrp, gpasswd) for groups manipulating,
> useful when you only need things not provided by busybox.
>
> Signed-off-by: Vladimir Sorokin <sorokin at altell.ru>
> Signed-off-by: Roman I Khimov <khimov at altell.ru>
> ---
> recipes/shadow/shadow.inc | 32 +++++++++++++++++++++++++++++---
> 1 files changed, 29 insertions(+), 3 deletions(-)
>
> diff --git a/recipes/shadow/shadow.inc b/recipes/shadow/shadow.inc
> index 460930b..97a2e19 100644
> --- a/recipes/shadow/shadow.inc
> +++ b/recipes/shadow/shadow.inc
> @@ -13,7 +13,7 @@ DEPENDS += "${@base_contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
>
> PACKAGE_ARCH_${PN} = "${MACHINE_ARCH}"
>
> -INC_PR = "r14"
> +INC_PR = "r15"
>
> # Additional Policy files for PAM
> PAM_SRC_URI = " \
> @@ -42,8 +42,23 @@ EXTRA_OECONF += "\
> ${@base_contains('DISTRO_FEATURES', 'pam', '--with-libpam', '--without-libpam', d)} \
> "
>
> +EXTRA_OECONF_linux-uclibc += "\
> + --disable-account-tools-setuid \
> + --disable-shadowgrp \
> + --without-audit \
> + --without-selinux \
> + --without-libcrack \
> + --without-nscd \
> + ${@base_contains('DISTRO_FEATURES', 'pam', '--with-libpam', '--without-libpam', d)} \
> +"
> +
use EXTRA_OECONF_libc-uclibc
current override linux-uclibc will not work for ARM and SPE machines.
> CFLAGS += "-I../include"
>
> +PACKAGES =+ "${PN}-group"
> +RDEPENDS_${PN} += "${PN}-group"
> +
> +FILES_${PN}-group = "${bindir}/gpasswd ${bindir}/newgrp.shadow ${bindir}/sg"
> +
> do_configure_prepend () {
> export CONFIG_SITE="${CONFIG_SITE} ${B}/cachedpaths"
> cat <<END >${B}/cachedpaths
> @@ -107,7 +122,6 @@ pkg_postinst_${PN} () {
> update-alternatives --install ${bindir}/passwd passwd passwd.${PN} 200
> update-alternatives --install ${sbindir}/chpasswd chpasswd chpasswd.${PN} 200
> update-alternatives --install ${bindir}/chfn chfn chfn.${PN} 200
> - update-alternatives --install ${bindir}/newgrp newgrp newgrp.${PN} 200
> update-alternatives --install ${bindir}/chsh chsh chsh.${PN} 200
> update-alternatives --install ${base_bindir}/login login login.${PN} 200
> update-alternatives --install ${base_sbindir}/vipw vipw vipw.${PN} 200
> @@ -120,7 +134,19 @@ pkg_postinst_${PN} () {
> }
>
> pkg_prerm_${PN} () {
> - for i in passwd chpasswd chfn newgrp chsh login vipw vigr ; do
> + for i in passwd chpasswd chfn chsh login vipw vigr ; do
> + update-alternatives --remove $i $i.${PN}
> + done
> +}
> +
> +pkg_postinst_${PN}-group () {
> + touch /etc/login.defs
> + update-alternatives --install ${bindir}/newgrp newgrp newgrp.${PN} 200
> +}
> +
> +pkg_prerm_${PN}-group () {
> + for i in newgrp ; do
> update-alternatives --remove $i $i.${PN}
> done
> }
> +
> --
> 1.6.4.2
>
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel at lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>
More information about the Openembedded-devel
mailing list