python3-pyopencl: update to 2023.1.4.

This commit is contained in:
Andrew J. Hesford 2023-10-16 10:14:00 -04:00
parent fd21a44437
commit bbcef4ded6
3 changed files with 3 additions and 75 deletions

View file

@ -1,43 +0,0 @@
From b5059d4a73f982db90f136fda0073dcdc83f3fd2 Mon Sep 17 00:00:00 2001
From: Andreas Kloeckner <inform@tiker.net>
Date: Mon, 28 Aug 2023 12:03:49 -0500
Subject: [PATCH] Update to latest aksetup
Includes changes equivalent to https://github.com/inducer/pycuda/pull/423
Co-authored-by: Antoine Martin <antoine@xpra.org>
---
aksetup_helper.py | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/aksetup_helper.py b/aksetup_helper.py
index 89e66da38..1acc8f6d5 100644
--- a/aksetup_helper.py
+++ b/aksetup_helper.py
@@ -43,10 +43,13 @@ def setup(*args, **kwargs):
def get_numpy_incpath():
- from imp import find_module
- # avoid actually importing numpy, it screws up distutils
- file, pathname, descr = find_module("numpy")
- from os.path import join
+ from os.path import join, basename
+ from importlib.util import find_spec
+ origin = find_spec("numpy").origin
+ if origin is None:
+ raise RuntimeError("origin of numpy package not found")
+
+ pathname = basename(origin)
return join(pathname, "core", "include")
@@ -937,7 +940,7 @@ def has_flag(compiler, flagname):
def cpp_flag(compiler):
"""Return the -std=c++[11/14] compiler flag.
- The c++14 is preferred over c++11 (when it is available).
+ C++14 is preferred over C++11 (when it is available).
"""
if has_flag(compiler, "-std=gnu++14"):
return "-std=gnu++14"

View file

@ -1,29 +0,0 @@
From ad6a14a2f28c3d54755f3a1a17069089ad896666 Mon Sep 17 00:00:00 2001
From: Andreas Kloeckner <inform@tiker.net>
Date: Mon, 28 Aug 2023 12:51:04 -0500
Subject: [PATCH] Fix numpy finding in aksetup
---
aksetup_helper.py | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/aksetup_helper.py b/aksetup_helper.py
index d36a2d70..8c9bcec5 100644
--- a/aksetup_helper.py
+++ b/aksetup_helper.py
@@ -43,13 +43,13 @@
def get_numpy_incpath():
- from os.path import join, basename
+ from os.path import join, dirname
from importlib.util import find_spec
origin = find_spec("numpy").origin
if origin is None:
raise RuntimeError("origin of numpy package not found")
- pathname = basename(origin)
+ pathname = dirname(origin)
return join(pathname, "core", "include")

View file

@ -1,7 +1,7 @@
# Template file for 'python3-pyopencl'
pkgname=python3-pyopencl
version=2023.1.2
revision=2
version=2023.1.4
revision=1
build_style=python3-module
hostmakedepends="python3-setuptools python3-pybind11 python3-Cython python3-numpy"
makedepends="OpenCL-Headers ocl-icd-devel python3-pybind11"
@ -11,7 +11,7 @@ maintainer="Andrew J. Hesford <ajh@sideband.org>"
license="X11, Apache-2.0, BSD-3-Clause"
homepage="https://mathema.tician.de/software/pyopencl"
distfiles="${PYPI_SITE}/p/pyopencl/pyopencl-${version}.tar.gz"
checksum=eb00cd574049d592b679dcf8bfe7ab4a36c94a39fd1acb1a6b45d6c0d7be9a68
checksum=220174efca900e9d5de5aef2aa1b77a6f2550501de92b035a91013aeae4d4c5e
# Tests require a working OpenCL platform
make_check=no