diff options
author | Diego Elio Pettenò <flameeyes@gentoo.org> | 2005-07-04 12:50:47 +0000 |
---|---|---|
committer | Diego Elio Pettenò <flameeyes@gentoo.org> | 2005-07-04 12:50:47 +0000 |
commit | 02511a109921a678d6c33e0d6cc6e7277ec9f13c (patch) | |
tree | 8caea4363f087173d934c78f5d4d6755f21cb5dd /eclass/pam.eclass | |
parent | meh. fix ChangeLog and stable keyword. (diff) | |
download | gentoo-2-02511a109921a678d6c33e0d6cc6e7277ec9f13c.tar.gz gentoo-2-02511a109921a678d6c33e0d6cc6e7277ec9f13c.tar.bz2 gentoo-2-02511a109921a678d6c33e0d6cc6e7277ec9f13c.zip |
Make pamd_mimic_system work also for Linux-PAM 0.77 (also OSX).
Diffstat (limited to 'eclass/pam.eclass')
-rw-r--r-- | eclass/pam.eclass | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/eclass/pam.eclass b/eclass/pam.eclass index 9a93f1aa9d69..956d481be1b2 100644 --- a/eclass/pam.eclass +++ b/eclass/pam.eclass @@ -1,7 +1,7 @@ # Copyright 2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License, v2 or later # Author Diego Pettenò <flameeyes@gentoo.org> -# $Header: /var/cvsroot/gentoo-x86/eclass/pam.eclass,v 1.5 2005/06/07 11:33:39 flameeyes Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/pam.eclass,v 1.6 2005/07/04 12:50:47 flameeyes Exp $ # # This eclass contains functions to install pamd configuration files and # pam modules. @@ -130,12 +130,18 @@ pamd_mimic_system() { authlevels="auth account password session" + if has_version '<sys-libs/pam-0.78'; then + mimic="\trequired\t\tpam_stack.so service=system-auth" + else + mimic="\tinclude\t\tsystem-auth" + fi + shift while [[ -n $1 ]]; do hasq $1 ${authlevels} || die "unknown level type" - echo -e "$1\tinclude\t\tsystem-auth" >> ${pamdfile} + echo -e "$1${mimic}" >> ${pamdfile} shift done |