14
0
forked from pool/python-pygame

------------------------------------------------------------------

- Add python-pygame-python38-import.patch from upstream to fix a build 
  failure with Python 3.8.
- Use autopatch macro rather than patch0, due to multiple patches.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pygame?expand=0&rev=26
This commit is contained in:
2019-10-15 04:14:19 +00:00
committed by Git OBS Bridge
parent 9a34c4807f
commit fec2dea4dd
3 changed files with 33 additions and 3 deletions

View File

@@ -0,0 +1,22 @@
From 9b5f88bca562f37d30eb7ac0f8f4ebdda68cb494 Mon Sep 17 00:00:00 2001
From: Christoph Gohlke <cjgohlke@gmail.com>
Date: Wed, 14 Aug 2019 14:01:06 -0700
Subject: [PATCH] Fix test error on Python 3.8.0b3
Fix `ImportError: cannot import name 'clock' from 'time' (unknown location)`
---
test/math_test.py | 1 -
1 file changed, 1 deletion(-)
diff --git a/test/math_test.py b/test/math_test.py
index c0bb84eb3..f22ba5e12 100644
--- a/test/math_test.py
+++ b/test/math_test.py
@@ -2,7 +2,6 @@
import sys
import unittest
import math
-from time import clock
import platform
import pygame.math

View File

@@ -1,3 +1,10 @@
------------------------------------------------------------------
Tue Oct 15 04:11:07 UTC 2019 - Steve Kowalik <steven.kowalik@suse.com>
- Add python-pygame-python38-import.patch from upstream to fix a build
failure with Python 3.8.
- Use autopatch macro rather than patch0, due to multiple patches.
-------------------------------------------------------------------
Mon May 20 08:46:49 UTC 2019 - pgajdos@suse.com

View File

@@ -12,7 +12,7 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
@@ -23,10 +23,11 @@ Release: 0
Summary: A Python Module for Interfacing with the SDL Multimedia Library
License: LGPL-2.1-or-later
Group: Development/Libraries/Python
URL: https://github.com/pygame/pygame
Url: https://github.com/pygame/pygame
Source0: https://files.pythonhosted.org/packages/source/p/pygame/pygame-%{version}.tar.gz
# Do not test mp3 format; whe have that support disabled in SDL1
Patch0: python-pygame-test-no-mp3.patch
Patch1: python-pygame-python38-import.patch
BuildRequires: %{python_module devel}
BuildRequires: %{python_module numpy}
BuildRequires: %{python_module setuptools}
@@ -89,7 +90,7 @@ This package contains documentation and example programs for Pygame.
%prep
%setup -q -n pygame-%{version}
%patch0 -p1
%autopatch -p1
sed -i 's/\r$//' docs/reST/ref/code_examples/draw_module_example.py
sed -i 's/\r$//' docs/reST/ref/code_examples/joystick_calls.py
# Fix wrong-script-interpreter