73 lines
2.0 KiB
Django/Jinja
73 lines
2.0 KiB
Django/Jinja
{% set pypi_name = 'oslo.i18n' %}
|
|
{% set upstream_version = upstream_version('6.1.0') %}
|
|
{% set rpm_release = '1' %}
|
|
{% set source = url_pypi() %}
|
|
|
|
Name: {{ py2name() }}
|
|
Version: {{ py2rpmversion() }}
|
|
Release: {{ py2rpmrelease() }}
|
|
Summary: OpenStack i18n library
|
|
License: {{ license('Apache-2.0') }}
|
|
Group: Development/Languages/Python
|
|
URL: https://docs.openstack.org/{{ pypi_name }}
|
|
Source0: {{ source }}
|
|
BuildRequires: openstack-macros
|
|
BuildRequires: {{ py3('oslotest') }}
|
|
BuildRequires: {{ py3('pbr') }}
|
|
BuildRequires: {{ py3('stestr') }}
|
|
BuildRequires: {{ py3('testscenarios') }}
|
|
BuildArch: noarch
|
|
|
|
%description
|
|
The oslo.i18n library contain utilities for working with internationalization
|
|
(i18n) features, especially translation for text strings in an application
|
|
or library.
|
|
|
|
%package -n {{ py2name(py_versions='py3') }}
|
|
Summary: OpenStack i18n library
|
|
|
|
%description -n {{ py2name(py_versions='py3') }}
|
|
The oslo.i18n library contain utilities for working with internationalization
|
|
(i18n) features, especially translation for text strings in an application
|
|
or library.
|
|
|
|
This package contains the Python 3.x module.
|
|
|
|
%package -n {{ py2name() }}-doc
|
|
Summary: Documentation for OpenStack i18n library
|
|
BuildRequires: {{ py3('Sphinx') }}
|
|
BuildRequires: {{ py3('openstackdocstheme') }}
|
|
BuildRequires: {{ py3('sphinxcontrib-apidoc') }}
|
|
|
|
%description -n {{ py2name() }}-doc
|
|
Documentation for the oslo.i18n library.
|
|
|
|
%prep
|
|
%autosetup -p1 -n {{ pypi_name }}-{{ upstream_version }}
|
|
%py_req_cleanup
|
|
|
|
%build
|
|
%{py3_build}
|
|
|
|
%install
|
|
%{py3_install}
|
|
|
|
# generate html docs
|
|
PBR_VERSION=%{version} %sphinx_build -b html doc/source doc/build/html
|
|
# remove the sphinx-build leftovers
|
|
rm -rf doc/build/html/.{doctrees,buildinfo}
|
|
|
|
%check
|
|
%{openstack_stestr_run}
|
|
|
|
%files -n {{ py2name(py_versions='py3') }}
|
|
%license LICENSE
|
|
%{python3_sitelib}/oslo_i18n
|
|
%{python3_sitelib}/*egg-info
|
|
|
|
%files -n {{ py2name() }}-doc
|
|
%doc doc/build/html ChangeLog CONTRIBUTING.rst README.rst
|
|
%license LICENSE
|
|
|
|
%changelog
|