aboutsummaryrefslogtreecommitdiff
path: root/python/python3-evdev/python3-evdev.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'python/python3-evdev/python3-evdev.SlackBuild')
-rw-r--r--python/python3-evdev/python3-evdev.SlackBuild14
1 files changed, 12 insertions, 2 deletions
diff --git a/python/python3-evdev/python3-evdev.SlackBuild b/python/python3-evdev/python3-evdev.SlackBuild
index e70f61145e..cadebc7c91 100644
--- a/python/python3-evdev/python3-evdev.SlackBuild
+++ b/python/python3-evdev/python3-evdev.SlackBuild
@@ -6,6 +6,7 @@
# Copyright 2020-2023 Isaac Yu <isaacyu@protonmail.com>
# Copyright 2023-2024 Erich Ritz, Jenks, Oklahoma, USA <erich.public@protonmail.com>
# Copyright 2024 Isaac Yu <isaacyu@protonmail.com>
+# Copyright 2025 Jeremy Hansen <jebrhansen+SBo@gmail.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -28,7 +29,7 @@
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=python3-evdev
-VERSION=${VERSION:-1.7.1}
+VERSION=${VERSION:-1.9.1}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -73,7 +74,16 @@ find -L . -perm 660 -exec chmod 644 {} \;
PYVER=$(python3 -c 'import sys; print("%d.%d" % sys.version_info[:2])')
export PYTHONPATH=/opt/python$PYVER/site-packages/
-python3 setup.py install --root=$PKG
+# Add unused section to avoid ERROR message from setuptools_scm
+# Make it an if statement just in case upstream decides to update
+# it and I don't notice.
+if ! grep -qF "[tool.setuptools_scm]" pyproject.toml; then
+ echo "[tool.setuptools_scm]" >> pyproject.toml
+fi
+export SETUPTOOLS_SCM_PRETEND_VERSION=$VERSION
+
+python3 -m build --wheel --no-isolation
+python3 -m installer --destdir "$PKG" dist/*.whl
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true