Gentoo Archives: gentoo-commits

From: Michael Palimaka <kensington@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: kde-plasma/kwallet-pam/
Date: Wed, 02 Mar 2016 19:23:40
Message-Id: 1456946599.185acb067688322b0dbdeaf73cee0a9ac0a9f6a6.kensington@gentoo
1 commit: 185acb067688322b0dbdeaf73cee0a9ac0a9f6a6
2 Author: Andreas Sturmlechner <andreas.sturmlechner <AT> gmail <DOT> com>
3 AuthorDate: Sun Feb 28 01:25:13 2016 +0000
4 Commit: Michael Palimaka <kensington <AT> gentoo <DOT> org>
5 CommitDate: Wed Mar 2 19:23:19 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=185acb06
7
8 kde-plasma/kwallet-pam: Add pkg_postinst instructions
9
10 Package-Manager: portage-2.2.27
11
12 kde-plasma/kwallet-pam/kwallet-pam-5.4.3-r1.ebuild | 27 +++++++++++++++++++++-
13 kde-plasma/kwallet-pam/kwallet-pam-5.5.4.ebuild | 25 ++++++++++++++++++++
14 2 files changed, 51 insertions(+), 1 deletion(-)
15
16 diff --git a/kde-plasma/kwallet-pam/kwallet-pam-5.4.3-r1.ebuild b/kde-plasma/kwallet-pam/kwallet-pam-5.4.3-r1.ebuild
17 index 26499e6..42f8033 100644
18 --- a/kde-plasma/kwallet-pam/kwallet-pam-5.4.3-r1.ebuild
19 +++ b/kde-plasma/kwallet-pam/kwallet-pam-5.4.3-r1.ebuild
20 @@ -1,4 +1,4 @@
21 -# Copyright 1999-2015 Gentoo Foundation
22 +# Copyright 1999-2016 Gentoo Foundation
23 # Distributed under the terms of the GNU General Public License v2
24 # $Id$
25
26 @@ -20,3 +20,28 @@ DEPEND="
27 RDEPEND="${DEPEND}
28 net-misc/socat
29 "
30 +
31 +pkg_postinst() {
32 + check_dm() {
33 + if [[ -e "${ROOT}${2}" ]] && \
34 + [[ -n $(egrep "auth\s+optional\s+pam_kwallet5.so" "${ROOT}${2}") ]] && \
35 + [[ -n $(egrep "session\s+optional\s+pam_kwallet5.so" "${ROOT}${2}") ]]; then
36 + elog " ${1} - ${2} ...GOOD"
37 + else
38 + ewarn " ${1} - ${2} ...BAD"
39 + fi
40 + }
41 + elog
42 + elog "This package enables auto-unlocking of kde-frameworks/kwallet:5."
43 + elog "List of things to make it work:"
44 + elog "1. Use same password for login and kwallet"
45 + elog "2. A display manager with support for PAM"
46 + elog "3.a Have the following lines in the display manager's pam.d file:"
47 + elog " -auth optional pam_kwallet5.so"
48 + elog " -session optional pam_kwallet5.so auto_start"
49 + elog "3.b Checking installed DMs..."
50 + has_version "x11-misc/sddm" && check_dm "SDDM" "/etc/pam.d/sddm"
51 + has_version "x11-misc/lightdm" && check_dm "LightDM" "/etc/pam.d/lightdm"
52 + has_version "kde-base/kdm" && check_dm "KDM" "/etc/pam.d/kde"
53 + elog
54 +}
55
56 diff --git a/kde-plasma/kwallet-pam/kwallet-pam-5.5.4.ebuild b/kde-plasma/kwallet-pam/kwallet-pam-5.5.4.ebuild
57 index 69759db..50ad31e 100644
58 --- a/kde-plasma/kwallet-pam/kwallet-pam-5.5.4.ebuild
59 +++ b/kde-plasma/kwallet-pam/kwallet-pam-5.5.4.ebuild
60 @@ -27,3 +27,28 @@ src_configure() {
61
62 kde5_src_configure
63 }
64 +
65 +pkg_postinst() {
66 + check_dm() {
67 + if [[ -e "${ROOT}${2}" ]] && \
68 + [[ -n $(egrep "auth\s+optional\s+pam_kwallet5.so" "${ROOT}${2}") ]] && \
69 + [[ -n $(egrep "session\s+optional\s+pam_kwallet5.so" "${ROOT}${2}") ]]; then
70 + elog " ${1} - ${2} ...GOOD"
71 + else
72 + ewarn " ${1} - ${2} ...BAD"
73 + fi
74 + }
75 + elog
76 + elog "This package enables auto-unlocking of kde-frameworks/kwallet:5."
77 + elog "List of things to make it work:"
78 + elog "1. Use same password for login and kwallet"
79 + elog "2. A display manager with support for PAM"
80 + elog "3.a Have the following lines in the display manager's pam.d file:"
81 + elog " -auth optional pam_kwallet5.so"
82 + elog " -session optional pam_kwallet5.so auto_start"
83 + elog "3.b Checking installed DMs..."
84 + has_version "x11-misc/sddm" && check_dm "SDDM" "/etc/pam.d/sddm"
85 + has_version "x11-misc/lightdm" && check_dm "LightDM" "/etc/pam.d/lightdm"
86 + has_version "kde-base/kdm" && check_dm "KDM" "/etc/pam.d/kde"
87 + elog
88 +}