dev-libs/libnfc: bump
[gentoo.git] / dev-libs / opensc / opensc-0.20.0.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5
6 inherit bash-completion-r1 libtool
7
8 DESCRIPTION="Libraries and applications to access smartcards"
9 HOMEPAGE="https://github.com/OpenSC/OpenSC/wiki"
10 SRC_URI="https://github.com/OpenSC/OpenSC/releases/download/${PV}/${P}.tar.gz"
11
12 LICENSE="LGPL-2.1"
13 SLOT="0"
14 KEYWORDS="~alpha amd64 arm ~hppa ~ia64 ~m68k ppc ppc64 ~s390 ~sparc x86"
15 IUSE="ctapi doc libressl openct notify +pcsc-lite readline secure-messaging ssl test zlib"
16 RESTRICT="!test? ( test )"
17
18 RDEPEND="zlib? ( sys-libs/zlib )
19         readline? ( sys-libs/readline:0= )
20         ssl? (
21                 !libressl? ( dev-libs/openssl:0= )
22                 libressl? ( >=dev-libs/libressl-2.7.0:0= )
23         )
24         openct? ( >=dev-libs/openct-0.5.0 )
25         pcsc-lite? ( >=sys-apps/pcsc-lite-1.3.0 )
26         notify? ( dev-libs/glib:2 )"
27 DEPEND="${RDEPEND}
28         app-text/docbook-xsl-stylesheets
29         dev-libs/libxslt
30         test? ( dev-util/cmocka )"
31 BDEPEND="virtual/pkgconfig"
32
33 REQUIRED_USE="
34         pcsc-lite? ( !openct !ctapi )
35         openct? ( !pcsc-lite !ctapi )
36         ctapi? ( !pcsc-lite !openct )
37         || ( pcsc-lite openct ctapi )"
38
39 src_prepare() {
40         default
41         elibtoolize
42 }
43
44 src_configure() {
45         econf \
46                 --with-completiondir="$(get_bashcompdir)" \
47                 --disable-openpace \
48                 --disable-static \
49                 --disable-strict \
50                 --enable-man \
51                 $(use_enable ctapi) \
52                 $(use_enable doc) \
53                 $(use_enable notify ) \
54                 $(use_enable openct) \
55                 $(use_enable pcsc-lite pcsc) \
56                 $(use_enable readline) \
57                 $(use_enable secure-messaging sm) \
58                 $(use_enable ssl openssl) \
59                 $(use_enable test cmocka) \
60                 $(use_enable zlib)
61 }
62
63 src_install() {
64         default
65         find "${D}" -name '*.la' -delete || die
66 }