Compare commits
8 Commits
Author | SHA256 | Date | |
---|---|---|---|
a5c4271614 | |||
0c764e3b4c | |||
4398e62a7c | |||
8a9d2571f5 | |||
4fac323c35 | |||
d5a53a39d3 | |||
a2bbfb42e8 | |||
57db7355d0 |
54
112.patch
54
112.patch
@@ -1,54 +0,0 @@
|
||||
From fbe0fab7947788039cb4fbc9a5a1ea65a0c0e15b Mon Sep 17 00:00:00 2001
|
||||
From: Florian Weimer <fweimer@redhat.com>
|
||||
Date: Fri, 5 Jan 2024 08:48:12 +0100
|
||||
Subject: [PATCH 1/2] accelerate: Fix type of PyArray_FillWithScalar
|
||||
|
||||
The first argument is of type PyArrayObject, not PyObject.
|
||||
---
|
||||
accelerate/src/numpy_formathandler.pyx | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/accelerate/src/numpy_formathandler.pyx b/accelerate/src/numpy_formathandler.pyx
|
||||
index 0c01d78e..10813694 100644
|
||||
--- a/accelerate/src/numpy_formathandler.pyx
|
||||
+++ b/accelerate/src/numpy_formathandler.pyx
|
||||
@@ -21,7 +21,7 @@ cdef extern from "numpy/arrayobject.h":
|
||||
int PyArray_ISCARRAY_RO( np.ndarray instance )
|
||||
cdef np.ndarray PyArray_Zeros(int nd, np.Py_intptr_t* dims, np.dtype, int fortran)
|
||||
cdef np.ndarray PyArray_EnsureArray(object)
|
||||
- cdef int PyArray_FillWithScalar(object, object)
|
||||
+ cdef int PyArray_FillWithScalar(np.ndarray, object)
|
||||
cdef void import_array()
|
||||
cdef void* PyArray_DATA( np.ndarray )
|
||||
cdef int PyArray_NDIM( np.ndarray )
|
||||
|
||||
From f62dd58a5437c628d3ff3e626d4507811ef2127b Mon Sep 17 00:00:00 2001
|
||||
From: Florian Weimer <fweimer@redhat.com>
|
||||
Date: Fri, 5 Jan 2024 08:48:43 +0100
|
||||
Subject: [PATCH 2/2] accelerate: Use recommended way to integrate NumPy with
|
||||
Cython
|
||||
|
||||
This approach follows
|
||||
<https://cython.readthedocs.io/en/latest/src/tutorial/numpy.html#adding-types>.
|
||||
---
|
||||
accelerate/src/numpy_formathandler.pyx | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/accelerate/src/numpy_formathandler.pyx b/accelerate/src/numpy_formathandler.pyx
|
||||
index 10813694..47dacaa0 100644
|
||||
--- a/accelerate/src/numpy_formathandler.pyx
|
||||
+++ b/accelerate/src/numpy_formathandler.pyx
|
||||
@@ -22,7 +22,6 @@ cdef extern from "numpy/arrayobject.h":
|
||||
cdef np.ndarray PyArray_Zeros(int nd, np.Py_intptr_t* dims, np.dtype, int fortran)
|
||||
cdef np.ndarray PyArray_EnsureArray(object)
|
||||
cdef int PyArray_FillWithScalar(np.ndarray, object)
|
||||
- cdef void import_array()
|
||||
cdef void* PyArray_DATA( np.ndarray )
|
||||
cdef int PyArray_NDIM( np.ndarray )
|
||||
cdef int *PyArray_DIMS( np.ndarray )
|
||||
@@ -226,4 +225,4 @@ cdef class NumpyHandler(FormatHandler):
|
||||
|
||||
# Cython numpy tutorial neglects to mention this AFAICS
|
||||
# get segfaults without it
|
||||
-import_array()
|
||||
+np.import_array()
|
@@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:b7e8b81c60c1a07d5b29fe89a9f1aba3172cd9e4b68046454e913943e7e4cb6f
|
||||
size 599962
|
3
PyOpenGL-accelerate-3.1.9.tar.gz
Normal file
3
PyOpenGL-accelerate-3.1.9.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:0e88282568e2921cf3983a715a9c2ecd9bb5ee45195d0e2648c17ef47ea18bdb
|
||||
size 22027
|
6
_service
6
_service
@@ -16,11 +16,11 @@
|
||||
or my understanding of it.
|
||||
-->
|
||||
<!--
|
||||
<param name="versionrewrite-pattern">227f9c6</param>
|
||||
<param name="versionrewrite-replacement">3.1.6</param>
|
||||
-->
|
||||
<param name="versionrewrite-pattern">29b79e8</param>
|
||||
<param name="versionrewrite-replacement">3.1.7</param>
|
||||
-->
|
||||
<param name="versionrewrite-pattern">5dfca47</param>
|
||||
<param name="versionrewrite-replacement">3.1.9</param>
|
||||
<param name="filename">PyOpenGL-accelerate</param>
|
||||
</service>
|
||||
<service name="recompress" mode="manual">
|
||||
|
@@ -1,3 +1,34 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Jul 25 05:03:22 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
|
||||
|
||||
- Add patch support-cython-3.1.patch:
|
||||
* Support Cython 3.1 changes.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jul 4 05:28:05 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
|
||||
|
||||
- Switch to pyproject macros.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Apr 28 15:37:20 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- update to 3.1.9
|
||||
* Reduce the number of iterations in memory leak test to avoid JIT
|
||||
triggering
|
||||
* Cleanup formatting in a few modules
|
||||
* Don't bomb out during egl test when there's no egl devices
|
||||
* Regenerated C wrappers with latest Cython
|
||||
* Numpy intp type for latest numpy
|
||||
* Fix ctypes FormatHandler for Python 3.12+
|
||||
* More changes, see upstream commits
|
||||
- Drop merged 112.patch and numpy2.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Sep 10 12:33:04 UTC 2024 - Markéta Machová <mmachova@suse.com>
|
||||
|
||||
- Add upstream patch numpy2.patch to fix compatibility with Numpy 2
|
||||
* https://github.com/mcfletch/pyopengl/commit/f897b0ed75c00d4c524be4689683a334832217ac
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jun 5 14:28:18 UTC 2024 - John Paul Adrian Glaubitz <adrian.glaubitz@suse.com>
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-opengl-accelerate
|
||||
#
|
||||
# Copyright (c) 2024 SUSE LLC
|
||||
# Copyright (c) 2025 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -17,22 +17,23 @@
|
||||
|
||||
|
||||
%define tarname PyOpenGL-accelerate
|
||||
%define _version 3.1.7
|
||||
%define _version 3.1.9
|
||||
%{?sle15_python_module_pythons}
|
||||
Name: python-opengl-accelerate
|
||||
Version: %{_version}
|
||||
Release: 0
|
||||
Summary: Acceleration for python-opengl
|
||||
License: BSD-3-Clause
|
||||
Group: Development/Libraries/Python
|
||||
URL: http://pyopengl.sourceforge.net
|
||||
Source0: %{tarname}-%{_version}.tar.gz
|
||||
# PATCH-FIX-UPSTREAM - accelerate: Fix C type errors for GCC 14/Clang compatibility
|
||||
Patch0: https://github.com/mcfletch/pyopengl/pull/112.patch
|
||||
# PATCH-FIX-UPSTREAM Based on gh#mcfletch/pyopengl#146
|
||||
Patch0: support-cython-3.1.patch
|
||||
BuildRequires: %{python_module Cython}
|
||||
BuildRequires: %{python_module devel}
|
||||
BuildRequires: %{python_module opengl >= %{version}}
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
BuildRequires: %{python_module numpy-devel if (%python-base without python36-base)}
|
||||
@@ -56,15 +57,12 @@ code.
|
||||
mv accelerate/* ./
|
||||
rmdir accelerate
|
||||
|
||||
# Force Cython to rebuild .c files
|
||||
rm src/*.c
|
||||
|
||||
%build
|
||||
export CFLAGS="%{optflags} -DGLX_GLXEXT_LEGACY"
|
||||
%python_build
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
%python_install
|
||||
%pyproject_install
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
||||
|
||||
%check
|
||||
@@ -72,8 +70,8 @@ export CFLAGS="%{optflags} -DGLX_GLXEXT_LEGACY"
|
||||
|
||||
%files %{python_files}
|
||||
%license license.txt
|
||||
%doc README.txt
|
||||
%doc README.md
|
||||
%{python_sitearch}/OpenGL_accelerate/
|
||||
%{python_sitearch}/PyOpenGL_accelerate-*-py%{python_version}.egg-info
|
||||
%{python_sitearch}/[Pp]y[Oo]pen[Gg][Ll]_accelerate-%{version}.dist-info
|
||||
|
||||
%changelog
|
||||
|
23
support-cython-3.1.patch
Normal file
23
support-cython-3.1.patch
Normal file
@@ -0,0 +1,23 @@
|
||||
From 69e8ced15eb63c3f00293f59cef50d5fad02d884 Mon Sep 17 00:00:00 2001
|
||||
From: Vsevolod Misiul <vsevolod.misul@innowise.com>
|
||||
Date: Mon, 19 May 2025 14:46:00 +0300
|
||||
Subject: [PATCH 1/2] For linux on arm64 the long type is not defined, so grab
|
||||
it from ctypes.c_long
|
||||
|
||||
---
|
||||
accelerate/src/vbo.pyx | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/accelerate/src/vbo.pyx b/accelerate/src/vbo.pyx
|
||||
index 13f9e99d..6e92c059 100644
|
||||
--- a/accelerate/src/vbo.pyx
|
||||
+++ b/accelerate/src/vbo.pyx
|
||||
@@ -1,6 +1,7 @@
|
||||
"""Cython-coded VBO implementation"""
|
||||
#cython: language_level=3
|
||||
import ctypes, weakref
|
||||
+from ctypes import c_long as long
|
||||
from OpenGL_accelerate.formathandler cimport FormatHandler
|
||||
from OpenGL import error
|
||||
from OpenGL._bytes import bytes,unicode
|
||||
|
Reference in New Issue
Block a user