use egetshell helper from user eclass
authorMike Frysinger <vapier@gentoo.org>
Sat, 26 Nov 2011 07:36:46 +0000 (07:36 +0000)
committerMike Frysinger <vapier@gentoo.org>
Sat, 26 Nov 2011 07:36:46 +0000 (07:36 +0000)
eclass/games.eclass

index aae12a302a65c51593168a3874f0af4db09f4cda..42b7822ee292c8272a26954276c2e7a87d671370 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2008 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/games.eclass,v 1.143 2011/03/22 17:20:50 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/games.eclass,v 1.144 2011/11/26 07:36:46 vapier Exp $
 
 # devlist: {vapier,wolf31o2,mr_bones_}@gentoo.org -> games@gentoo.org
 #
@@ -8,7 +8,7 @@
 # you better have a *good* reason why you're *not* using games.eclass
 # in a games-* ebuild
 
-inherit base multilib toolchain-funcs eutils
+inherit base multilib toolchain-funcs eutils user
 
 case ${EAPI:-0} in
        0|1) EXPORT_FUNCTIONS pkg_setup src_compile pkg_preinst pkg_postinst ;;
@@ -134,7 +134,7 @@ games_pkg_setup() {
        # Dear portage team, we are so sorry.  Lots of love, games team.
        # See Bug #61680
        [[ ${USERLAND} != "GNU" ]] && return 0
-       [[ $(getent passwd "${GAMES_USER_DED}" | cut -f7 -d:) == "/bin/false" ]] \
+       [[ $(egetshell "${GAMES_USER_DED}") == "/bin/false" ]] \
                && usermod -s /bin/bash "${GAMES_USER_DED}"
 }