Projects
home:fstrba
python-curl_cffi
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 4
View file
python-curl_cffi.spec
Changed
@@ -16,6 +16,11 @@ # +%if 0%{?suse_version} > 1500 +%bcond_without libalternatives +%else +%bcond_with libalternatives +%endif %{?sle15_python_module_pythons} Name: python-curl_cffi Version: 0.16.1 @@ -42,6 +47,13 @@ Requires: curl-impersonate Requires: python-certifi Requires: python-cffi +%if %{with libalternatives} +BuildRequires: alts +Requires: alts +%else +Requires(post): update-alternatives +Requires(postun): update-alternatives +%endif %python_subpackages %description @@ -56,24 +68,19 @@ %pyproject_wheel %install -# 1. Install the wheel into the buildroot %pyproject_install -# 2. Rename binaries to versioned versions for all flavors using the standard macro -%python_clone %{buildroot}%{_bindir}/curl-cffi - -# 3. Link unversioned only for the primary interpreter -%python_expand if "%{$python_flavor}" = "%{primary_python}" ; then ln -s curl-cffi-%{$python_bin_suffix} %{buildroot}%{_bindir}/curl-cffi; fi +%python_clone -a %{buildroot}%{_bindir}/curl-cffi -# 4. Run fdupes to hardlink identical files %python_expand %fdupes %{buildroot}%{$python_sitearch} +%pre +# removing old update-alternatives entries +%python_libalternatives_reset_alternative curl-cffi + %files %{python_files} %license LICENSE -%{_bindir}/curl-cffi-%{python_bin_suffix} -%if "%{python_flavor}" == "%{primary_python}" -%{_bindir}/curl-cffi -%endif +%python_alternative %{_bindir}/curl-cffi %{python_sitearch}/curl_cffi %{python_sitearch}/curl_cffi-%{version}.dist-info
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.