diff --git a/python-urlgrabber.changes b/python-urlgrabber.changes index 92a57b4..342d2f9 100644 --- a/python-urlgrabber.changes +++ b/python-urlgrabber.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed May 20 07:47:54 UTC 2020 - pgajdos@suse.com + +- urlgrabber-ext-down as an alternative + ------------------------------------------------------------------- Mon May 18 09:10:43 UTC 2020 - Petr Gajdos diff --git a/python-urlgrabber.spec b/python-urlgrabber.spec index 9039f91..48f94a1 100644 --- a/python-urlgrabber.spec +++ b/python-urlgrabber.spec @@ -16,14 +16,16 @@ # -%define _libexecdir /usr/libexec %{?!python_module:%define python_module() python-%{**} python3-%{**}} %define modname urlgrabber +# package expects urlgrabber-ext-down in /usr/libexec +%define _libexecdir /usr/libexec Name: python-urlgrabber Version: 4.1.0 Release: 0 Summary: A high-level cross-protocol url-grabber License: LGPL-2.1-only +Group: Development/Libraries/Python URL: https://github.com/rpm-software-management/urlgrabber Source: https://github.com/rpm-software-management/%{modname}/releases/download/%{modname}-4-1-0/%{modname}-%{version}.tar.gz BuildRequires: %{python_module pycurl} @@ -31,7 +33,6 @@ BuildRequires: %{python_module setuptools} BuildRequires: %{python_module six} BuildRequires: fdupes BuildRequires: python-rpm-macros -Requires: %{modname}-ext-down Requires: python-pycurl Requires: python-six Requires(post): update-alternatives @@ -44,12 +45,6 @@ A high-level cross-protocol url-grabber for python supporting HTTP, FTP and file locations. Features include keepalive, byte ranges, throttling, authentication, proxies and more. -%package -n %{modname}-ext-down -Summary: External Downloader - -%description -n %{modname}-ext-down -A very simple external downloader. - %prep %setup -q -n urlgrabber-%{version} # Remove with next release @@ -61,11 +56,13 @@ sed -i "13d" urlgrabber/__init__.py # Remove wrong license header, fixes bnc#781 %install %python_install %python_clone -a %{buildroot}%{_bindir}/urlgrabber +%python_clone -a %{buildroot}%{_libexecdir}/urlgrabber-ext-down rm -rf %{buildroot}%{_datadir}/doc/urlgrabber-%{version} # Remove wrongly installed docs %python_expand %fdupes %{buildroot}%{$python_sitelib} %post %python_install_alternative urlgrabber +%{python_expand %{_sbindir}/update-alternatives --quiet --install %{_libexecdir}/urlgrabber-ext-down urlgrabber-ext-down %{_libexecdir}/urlgrabber-ext-down-%{$python_version} %{$python_version_nodots}} %postun %python_uninstall_alternative urlgrabber @@ -74,9 +71,7 @@ rm -rf %{buildroot}%{_datadir}/doc/urlgrabber-%{version} # Remove wrongly instal %license LICENSE %doc ChangeLog README TODO %python_alternative %{_bindir}/urlgrabber +%python_alternative %{_libexecdir}/urlgrabber-ext-down %{python_sitelib}/* -%files -n %{modname}-ext-down -%{_libexecdir}/urlgrabber-ext-down - %changelog