]> git.pld-linux.org Git - packages/python-kombu.git/blame - python-kombu.spec
rebuild with tests and docs
[packages/python-kombu.git] / python-kombu.spec
CommitLineData
44562528
JK
1#
2# Conditional build:
aae8302a
JB
3%bcond_without doc # Sphinx documentation
4%bcond_without tests # unit tests
44562528 5%bcond_without python2 # CPython 2.x module
6e10e0c3 6%bcond_with python3 # CPython 3.x module
44562528 7
6e10e0c3 8%define module kombu
44562528 9Summary: Messaging library for Python
aae8302a 10Summary(pl.UTF-8): Biblioteka komunikatów dla Pythona
be70ea90 11Name: python-%{module}
58de0877 12# keep 4.x here for python2 support
aae8302a 13Version: 4.6.11
bfb1a139 14Release: 3
58de0877 15License: BSD
be70ea90 16Group: Development/Languages/Python
aae8302a
JB
17#Source0Download: https://pypi.org/simple/kombu/
18Source0: https://files.pythonhosted.org/packages/source/k/kombu/%{module}-%{version}.tar.gz
19# Source0-md5: 759b31d97fc11c4cb16f6d293723e85e
20URL: https://pypi.org/project/kombu/
44562528 21%if %{with python2}
f5b96fc9 22BuildRequires: python-modules >= 1:2.7
aae8302a
JB
23BuildRequires: python-setuptools >= 1:20.6.7
24%if %{with tests}
25BuildRequires: python-Pyro4
26BuildRequires: python-amqp >= 2.6.0
27BuildRequires: python-botocore
28BuildRequires: python-case >= 1.5.2
29BuildRequires: python-importlib_metadata >= 0.18
44562528 30BuildRequires: python-nose
aae8302a
JB
31BuildRequires: python-pytest
32BuildRequires: python-pytz
44562528
JK
33%endif
34%endif
35%if %{with python3}
aae8302a
JB
36BuildRequires: python3-modules >= 1:3.5
37BuildRequires: python3-setuptools >= 1:20.6.7
44562528 38%if %{with tests}
aae8302a
JB
39BuildRequires: python3-Pyro4
40BuildRequires: python3-amqp >= 2.6.0
41BuildRequires: python3-amqp < 2.7
42BuildRequires: python3-botocore
43BuildRequires: python3-case >= 1.5.2
44%if "%{py3_ver}" < "3.8"
45BuildRequires: python3-importlib_metadata >= 0.18
46%endif
44562528 47BuildRequires: python3-nose
44562528 48%endif
65a38e1a 49%endif
aae8302a
JB
50BuildRequires: rpm-pythonprov
51BuildRequires: rpmbuild(macros) >= 1.714
52%if %{with doc}
53BuildRequires: python-amqp
54BuildRequires: python-sphinx_celery
55BuildRequires: python-sphinxcontrib-issuetracker
56BuildRequires: sphinx-pdg-2
44562528 57%endif
aae8302a 58Requires: python-modules >= 1:2.7
be70ea90 59BuildArch: noarch
60BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
61
62%description
333ebabd 63The aim of Kombu is to make messaging in Python as easy as possible by
44562528 64providing an idiomatic high-level interface for the AMQ protocol, and
333ebabd 65also provide proven and tested solutions to common messaging problems.
be70ea90 66
aae8302a
JB
67%description -l pl.UTF-8
68Celem Kombu jest jak największe ułatwienie wymiany komunikatów w
69Pythonie poprzez dostarczenie idomatycznego, wysokopoziomowego
70interfejsu do protokołu AMQ oraz sprawdzonych rozwiązań powszechnych
71problemów związanych z komunikowaniem.
72
44562528
JK
73%package -n python3-%{module}
74Summary: Messaging library for Python
aae8302a 75Summary(pl.UTF-8): Biblioteka komunikatów dla Pythona
44562528 76Group: Libraries/Python
aae8302a 77Requires: python3-modules >= 1:3.5
44562528
JK
78
79%description -n python3-%{module}
80The aim of Kombu is to make messaging in Python as easy as possible by
81providing an idiomatic high-level interface for the AMQ protocol, and
82also provide proven and tested solutions to common messaging problems.
83
aae8302a
JB
84%description -n python3-%{module} -l pl.UTF-8
85Celem Kombu jest jak największe ułatwienie wymiany komunikatów w
86Pythonie poprzez dostarczenie idomatycznego, wysokopoziomowego
87interfejsu do protokołu AMQ oraz sprawdzonych rozwiązań powszechnych
88problemów związanych z komunikowaniem.
89
44562528 90%package apidocs
aae8302a
JB
91Summary: API documentation for kombu module
92Summary(pl.UTF-8): Dokumentacja API modułu kombu
44562528 93Group: Documentation
aae8302a 94Obsoletes: python3-kombu-apidocs < 5
44562528
JK
95
96%description apidocs
aae8302a 97API documentation for kombu module.
44562528
JK
98
99%description apidocs -l pl.UTF-8
aae8302a 100Dokumentacja API modułu kombu.
65a38e1a 101
be70ea90 102%prep
103%setup -q -n %{module}-%{version}
104
105%build
44562528 106%if %{with python2}
aae8302a 107%py_build
44562528 108
aae8302a
JB
109%if %{with tests}
110PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
111PYTEST_PLUGINS="case.pytest" \
112%{__python} -m pytest t/unit
44562528
JK
113%endif
114%endif
115
116%if %{with python3}
aae8302a 117%py3_build
65a38e1a 118
aae8302a
JB
119%if %{with tests}
120PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
121PYTEST_PLUGINS="case.pytest" \
122%{__python3} -m pytest t/unit
65a38e1a 123%endif
44562528 124%endif
be70ea90 125
aae8302a
JB
126%if %{with doc}
127%{__make} -C docs html \
128 SPHINXBUILD=sphinx-build-2
129%endif
130
be70ea90 131%install
132rm -rf $RPM_BUILD_ROOT
44562528
JK
133
134%if %{with python2}
d357e5f5 135%py_install
be70ea90 136
137%py_postclean
44562528
JK
138%endif
139
140%if %{with python3}
d357e5f5 141%py3_install
44562528 142%endif
be70ea90 143
144%clean
145rm -rf $RPM_BUILD_ROOT
146
65a38e1a 147%if %{with python2}
be70ea90 148%files
14a88007 149%defattr(644,root,root,755)
4f09112b 150%doc AUTHORS FAQ LICENSE README.rst THANKS TODO
14a88007 151%{py_sitescriptdir}/%{module}
14a88007 152%{py_sitescriptdir}/%{module}-*.egg-info
65a38e1a
JK
153%endif
154
155%if %{with python3}
44562528
JK
156%files -n python3-%{module}
157%defattr(644,root,root,755)
4f09112b 158%doc AUTHORS FAQ LICENSE README.rst THANKS TODO
44562528
JK
159%{py3_sitescriptdir}/%{module}
160%{py3_sitescriptdir}/%{module}-*.egg-info
aae8302a 161%endif
44562528
JK
162
163%if %{with doc}
aae8302a 164%files apidocs
44562528 165%defattr(644,root,root,755)
aae8302a 166%doc docs/_build/html/{_modules,_static,reference,userguide,*.html,*.js}
14a88007 167%endif
This page took 0.110026 seconds and 4 git commands to generate.