summaryrefslogtreecommitdiff
path: root/dev-python/pysdl2
diff options
context:
space:
mode:
authorroot <root@alpha.trunkmasters.com>2026-06-12 19:09:37 -0500
committerroot <root@alpha.trunkmasters.com>2026-06-12 19:09:37 -0500
commitb590c8d7572b727d565cc0b8ff660d43569845de (patch)
tree06f7a4102ea4e845df8b66660f252920d52952f9 /dev-python/pysdl2
parent24f9cbfc4c34fdb6a6e03311674414e881ceab47 (diff)
downloadbaldeagleos-repo-b590c8d7572b727d565cc0b8ff660d43569845de.tar.gz
baldeagleos-repo-b590c8d7572b727d565cc0b8ff660d43569845de.tar.xz
baldeagleos-repo-b590c8d7572b727d565cc0b8ff660d43569845de.zip
Adding metadata
Diffstat (limited to 'dev-python/pysdl2')
-rw-r--r--dev-python/pysdl2/Manifest1
-rw-r--r--dev-python/pysdl2/metadata.xml12
-rw-r--r--dev-python/pysdl2/pysdl2-0.9.17.ebuild69
3 files changed, 82 insertions, 0 deletions
diff --git a/dev-python/pysdl2/Manifest b/dev-python/pysdl2/Manifest
new file mode 100644
index 000000000000..f406a59c1ea3
--- /dev/null
+++ b/dev-python/pysdl2/Manifest
@@ -0,0 +1 @@
+DIST pysdl2-0.9.17.tar.gz 775955 BLAKE2B 205bd6d1e6562133f77827daf77bca9f7cbb589c7454e10fba2b86526c17d7300b2e42ea83030e11703696b62c17b0d5f9c46f082535a67e16d46cc90e048d8c SHA512 ec4bf3b3d01e6c4ffa08fba032d345ec5da141a8021fa5ac98fbbde04e22911893bcd4159afb3a52e06eb178a460b451256487c9b3a3a8105448db36ba0df6b8
diff --git a/dev-python/pysdl2/metadata.xml b/dev-python/pysdl2/metadata.xml
new file mode 100644
index 000000000000..b07db9c2bd4f
--- /dev/null
+++ b/dev-python/pysdl2/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://docs.baldeagleos.com/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>mgorny@gentoo.org</email>
+ <name>Michał Górny</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>python@gentoo.org</email>
+ </maintainer>
+ <origin>baldeagleos-repo</origin>
+</pkgmetadata>
diff --git a/dev-python/pysdl2/pysdl2-0.9.17.ebuild b/dev-python/pysdl2/pysdl2-0.9.17.ebuild
new file mode 100644
index 000000000000..6663df4c2741
--- /dev/null
+++ b/dev-python/pysdl2/pysdl2-0.9.17.ebuild
@@ -0,0 +1,69 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYPI_PN=PySDL2
+PYTHON_COMPAT=( python3_{13..14} )
+
+inherit distutils-r1 pypi
+
+DESCRIPTION="Python (ctypes) bindings for SDL2 libraries"
+HOMEPAGE="
+ https://github.com/py-sdl/py-sdl2/
+ https://pypi.org/project/PySDL2/
+"
+
+LICENSE="|| ( public-domain CC0-1.0 ZLIB )"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+# Optional deps:
+# - dev-python/numpy,
+# - dev-python/pillow,
+# - media-libs/sdl2-* (loaded dynamically via ctypes).
+#
+# If a reverse dependency needs the specific module, it should
+# explicitly depend on the optional module in question. You also
+# probably need to explicitly require some media-libs/libsdl2 flags.
+RDEPEND="media-libs/libsdl2"
+
+# Require all of SDL2 libraries and at least the most common subsystems
+# for better test coverage.
+DEPEND="
+ test? (
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/pillow[${PYTHON_USEDEP}]
+ media-libs/libsdl2[joystick,sound,video]
+ media-libs/sdl2-gfx
+ media-libs/sdl2-image[gif,jpeg,png,tiff,webp]
+ || (
+ media-libs/sdl2-mixer[flac]
+ media-libs/sdl2-mixer[midi]
+ media-libs/sdl2-mixer[mod]
+ media-libs/sdl2-mixer[mp3]
+ media-libs/sdl2-mixer[opus]
+ )
+ media-libs/sdl2-ttf
+ )"
+
+distutils_enable_tests pytest
+
+python_test() {
+ local EPYTEST_DESELECT=(
+ # pysdl2 was misusing libsdl2's error API. Fixed upstream already
+ # but it didn't land in 0.9.16.
+ # https://bugs.gentoo.org/916120
+ # https://bugs.gentoo.org/916118
+ sdl2/test/gamecontroller_test.py
+ sdl2/test/hidapi_test.py::test_SDL_hid_enumerate
+ )
+
+ local -x SDL_VIDEODRIVER=dummy
+ local -x SDL_AUDIODRIVER=dummy
+ local -x SDL_RENDER_DRIVER=software
+
+ local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
+ epytest -x
+}