diff options
author | Brian Evans <grknight@gentoo.org> | 2019-12-10 10:49:58 -0500 |
---|---|---|
committer | Brian Evans <grknight@gentoo.org> | 2019-12-10 10:49:58 -0500 |
commit | bc165d784681b20934318f5e50386951c3ecdeb4 (patch) | |
tree | a42e1d168d39c9f48003172e2d09aeb9d2627b02 /media-fonts/liberation-fonts | |
parent | sys-apps/openrc: fix live ebuild so no static libs are built (diff) | |
download | gentoo-bc165d784681b20934318f5e50386951c3ecdeb4.tar.gz gentoo-bc165d784681b20934318f5e50386951c3ecdeb4.tar.bz2 gentoo-bc165d784681b20934318f5e50386951c3ecdeb4.zip |
media-fonts/liberation-fonts: Fix python-any-r1 usage
Non-maintainer commit.
The usage of python-any-r1 was incomplete. This commit fixes:
* Adding python_gen_any_dep so valid USE are connected to python deps
* Adding python_check_deps to validate if a dep is actually installed
* sed the Makefile to use EPYTHON for consistent builds instead of user pref
* Changing DEPEND to BDEPEND on EAPI7 as they are tools run by the build
Closes: https://bugs.gentoo.org/698128
Package-Manager: Portage-2.3.81, Repoman-2.3.20
Signed-off-by: Brian Evans <grknight@gentoo.org>
Diffstat (limited to 'media-fonts/liberation-fonts')
-rw-r--r-- | media-fonts/liberation-fonts/liberation-fonts-2.00.1-r3.ebuild | 15 | ||||
-rw-r--r-- | media-fonts/liberation-fonts/liberation-fonts-2.00.5.ebuild | 19 |
2 files changed, 28 insertions, 6 deletions
diff --git a/media-fonts/liberation-fonts/liberation-fonts-2.00.1-r3.ebuild b/media-fonts/liberation-fonts/liberation-fonts-2.00.1-r3.ebuild index 78a09b75e220..f8b2526afc60 100644 --- a/media-fonts/liberation-fonts/liberation-fonts-2.00.1-r3.ebuild +++ b/media-fonts/liberation-fonts/liberation-fonts-2.00.1-r3.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2018 Gentoo Foundation +# Copyright 1999-2019 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -25,10 +25,21 @@ DEPEND=" fontforge? ( ${PYTHON_DEPS} media-gfx/fontforge - dev-python/fonttools + $(python_gen_any_dep '<dev-python/fonttools-4.0[${PYTHON_USEDEP}]') )" RDEPEND="" +python_check_deps() { + has_version "dev-python/fonttools[${PYTHON_USEDEP}]" +} + +src_prepare() { + default + if use fontforge ; then + sed -i "s/= python/= ${EPYTHON}/" Makefile || die + fi +} + pkg_setup() { if use fontforge; then FONT_S="${S}/${PN}-ttf-${PV}" diff --git a/media-fonts/liberation-fonts/liberation-fonts-2.00.5.ebuild b/media-fonts/liberation-fonts/liberation-fonts-2.00.5.ebuild index 7cff094ba513..4f8f5081e5bc 100644 --- a/media-fonts/liberation-fonts/liberation-fonts-2.00.5.ebuild +++ b/media-fonts/liberation-fonts/liberation-fonts-2.00.5.ebuild @@ -9,8 +9,8 @@ inherit font python-any-r1 DESCRIPTION="A Helvetica/Times/Courier replacement TrueType font set, courtesy of Red Hat" HOMEPAGE="https://github.com/liberationfonts/liberation-fonts" -SRC_URI="!fontforge? ( ${HOMEPAGE}/files/2926169/${PN}-ttf-${PV}.tar.gz ) -fontforge? ( ${HOMEPAGE}/files/2926167/${P}.tar.gz )" +SRC_URI="!fontforge? ( https://github.com/liberationfonts/liberation-fonts/files/2926169/${PN}-ttf-${PV}.tar.gz ) +fontforge? ( https://github.com/liberationfonts/liberation-fonts/files/2926167/${P}.tar.gz )" KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~x64-solaris" SLOT="0" @@ -21,13 +21,24 @@ FONT_SUFFIX="ttf" FONT_CONF=( "${FILESDIR}/60-liberation.conf" ) -DEPEND=" +BDEPEND=" fontforge? ( ${PYTHON_DEPS} media-gfx/fontforge - dev-python/fonttools + $(python_gen_any_dep 'dev-python/fonttools[${PYTHON_USEDEP}]') )" +python_check_deps() { + has_version -b "dev-python/fonttools[${PYTHON_USEDEP}]" +} + +src_prepare() { + default + if use fontforge ; then + sed -i "s/= python3/= ${EPYTHON}/" Makefile || die + fi +} + pkg_setup() { if use fontforge; then FONT_S="${S}/${PN}-ttf-${PV}" |