From 84a80a0ab92050b6219db07fcd429335bd74e12b Mon Sep 17 00:00:00 2001 From: Isaac Yu Date: Sat, 21 Dec 2019 07:31:09 +0700 Subject: python/pyudev: Updated for version 0.21.0. Signed-off-by: Willy Sudiarto Raharjo --- python/pyudev/README | 2 +- python/pyudev/pyudev.SlackBuild | 13 ++++++++----- python/pyudev/pyudev.info | 2 +- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/python/pyudev/README b/python/pyudev/README index d8e6bf9d10..0439de0e7c 100644 --- a/python/pyudev/README +++ b/python/pyudev/README @@ -9,4 +9,4 @@ Almost the complete libudev functionality is exposed. You can: threads, or within the event loops of Qt (pyudev.pyqt4, pyudev.pyside), glib (pyudev.glib) or the optional dependency wxPython (pyudev.wx). -python3 is an optional dependency (autodetected). +If python3-six is installed, then this will also build for Python 3. diff --git a/python/pyudev/pyudev.SlackBuild b/python/pyudev/pyudev.SlackBuild index 46a7d008ca..b8564e8eb6 100644 --- a/python/pyudev/pyudev.SlackBuild +++ b/python/pyudev/pyudev.SlackBuild @@ -2,7 +2,7 @@ # Slackware build script for pyudev # Copyright 2012 Jon Ware -# Copyright 2018 Isaac Yu +# Copyright 2018-2019 Isaac Yu # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -24,7 +24,7 @@ PRGNAM=pyudev VERSION=${VERSION:-0.21.0} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -69,10 +69,13 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; -python setup.py install --root=$PKG +# Python 2 support (Default) +if $(python -c 'import six' 2>/dev/null); then + python setup.py install --root=$PKG +fi -# Python 3 support. -if $(python3 -c 'import sys' 2>/dev/null); then +# Python 3 support +if $(python3 -c 'import six' 2>/dev/null); then python3 setup.py install --root=$PKG fi diff --git a/python/pyudev/pyudev.info b/python/pyudev/pyudev.info index 9d559bf0e3..3f8746ceaa 100644 --- a/python/pyudev/pyudev.info +++ b/python/pyudev/pyudev.info @@ -5,6 +5,6 @@ DOWNLOAD="https://pypi.python.org/packages/source/p/pyudev/pyudev-0.21.0.tar.gz" MD5SUM="cf4d9db7d772622144ca1be6b5d9353b" DOWNLOAD_x86_64="" MD5SUM_x86_64="" -REQUIRES="" +REQUIRES="six" MAINTAINER="Isaac Yu" EMAIL="isaacyu1@isaacyu1.com" -- cgit v1.2.3