/[gentoo-x86]/eclass/user.eclass
Gentoo

Diff of /eclass/user.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.12 Revision 1.13
1# Copyright 1999-2011 Gentoo Foundation 1# Copyright 1999-2011 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/user.eclass,v 1.12 2011/11/26 06:45:38 vapier Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/user.eclass,v 1.13 2011/11/26 06:50:27 vapier Exp $
4 4
5# @ECLASS: user.eclass 5# @ECLASS: user.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# base-system@gentoo.org (Linux) 7# base-system@gentoo.org (Linux)
8# Joe Jezak <josejx@gmail.com> (OS X) 8# Joe Jezak <josejx@gmail.com> (OS X)
153 if [[ ${eshell} == */false || ${eshell} == */nologin ]] ; then 153 if [[ ${eshell} == */false || ${eshell} == */nologin ]] ; then
154 eerror "Do not specify ${eshell} yourself, use -1" 154 eerror "Do not specify ${eshell} yourself, use -1"
155 die "Pass '-1' as the shell parameter" 155 die "Pass '-1' as the shell parameter"
156 fi 156 fi
157 else 157 else
158 for shell in /sbin/nologin /usr/sbin/nologin /bin/false /usr/bin/false /dev/null ; do 158 for eshell in /sbin/nologin /usr/sbin/nologin /bin/false /usr/bin/false /dev/null ; do
159 [[ -x ${ROOT}${shell} ]] && break 159 [[ -x ${ROOT}${eshell} ]] && break
160 done 160 done
161 161
162 if [[ ${shell} == "/dev/null" ]] ; then 162 if [[ ${eshell} == "/dev/null" ]] ; then
163 eerror "Unable to identify the shell to use, proceeding with userland default." 163 eerror "Unable to identify the shell to use, proceeding with userland default."
164 case ${USERLAND} in 164 case ${USERLAND} in
165 GNU) shell="/bin/false" ;; 165 GNU) eshell="/bin/false" ;;
166 BSD) shell="/sbin/nologin" ;; 166 BSD) eshell="/sbin/nologin" ;;
167 Darwin) shell="/usr/sbin/nologin" ;; 167 Darwin) eshell="/usr/sbin/nologin" ;;
168 *) die "Unable to identify the default shell for userland ${USERLAND}" 168 *) die "Unable to identify the default shell for userland ${USERLAND}"
169 esac 169 esac
170 fi 170 fi
171
172 eshell=${shell}
173 fi 171 fi
174 einfo " - Shell: ${eshell}" 172 einfo " - Shell: ${eshell}"
175 opts+=" -s ${eshell}" 173 opts+=" -s ${eshell}"
176 174
177 # handle homedir 175 # handle homedir

Legend:
Removed from v.1.12  
changed lines
  Added in v.1.13

  ViewVC Help
Powered by ViewVC 1.1.20