diff --git a/python-pyftpdlib.changes b/python-pyftpdlib.changes index 3e5864c..763fbba 100644 --- a/python-pyftpdlib.changes +++ b/python-pyftpdlib.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed May 20 07:26:27 UTC 2020 - Petr Gajdos + +- %python3_only -> %python_alternative + ------------------------------------------------------------------- Mon Apr 20 10:41:55 UTC 2020 - Tomáš Chvátal diff --git a/python-pyftpdlib.spec b/python-pyftpdlib.spec index 78f0fa0..51c0859 100644 --- a/python-pyftpdlib.spec +++ b/python-pyftpdlib.spec @@ -37,6 +37,8 @@ BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-pyOpenSSL +Requires(post): update-alternatives +Requires(postun): update-alternatives Recommends: python-pysendfile BuildArch: noarch %if %{with python2} @@ -60,6 +62,7 @@ write very asynchronous FTP servers with Python. %install %python_install +%python_clone -a %{buildroot}%{_bindir}/ftpbench %python_expand %fdupes %{buildroot}%{$python_sitelib} # Note: Do not remove tests. Other packages import them @@ -69,10 +72,16 @@ export PYTHONPATH=$PWD %python_exec pyftpdlib/test/runner.py %endif +%post +%python_install_alternative ftpbench + +%postun +%python_uninstall_alternative ftpbench + %files %{python_files} %license LICENSE %doc README.rst -%python3_only %{_bindir}/ftpbench +%python_alternative %{_bindir}/ftpbench %{python_sitelib}/* %changelog