provide/obsolete _isa packages in python_provide (#1271776)
This commit is contained in:
parent
2881873aa2
commit
3b6fac0339
|
@ -13,33 +13,37 @@ CFLAGS="%{optflags}" %{__python} %{py_setup} %{?py_setup_args} install -O1 --ski
|
|||
function string.starts(String,Start)\
|
||||
return string.sub(String,1,string.len(Start))==Start\
|
||||
end\
|
||||
str = rpm.expand("%{?1:%{1}}");\
|
||||
package = rpm.expand("%{?1:%{1}}");\
|
||||
vr = rpm.expand("%{?epoch:%{epoch}:}%{version}-%{release}")
|
||||
if (string.starts(str, "python2-")) then\
|
||||
print("Provides: python-");\
|
||||
print(string.sub(str,9,string.len(str)));\
|
||||
if (string.starts(package, "python2-")) then\
|
||||
str = "Provides: python-" .. string.sub(package,9,string.len(package)) .. "%{?_isa} = " .. vr;\
|
||||
print(rpm.expand(str));\
|
||||
print("\\nProvides: python-");\
|
||||
print(string.sub(package,9,string.len(package)));\
|
||||
print(" = ");\
|
||||
print(vr);\
|
||||
--Obsoleting the previous default python package\
|
||||
str = "\\nObsoletes: python-" .. string.sub(package,9,string.len(package)) .. "%{?_isa} < " .. vr;\
|
||||
print(rpm.expand(str));\
|
||||
print("\\nObsoletes: python-");\
|
||||
print(string.sub(str,9,string.len(str)));\
|
||||
print(string.sub(package,9,string.len(package)));\
|
||||
print(" < ");\
|
||||
print(vr);\
|
||||
elseif (string.starts(str, "python3-")) then\
|
||||
elseif (string.starts(package, "python3-")) then\
|
||||
--No unversioned provides as python3 is not default\
|
||||
elseif (string.starts(str, "pypy-")) then\
|
||||
elseif (string.starts(package, "pypy-")) then\
|
||||
--No unversioned provides as pypy is not default\
|
||||
elseif (string.starts(str, "pypy3-")) then\
|
||||
elseif (string.starts(package, "pypy3-")) then\
|
||||
--No unversioned provides as pypy is not default\
|
||||
elseif (string.starts(str, "python-")) then\
|
||||
elseif (string.starts(package, "python-")) then\
|
||||
--Providing the current default python\
|
||||
print("Provides: python2-");\
|
||||
print(string.sub(str,8,string.len(str)));\
|
||||
print(string.sub(package,8,string.len(package)));\
|
||||
print(" = ");\
|
||||
print(vr);\
|
||||
else\
|
||||
print("ERROR: ");\
|
||||
print(str);\
|
||||
print(package);\
|
||||
print("not recognized.");\
|
||||
end\
|
||||
}
|
||||
|
|
|
@ -108,7 +108,7 @@ Summary: An interpreted, interactive, object-oriented programming language
|
|||
Name: %{python}
|
||||
# Remember to also rebase python-docs when changing this:
|
||||
Version: 2.7.10
|
||||
Release: 10%{?dist}
|
||||
Release: 11%{?dist}
|
||||
License: Python
|
||||
Group: Development/Languages
|
||||
Requires: %{python}-libs%{?_isa} = %{version}-%{release}
|
||||
|
@ -2155,6 +2155,9 @@ rm -fr %{buildroot}
|
|||
# ======================================================
|
||||
|
||||
%changelog
|
||||
* Thu Oct 15 2015 Thomas Spura <tomspur@fedoraproject.org> - 2.7.10-11
|
||||
- provide/obsolete _isa packages in python_provide (#1271776)
|
||||
|
||||
* Wed Sep 23 2015 Robert Kuska <rkuska@redhat.com> - 2.7.10-10
|
||||
- Revert the moving modules to python-tools because distutils uses lib2to3
|
||||
|
||||
|
|
Loading…
Reference in New Issue