1 # Copyright 1999-2017 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
6 PYTHON_COMPAT=( python2_7 )
8 inherit fcaps gnome2 pam python-any-r1 versionator virtualx
10 DESCRIPTION="Password and keyring managing daemon"
11 HOMEPAGE="https://wiki.gnome.org/Projects/GnomeKeyring"
13 LICENSE="GPL-2+ LGPL-2+"
15 IUSE="+caps pam selinux +ssh-agent test"
16 KEYWORDS="alpha amd64 arm ~arm64 ia64 ~mips ppc ppc64 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~sparc-solaris ~x86-solaris"
18 # Replace gkd gpg-agent with pinentry[gnome-keyring] one, bug #547456
20 >=app-crypt/gcr-3.5.3:=[gtk]
21 >=dev-libs/glib-2.38:2
22 app-misc/ca-certificates
23 >=dev-libs/libgcrypt-1.2.2:0=
24 caps? ( sys-libs/libcap-ng )
26 selinux? ( sec-policy/selinux-gnome )
27 >=app-crypt/gnupg-2.0.28:=
30 >=app-eselect/eselect-pinentry-0.5
31 app-text/docbook-xml-dtd:4.3
33 >=dev-util/intltool-0.35
36 test? ( ${PYTHON_DEPS} )
38 PDEPEND="app-crypt/pinentry[gnome-keyring]" #570512
41 use test && python-any-r1_pkg_setup
45 # Disable stupid CFLAGS with debug enabled
46 sed -e 's/CFLAGS="$CFLAGS -g"//' \
47 -e 's/CFLAGS="$CFLAGS -O0"//' \
48 -i configure.ac configure || die
54 gnome2_src_configure \
55 $(use_with caps libcap-ng) \
57 $(use_with pam pam-dir $(getpam_mod_dir)) \
58 $(use_enable selinux) \
59 $(use_enable ssh-agent) \
64 "${EROOT}${GLIB_COMPILE_SCHEMAS}" --allow-any-name "${S}/schema" || die
65 GSETTINGS_SCHEMA_DIR="${S}/schema" virtx emake check
69 # cap_ipc_lock only needed if building --with-libcap-ng
70 # Never install as suid root, this breaks dbus activation, see bug #513870
71 use caps && fcaps -m 755 cap_ipc_lock usr/bin/gnome-keyring-daemon
74 if ! [[ $(eselect pinentry show | grep "pinentry-gnome3") ]] ; then
75 ewarn "Please select pinentry-gnome3 as default pinentry provider:"
76 ewarn " # eselect pinentry set pinentry-gnome3"