1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
7 DESCRIPTION="A portable, efficient middleware for different kinds of mail access"
8 HOMEPAGE="http://libetpan.sourceforge.net/"
9 SRC_URI="https://github.com/dinhviethoa/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
13 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos"
14 IUSE="berkdb gnutls ipv6 liblockfile libressl lmdb sasl ssl static-libs"
16 # BerkDB is only supported up to version 6.0
18 !lmdb? ( berkdb? ( sys-libs/db:= ) )
21 gnutls? ( net-libs/gnutls:= )
23 !libressl? ( dev-libs/openssl:0= )
24 libressl? ( dev-libs/libressl:0= )
27 sasl? ( dev-libs/cyrus-sasl:2 )
28 liblockfile? ( net-libs/liblockfile )"
32 "${FILESDIR}"/${PN}-1.0-nonnull.patch
33 "${FILESDIR}"/${PN}-1.9.4-berkdb_lookup.patch #519846
34 "${FILESDIR}"/${PN}-1.9.4-pkgconfig_file_no_ldflags.patch
38 if use gnutls && ! use ssl ; then
39 ewarn "You have \"gnutls\" USE flag enabled but \"ssl\" USE flag disabled!"
40 ewarn "No ssl support will be available in ${PN}."
43 if use berkdb && use lmdb ; then
44 ewarn "You have \"berkdb\" _and_ \"lmdb\" USE flags enabled."
45 ewarn "Using lmdb as cache DB!"
55 # in Prefix emake uses SHELL=${BASH}, export CONFIG_SHELL to the same so
56 # libtool recognises it as valid shell (bug #300211)
57 use prefix && export CONFIG_SHELL=${BASH}
59 # --enable-debug simply injects "-O2 -g" into CFLAGS
62 $(use_enable liblockfile lockfile)
63 $(use_enable static-libs static)
65 $(usex lmdb '--enable-lmdb --disable-db' "$(use_enable berkdb db) --disable-lmdb")
66 $(usex ssl "$(use_with gnutls) $(use_with !gnutls openssl)" '--without-gnutls --without-openssl')
68 econf "${myeconfargs[@]}"
73 find "${ED}" -name "*.la" -delete || die
74 if ! use static-libs ; then
75 find "${ED}" -name "*.a" -delete || die