2025-01-21 21:36:16 +01:00
|
|
|
# Copyright 1999-2025 Gentoo Authors
|
2023-02-05 19:51:17 +01:00
|
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
|
|
|
|
|
|
EAPI=8
|
|
|
|
|
|
2023-09-03 00:09:16 +02:00
|
|
|
DISTUTILS_EXT=1
|
2023-02-05 19:51:17 +01:00
|
|
|
DISTUTILS_USE_PEP517=setuptools
|
2026-03-09 00:12:27 +01:00
|
|
|
PYTHON_COMPAT=( python3_{12..13} )
|
2023-02-05 19:51:17 +01:00
|
|
|
|
2023-02-06 13:26:41 +01:00
|
|
|
inherit distutils-r1 virtualx
|
2023-02-05 19:51:17 +01:00
|
|
|
|
|
|
|
|
DESCRIPTION="Modern OpenGL binding for python"
|
|
|
|
|
HOMEPAGE="https://github.com/moderngl/glcontext https://pypi.org/project/glcontext"
|
2023-04-25 19:22:16 +02:00
|
|
|
SRC_URI="https://github.com/moderngl/glcontext/archive/refs/tags/${PV}.tar.gz -> ${P}.gh.tar.gz"
|
2023-02-05 19:51:17 +01:00
|
|
|
|
|
|
|
|
LICENSE="MIT"
|
|
|
|
|
SLOT="0"
|
|
|
|
|
KEYWORDS="~amd64 ~x86"
|
2023-04-25 19:22:16 +02:00
|
|
|
IUSE="debug"
|
2023-02-05 19:51:17 +01:00
|
|
|
|
|
|
|
|
BDEPEND="
|
|
|
|
|
x11-libs/libX11
|
|
|
|
|
media-libs/libglvnd[X]
|
|
|
|
|
test? (
|
|
|
|
|
dev-python/pytest[${PYTHON_USEDEP}]
|
|
|
|
|
dev-python/psutil[${PYTHON_USEDEP}]
|
2025-01-21 21:36:16 +01:00
|
|
|
)
|
2023-02-05 19:51:17 +01:00
|
|
|
"
|
|
|
|
|
DEPEND="${BDEPEND}"
|
2025-01-21 21:36:16 +01:00
|
|
|
RDEPEND="dev-util/spirv-tools"
|
2023-02-05 19:51:17 +01:00
|
|
|
|
2023-02-06 13:26:41 +01:00
|
|
|
distutils_enable_tests pytest
|
|
|
|
|
src_test() {
|
|
|
|
|
virtx distutils-r1_src_test
|
|
|
|
|
}
|
2023-02-05 19:51:17 +01:00
|
|
|
|
2023-02-06 13:26:41 +01:00
|
|
|
python_test() {
|
|
|
|
|
cd "${T}" || die
|
|
|
|
|
epytest "${S}"/tests || die "Tests failed with ${EPYTHON}"
|
2023-02-05 19:51:17 +01:00
|
|
|
}
|