%global pypi_name click-man Name: python-%{pypi_name} Version: 0.2.2 Release: 4%{?dist} Summary: Generate man pages for click based CLI applications License: MIT URL: https://github.com/click-contrib/click-man Source0: https://files.pythonhosted.org/packages/source/c/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch BuildRequires: python2-devel BuildRequires: python2dist(setuptools) BuildRequires: python3-devel BuildRequires: python3dist(setuptools) %{?python_enable_dependency_generator} %description Automatically produces UNIX-style manual pages for Python applications that use Click for option handling. %package -n python2-%{pypi_name} Summary: %{summary} %{?python_provide:%python_provide python2-%{pypi_name}} %description -n python2-%{pypi_name} Automatically produces UNIX-style manual pages for Python applications that use Click for option handling. %package -n python3-%{pypi_name} Summary: %{summary} %{?python_provide:%python_provide python3-%{pypi_name}} %description -n python3-%{pypi_name} Automatically produces UNIX-style manual pages for Python applications that use Click for option handling. %prep %autosetup -n %{pypi_name}-%{version} # Remove bundled egg-info rm -rf %{pypi_name}.egg-info %build %py2_build %py3_build %install # Must do the default python version install last because # the scripts in /usr/bin are overwritten with every setup.py install. %py2_install rm -rf %{buildroot}%{_bindir}/* %py3_install %files -n python2-%{pypi_name} %license LICENSE %doc README.md README.rst %{python2_sitelib}/click_man %{python2_sitelib}/click_man-%{version}-py?.?.egg-info %files -n python3-%{pypi_name} %license LICENSE %doc README.md README.rst %{_bindir}/click-man %{python3_sitelib}/click_man %{python3_sitelib}/click_man-%{version}-py?.?.egg-info %changelog * Fri Aug 31 2018 Stephen Gallagher - 0.2.2-4 - Fix description - Use python?dist()-style BuildRequires * Thu Aug 30 2018 Stephen Gallagher - 0.2.2-3 - Use automatic dependency generator * Wed Aug 29 2018 Stephen Gallagher - 0.2.2-2 - Add missing URL * Wed Aug 29 2018 Stephen Gallagher - 0.2.2-1 - Initial package.