Update to 1.5.27
Add patch for Python 3.12 support Use SPDX License
This commit is contained in:
parent
111ed9c4b7
commit
45ba8fa193
4 changed files with 39 additions and 4 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -12,3 +12,4 @@
|
|||
/pyglet-1.5.16.tar.gz
|
||||
/pyglet-1.5.16-repacked.tar.gz
|
||||
/pyglet-1.5.23-repacked.tar.gz
|
||||
/pyglet-1.5.27-repacked.tar.gz
|
||||
|
|
|
|||
21
python-pyglet-imp.patch
Normal file
21
python-pyglet-imp.patch
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
diff -up pyglet-1.5.27/tests/integration/test_toplevel_imports.py.imp pyglet-1.5.27/tests/integration/test_toplevel_imports.py
|
||||
--- pyglet-1.5.27/tests/integration/test_toplevel_imports.py.imp 2023-06-17 07:55:27.061254060 -0600
|
||||
+++ pyglet-1.5.27/tests/integration/test_toplevel_imports.py 2023-06-17 08:01:50.139739485 -0600
|
||||
@@ -5,7 +5,7 @@
|
||||
This _must_ be the first test run.
|
||||
'''
|
||||
|
||||
-import imp
|
||||
+import importlib
|
||||
import unittest
|
||||
|
||||
import pyglet
|
||||
@@ -47,7 +47,7 @@ def add_module_tests(name, bases, dict):
|
||||
def create_test(components):
|
||||
def test_module(self):
|
||||
top = pyglet
|
||||
- imp.reload(top)
|
||||
+ importlib.reload(top)
|
||||
for component in components:
|
||||
self.assertTrue(hasattr(top, component),
|
||||
'Cannot access "%s" in "%s"' % (component, top.__name__))
|
||||
|
|
@ -4,11 +4,11 @@
|
|||
%bcond_without tests
|
||||
|
||||
Name: python-%{srcname}
|
||||
Version: 1.5.23
|
||||
Release: 5%{?dist}
|
||||
Version: 1.5.27
|
||||
Release: 1%{?dist}
|
||||
Summary: A cross-platform windowing and multimedia library for Python
|
||||
|
||||
License: BSD
|
||||
License: BSD-3-Clause
|
||||
URL: http://www.pyglet.org/
|
||||
|
||||
# The upstream tarball includes some non-free files in the examples and tests,
|
||||
|
|
@ -20,6 +20,9 @@ URL: http://www.pyglet.org/
|
|||
Source0: %{versionedname}-repacked.tar.gz
|
||||
Source1: pyglet-get-tarball.sh
|
||||
|
||||
# Use importlib instead of imp
|
||||
Patch0: python-pyglet-imp.patch
|
||||
|
||||
# Note that unbundling pypng removes "PNGImageDecoder", which is normally
|
||||
# available for advanced use cases. Instead of:
|
||||
# img = image.load(fname, decoder=PNGImageDecoder) # don't use!
|
||||
|
|
@ -41,6 +44,9 @@ BuildRequires: pyproject-rpm-macros
|
|||
%if %{with tests}
|
||||
BuildRequires: /usr/bin/xvfb-run mesa-dri-drivers
|
||||
BuildRequires: python3-pytest
|
||||
# These two for gdkpixbuf2 tests
|
||||
BuildRequires: gtk2-devel
|
||||
BuildRequires: gdk-pixbuf2-devel
|
||||
# libpurple has sound files unbundled in the repacked tarball
|
||||
BuildRequires: libpurple
|
||||
%endif
|
||||
|
|
@ -129,6 +135,7 @@ ln -s %{_datadir}/sounds/purple/*.wav tests/data/media/
|
|||
# test_find_font_match & test_have_font skipped -- they look for a font named 'arial'
|
||||
# test_freetype_face tests are is skipped -- they depend on non-free font we remove
|
||||
# test_push_handlers_instance has broken mocking: https://github.com/pyglet/pyglet/issues/606
|
||||
# GdkPixBufTest.test_load_animation uses dinosaur.gif which we remove
|
||||
%pytest \
|
||||
-vv \
|
||||
--non-interactive \
|
||||
|
|
@ -136,6 +143,7 @@ ln -s %{_datadir}/sounds/purple/*.wav tests/data/media/
|
|||
--ignore=tests/integration/media \
|
||||
-m 'not (requires_user_action or requires_user_validation or only_interactive)' \
|
||||
-k 'not (test_find_font_match or test_have_font or test_freetype_face or test_push_handlers_instance)' \
|
||||
--deselect tests/integration/image/test_gdkpixbuf2.py::GdkPixBufTest::test_load_animation \
|
||||
tests
|
||||
%endif
|
||||
|
||||
|
|
@ -148,6 +156,11 @@ ln -s %{_datadir}/sounds/purple/*.wav tests/data/media/
|
|||
|
||||
|
||||
%changelog
|
||||
* Sat Jun 17 2023 Orion Poplawski <orion@nwra.com> - 1.5.27-1
|
||||
- Update to 1.5.27
|
||||
- Add patch for Python 3.12 support
|
||||
- Use SPDX License
|
||||
|
||||
* Fri Jun 16 2023 Python Maint <python-maint@redhat.com> - 1.5.23-5
|
||||
- Rebuilt for Python 3.12
|
||||
|
||||
|
|
|
|||
2
sources
2
sources
|
|
@ -1 +1 @@
|
|||
SHA512 (pyglet-1.5.23-repacked.tar.gz) = 3385bcfe93ed3b50e1fd8e3c148fc363a72615ece8a2f4ba136df71e480d4c556e0dbd9183911746cdcbe7245aad49f825f6640866e39bd39c204cca6142b3f6
|
||||
SHA512 (pyglet-1.5.27-repacked.tar.gz) = 496b1b94bde77e2ddf095d021b0736969abd7e70b5fd24ec56e655c41724aa69201d75c63ffc2196197af1ff822f76341c98baaf71170d3b98f37f535ee86660
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue