dev-db/percona-server: drop old
[gentoo.git] / dev-db / sqlcipher / sqlcipher-3.4.2.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5
6 inherit autotools eutils flag-o-matic ltprune multilib-minimal
7
8 DESCRIPTION="Full Database Encryption for SQLite"
9 HOMEPAGE="https://www.zetetic.net/sqlcipher/"
10 SRC_URI="https://github.com/sqlcipher/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
11
12 LICENSE="BSD"
13 SLOT="0"
14 KEYWORDS="amd64 x86"
15
16 IUSE="libedit readline libressl static-libs tcl test"
17 RESTRICT="!test? ( test )"
18
19 # Tcl is always needed by buildsystem
20 RDEPEND="
21         libedit? ( dev-libs/libedit[${MULTILIB_USEDEP}] )
22         !libressl? ( dev-libs/openssl:0=[${MULTILIB_USEDEP}] )
23         libressl? ( dev-libs/libressl:0=[${MULTILIB_USEDEP}] )
24         readline? ( sys-libs/readline:0=[${MULTILIB_USEDEP}] )
25         tcl? ( dev-lang/tcl:=[${MULTILIB_USEDEP}] )
26 "
27 DEPEND="${RDEPEND}
28         dev-lang/tcl:*"
29
30 # Libedit and readline support are mutually exclusive
31 # Testsuite requires compilation with TCL, bug #582584
32 REQUIRED_USE="
33         libedit? ( !readline )
34         test? ( tcl )
35 "
36
37 DOCS=( README.md )
38
39 src_prepare() {
40         # bug #678502
41         eapply "${FILESDIR}/${P}-libressl-2.8.patch"
42
43         append-cflags -DSQLITE_HAS_CODEC
44         eapply_user
45         eautoreconf
46 }
47
48 multilib_src_configure() {
49         ECONF_SOURCE=${S} \
50         econf \
51                 --enable-fts3 \
52                 --enable-fts4 \
53                 --enable-fts5 \
54                 --enable-json1 \
55                 --enable-tempstore \
56                 $(use_enable libedit editline) \
57                 $(use_enable readline) \
58                 $(use_enable static-libs static) \
59                 $(use_enable tcl)
60 }
61
62 multilib_src_install_all() {
63         prune_libtool_files
64         einstalldocs
65 }