From a7a0144d25f12ff44968a2ebef790be4b911d7c8 Mon Sep 17 00:00:00 2001 From: Giancarlo Dessi Date: Sat, 6 Apr 2024 07:08:46 +0700 Subject: gis/OWSLib: Fix script if Python 3.11 is found. Signed-off-by: Willy Sudiarto Raharjo --- gis/OWSLib/OWSLib.SlackBuild | 6 +++++- gis/OWSLib/pytz-not-required.patch | 13 +++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 gis/OWSLib/pytz-not-required.patch (limited to 'gis') diff --git a/gis/OWSLib/OWSLib.SlackBuild b/gis/OWSLib/OWSLib.SlackBuild index fd76c9c131..afdb8084e9 100644 --- a/gis/OWSLib/OWSLib.SlackBuild +++ b/gis/OWSLib/OWSLib.SlackBuild @@ -27,7 +27,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=OWSLib VERSION=${VERSION:-0.30.0} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} PKGTYPE=${PKGTYPE:-tgz} @@ -76,6 +76,10 @@ find -L . \ -o -perm 511 \) -exec chmod 755 {} \; -o \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + +if [ -x /usr/bin/python3.11 ]; then + patch -p1 < $CWD/pytz-not-required.patch +fi python3 setup.py install --root=$PKG diff --git a/gis/OWSLib/pytz-not-required.patch b/gis/OWSLib/pytz-not-required.patch new file mode 100644 index 0000000000..03471b2d4d --- /dev/null +++ b/gis/OWSLib/pytz-not-required.patch @@ -0,0 +1,13 @@ +python-pytz has been removed from Slackware -current because +not needed with Python 3.11 +This patch prevents pip check from indicating the lack of +pytz as dependency required by OWSLib in -current +--- ./requirements.txt 2024-04-05 23:42:52.864498274 +0200 ++++ ./requirements.txt 2024-04-05 23:43:13.322499915 +0200 +@@ -1,6 +1,5 @@ + dataclasses; python_version < '3.7' + lxml + python-dateutil>=1.5 +-pytz + pyyaml + requests>=1.0 -- cgit v1.2.3-79-gdb01