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