*/*: Clean PYTHON_COMPAT of obsolete impls
[gentoo.git] / app-portage / esearch / esearch-9999.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=5
5
6 PYTHON_COMPAT=(python{2_7,3_6,3_7})
7 PYTHON_REQ_USE="readline(+)"
8
9 inherit distutils-r1 git-r3
10
11 DESCRIPTION="Replacement for 'emerge --search' with search-index"
12 HOMEPAGE="https://github.com/fuzzyray/esearch"
13 EGIT_REPO_URI="https://github.com/fuzzyray/esearch.git"
14
15 LICENSE="GPL-2"
16 SLOT="0"
17 IUSE="l10n_fr l10n_it"
18
19 KEYWORDS=""
20
21 DEPEND="sys-apps/portage"
22 RDEPEND="${DEPEND}"
23
24 python_configure_all() {
25         echo VERSION="${PVR}" "${EPYTHON}" setup.py set_version
26         VERSION="${PVR}" "${EPYTHON}" setup.py set_version \
27                 || die "setup.py set_version failed"
28 }
29
30 python_install_all() {
31         distutils-r1_python_install_all
32         dodoc eupdatedb.cron
33
34         # Remove unused man pages according to the l10n flags
35         if ! use l10n_fr ; then
36                 rm -rf "${ED}"/usr/share/man/fr \
37                         || die "rm failed to remove ${ED}/usr/share/man/fr"
38         fi
39
40         if ! use l10n_it ; then
41                 rm -rf "${ED}"/usr/share/man/it \
42                         || die "rm failed to remove ${ED}/usr/share/man/it"
43         fi
44 }