forked from pool/python-python-ptrace
- Update to 0.9.8 * Added Arm 64bit (AArch64) support. * Implemented ``PTRACE_GETREGSET`` and ``PTRACE_SETREGSET`` required on AArch64 and available on Linux. * Issue #66: Fix ``SIGTRAP|0x80`` or ``SIGTRAP`` wait in syscall_state.exit (``PTRACE_O_TRACESYSGOOD``). - Build PEP517 wheels separately in multibuild - Add patchtes for Python 3.12: * python-ptrace-pr81-importlib.patch gh#vstinner/python-ptrace#81 * python-ptrace-pr83-importlib.patch gh#vstinner/python-ptrace#83 OBS-URL: https://build.opensuse.org/request/show/1154445 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-python-ptrace?expand=0&rev=18
35 lines
1009 B
Diff
35 lines
1009 B
Diff
From 80e0c97a84eccb8b82737cf40b9c5581c20c245f Mon Sep 17 00:00:00 2001
|
|
From: Mario Haustein <mario.haustein@hrz.tu-chemnitz.de>
|
|
Date: Sat, 16 Sep 2023 13:49:43 +0200
|
|
Subject: [PATCH] Remove deprecated `imp` module
|
|
|
|
---
|
|
setup.py | 7 +++++--
|
|
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/setup.py b/setup.py
|
|
index 4d6ba36..ad54f9a 100755
|
|
--- a/setup.py
|
|
+++ b/setup.py
|
|
@@ -28,7 +28,7 @@
|
|
# - git commit -a -m "post-release"
|
|
# - git push
|
|
|
|
-from imp import load_source
|
|
+import importlib.util
|
|
from os import path
|
|
try:
|
|
# setuptools supports bdist_wheel
|
|
@@ -55,7 +55,10 @@
|
|
with open('README.rst') as fp:
|
|
LONG_DESCRIPTION = fp.read()
|
|
|
|
-ptrace = load_source("version", path.join("ptrace", "version.py"))
|
|
+ptrace_spec = importlib.util.spec_from_file_location("version", path.join("ptrace", "version.py"))
|
|
+ptrace = importlib.util.module_from_spec(ptrace_spec)
|
|
+ptrace_spec.loader.exec_module(ptrace)
|
|
+
|
|
PACKAGES = {}
|
|
for name in MODULES:
|
|
PACKAGES[name] = name.replace(".", "/")
|