summaryrefslogtreecommitdiff
blob: f7075b5a456a2071d122f5f6310c9c1ac514c7e8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-crypt/pinentry/pinentry-0.7.0.ebuild,v 1.1 2004/02/28 08:13:54 vapier Exp $

DESCRIPTION="collection of simple PIN or passphrase entry dialogs which utilize the Assuan protocol"
HOMEPAGE="http://www.gnupg.org/aegypten/"
SRC_URI="ftp://ftp.gnupg.org/gcrypt/pinentry/${P}.tar.gz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86 ~ppc"
IUSE="qt gtk ncurses"

DEPEND="gtk? ( x11-libs/gtk+ )
	ncurses? ( sys-libs/ncurses )
	qt? ( x11-libs/qt )
	!gtk? ( !qt? ( !ncurses? ( sys-libs/ncurses ) ) )"

src_compile() {
	local myconf=""
	if ! use qt && ! use gtk && ! use ncurses ; then
		myconf="--enable-pinentry-curses --enable-fallback-curses"
	fi
	econf \
		`use_enable qt pinentry-qt` \
		`use_enable gtk pinentry-gtk` \
		`use_enable ncurses pinentry-curses` \
		`use_enable ncurses fallback-curses` \
		--disable-dependency-tracking \
		${myconf} \
		|| die
	make || die
}

src_install() {
	make DESTDIR="${D}" install || die
	dodoc AUTHORS ChangeLog NEWS README THANKS TODO

	# The other two pinentries don't spit out an insecure memory warning when
	# not suid root, and gtk refuses to start if pinentry-gtk is suid root.
	fperms +s /usr/bin/pinentry-qt
}

pkg_postinst() {
	einfo "pinentry-qt is installed SUID root to make use of protected memory space"
	einfo "This is needed in order to have a secure place to store your passphrases,"
	einfo "etc. at runtime but may make some sysadmins nervous"
}