When flat, don't require/provide python(abi) = 3.10

The regex was broken for two+ digit minor version.

Providing python(abi) = 3.10 confuses the dependency resolution in the
Python 3.10 testing copr.

E.g. python3-sphinx requires `python(abi) = 3.10` and `/usr/bin/python3`.
In certain circumstances, dnf installs python3 and python3.10 from rawhide,
satisfying both of the dependencies.

Running `sphinx-build` hence ends up with:

    Traceback (most recent call last):
      File "/usr/bin/sphinx-build", line 5, in <module>
        from sphinx.cmd.build import main
    ModuleNotFoundError: No module named 'sphinx'
This commit is contained in:
Miro Hrončok 2021-03-22 12:40:04 +01:00
parent 87f3cf679a
commit 8aff12c51e
1 changed files with 6 additions and 3 deletions

View File

@ -17,7 +17,7 @@ URL: https://www.python.org/
%global prerel a6
%global upstream_version %{general_version}%{?prerel}
Version: %{general_version}%{?prerel:~%{prerel}}
Release: 1%{?dist}
Release: 2%{?dist}
License: Python
@ -563,8 +563,8 @@ The debug runtime additionally supports debug builds of C-API extensions
# We'll not provide this, on purpose
# No package in Fedora shall ever depend on flatpackage via this
%global __requires_exclude ^python\\(abi\\) = 3\\..$
%global __provides_exclude ^python\\(abi\\) = 3\\..$
%global __requires_exclude ^python\\(abi\\) = 3\\..+
%global __provides_exclude ^python\\(abi\\) = 3\\..+
# Python interpreter packages used to be named (or provide) name pythonXY (e.g.
# python39). However, to align it with the executable names and to prepare for
@ -1577,6 +1577,9 @@ CheckPython optimized
# ======================================================
%changelog
* Mon Mar 22 2021 Miro Hrončok <mhroncok@redhat.com> - 3.10.0~a6-2
- When flat, don't require/provide python(abi) = 3.10
* Tue Mar 02 2021 Tomas Hrnciar <thrnciar@redhat.com> - 3.10.0~a6-1
- Update to 3.10.0a6