%global pypi_name ModulemdTranslationHelpers
Name: python-%{pypi_name}
Version: 0.5
Release: 3%{?dist}
Summary: Tools for working with translations of modulemd
License: MIT
URL: https://github.com/fedora-modularity/ModulemdTranslationHelpers
Source0: %{pypi_source}
BuildArch: noarch
BuildRequires: python3-devel
BuildRequires: python3dist(setuptools)
# The following are needed for generating the manpages which are only produced
# for the python3 package.
BuildRequires: python3dist(babel)
BuildRequires: python3dist(click)
BuildRequires: python3dist(click-man)
BuildRequires: python3dist(pygobject)
BuildRequires: python3dist(requests)
BuildRequires: koji
BuildRequires: libmodulemd
%{?python_enable_dependency_generator}
%description
Provides a library and tools for dealing with translatable strings in modulemd
documents.
%package -n python3-%{pypi_name}
Summary: %{summary}
%{?python_provide:%python_provide python3-%{pypi_name}}
Requires: koji
Requires: libmodulemd
Requires: python3dist(pygobject)
Obsoletes: python3-mmdzanata < 0.7-3
Obsoletes: python2-mmdzanata < 0.7-3
%description -n python3-%{pypi_name}
Provides a library and tools for dealing with translatable strings in modulemd
documents.
%prep
%autosetup -n %{pypi_name}-%{version}
# Remove bundled egg-info
rm -rf %{pypi_name}.egg-info
%build
%py3_build
%install
%py3_install
%{__python3} setup.py --command-packages=click_man.commands man_pages --target=%{buildroot}%{_mandir}/man1
%files -n python3-%{pypi_name}
%doc README.md
%license LICENSE
%{_bindir}/ModulemdTranslationHelpers
%{_mandir}/man1/*
%{python3_sitelib}/%{pypi_name}/
%{python3_sitelib}/%{pypi_name}-*.egg-info/
%changelog
* Mon Oct 01 2018 Stephen Gallagher <sgallagh@redhat.com> - 0.5-3
- Drop Python 2 subpackage
* Wed Sep 26 2018 Stephen Gallagher <sgallagh@redhat.com> - 0.5-2
- Fixes to the specfile
* Tue Sep 25 2018 Stephen Gallagher <sgallagh@redhat.com> - 0.5-1
- Fixes from code review
* Tue Sep 25 2018 Stephen Gallagher <sgallagh@redhat.com> - 0.3-1
- Initial package