Do not provide pythonXdist for platform-python packages
This commit is contained in:
parent
ea8d0d41e8
commit
d64bb3efc4
@ -34,7 +34,7 @@
|
||||
Name: python-rpm-generators
|
||||
Summary: Requires and Provides generators for Python RPMs
|
||||
Version: %{rpmver}
|
||||
Release: %{?snapver:0.%{snapver}.}3%{?dist}
|
||||
Release: %{?snapver:0.%{snapver}.}4%{?dist}
|
||||
License: GPLv2+
|
||||
Url: http://www.rpm.org/
|
||||
Source0: http://ftp.rpm.org/releases/%{srcdir}/%{srcname}-%{srcver}.tar.bz2
|
||||
@ -58,6 +58,7 @@ Patch7: rpm-4.13.x-pythondistdeps.py-fix-processing-wheels.patch
|
||||
# Downstream only: https://github.com/rpm-software-management/rpm/pull/212
|
||||
Patch8: rpm-4.13.x-pythondistdeps-python3.patch
|
||||
Patch9: rpm-4.13.x-pythondeps-platform-python-abi.patch
|
||||
Patch10: rpm-4.13.x-pythondistdeps.py-platform-python.patch
|
||||
|
||||
%description
|
||||
This package provides scripts that analyse Python binary RPM packages
|
||||
@ -114,6 +115,9 @@ install -Dm 755 scripts/__pycache__/* \
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Aug 24 2017 Miro Hrončok <mhroncok@redhat.com> - 4.13.0.1-4
|
||||
- Add patch 10: Do not provide pythonXdist for platform-python packages (rhbz#1484607)
|
||||
|
||||
* Tue Aug 08 2017 Tomas Orsava <torsava@redhat.com> - 4.13.0.1-3
|
||||
- Add patch 9: Generate requires and provides for platform-python(abi)
|
||||
(https://fedoraproject.org/wiki/Changes/Platform_Python_Stack)
|
||||
|
42
rpm-4.13.x-pythondistdeps.py-platform-python.patch
Normal file
42
rpm-4.13.x-pythondistdeps.py-platform-python.patch
Normal file
@ -0,0 +1,42 @@
|
||||
From eb48f08dd30324f960b8e404b80eb885b2bbb593 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@hroncok.cz>
|
||||
Date: Thu, 24 Aug 2017 13:45:49 +0200
|
||||
Subject: [PATCH] Do not provide pythonXdist for platform-python packages
|
||||
|
||||
---
|
||||
scripts/pythondistdeps.py | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/scripts/pythondistdeps.py b/scripts/pythondistdeps.py
|
||||
index 2abb59f49..f624fdbb7 100755
|
||||
--- a/scripts/pythondistdeps.py
|
||||
+++ b/scripts/pythondistdeps.py
|
||||
@@ -16,6 +16,7 @@ from os.path import basename, dirname, isdir, sep
|
||||
from sys import argv, stdin, version
|
||||
from distutils.sysconfig import get_python_lib
|
||||
from warnings import warn
|
||||
+import re
|
||||
|
||||
|
||||
opts, args = getopt(
|
||||
@@ -78,6 +79,9 @@ for f in files:
|
||||
f = f.strip()
|
||||
lower = f.lower()
|
||||
name = 'python(abi)'
|
||||
+ if re.search(r'/usr/lib(64)?/platform-python\d\.\d', lower):
|
||||
+ # https://bugzilla.redhat.com/show_bug.cgi?id=1484607
|
||||
+ continue
|
||||
# add dependency based on path, versioned if within versioned python directory
|
||||
if py_abi and (lower.endswith('.py') or lower.endswith('.pyc') or lower.endswith('.pyo')):
|
||||
if name not in py_deps:
|
||||
@@ -115,7 +119,6 @@ for f in files:
|
||||
if not dist.py_version:
|
||||
# Try to parse the Python version from the path the metadata
|
||||
# resides at (e.g. /usr/lib/pythonX.Y/site-packages/...)
|
||||
- import re
|
||||
res = re.search(r"/python(?P<pyver>\d+\.\d)/", path_item)
|
||||
if res:
|
||||
dist.py_version = res.group('pyver')
|
||||
--
|
||||
2.13.5
|
||||
|
Loading…
Reference in New Issue
Block a user