From b810a9fab82208bec4caf41a281dcadb09add83a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Date: Fri, 17 Nov 2023 16:47:37 +0100 Subject: [PATCH] dev-python/fonttools: Make Cython extensions optional MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sponsored-by: Ex Makhina, Inc. Signed-off-by: Michał Górny --- dev-python/fonttools/fonttools-4.44.3.ebuild | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/dev-python/fonttools/fonttools-4.44.3.ebuild b/dev-python/fonttools/fonttools-4.44.3.ebuild index 219165929729e..6d2a93312bc3b 100644 --- a/dev-python/fonttools/fonttools-4.44.3.ebuild +++ b/dev-python/fonttools/fonttools-4.44.3.ebuild @@ -23,12 +23,15 @@ SRC_URI=" LICENSE="BSD" SLOT="0" KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~arm64-macos ~x64-macos" +IUSE="+native-extensions" RDEPEND=" >=dev-python/fs-2.4.9[${PYTHON_USEDEP}] " BDEPEND=" - dev-python/cython[${PYTHON_USEDEP}] + native-extensions? ( + dev-python/cython[${PYTHON_USEDEP}] + ) test? ( dev-python/brotlicffi[${PYTHON_USEDEP}] app-arch/zopfli @@ -55,8 +58,9 @@ python_prepare_all() { distutils-r1_python_prepare_all } -src_configure() { - export FONTTOOLS_WITH_CYTHON=1 +python_compile() { + local -x FONTTOOLS_WITH_CYTHON=$(usex native-extensions) + distutils-r1_python_compile } src_test() {