]>
Commit | Line | Data |
---|---|---|
eaba2e1b JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # unit tests | |
4 | ||
5 | Summary: Ultra fast JSON encoder and decoder for Python | |
6 | Summary(pl.UTF-8): Ultraszybki koder i dekoder formatu JSON dla Pythona | |
7 | Name: python3-ujson | |
8 | Version: 3.0.0 | |
31c33af4 | 9 | Release: 4 |
eaba2e1b JB |
10 | License: BSD |
11 | Group: Libraries/Python | |
12 | #Source0Download: https://pypi.org/simple/ujson/ | |
13 | Source0: https://files.pythonhosted.org/packages/source/u/ujson/ujson-%{version}.tar.gz | |
14 | # Source0-md5: 1c13a485776a2a0dfa1795d101bb3d57 | |
15 | URL: https://pypi.org/project/ujson/ | |
16 | BuildRequires: libstdc++-devel | |
17 | BuildRequires: python3-devel >= 1:3.5 | |
18 | BuildRequires: python3-setuptools | |
19 | BuildRequires: python3-setuptools_scm | |
20 | %if %{with tests} | |
21 | BuildRequires: python3-pytest | |
22 | %endif | |
23 | BuildRequires: rpm-pythonprov | |
24 | BuildRequires: rpmbuild(macros) >= 1.714 | |
5e378d29 | 25 | Requires: python3-modules >= 1:3.5 |
eaba2e1b JB |
26 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
27 | ||
28 | %description | |
29 | UltraJSON is an ultra fast JSON encoder and decoder written in pure C | |
30 | with bindings for Python 3.5+. | |
31 | ||
32 | %description -l pl.UTF-8 | |
33 | UltraJSON to ultraszybki koder i dekoder formatu JSON, napisany w | |
34 | czystym C z wiÄ…zaniami do Pythona 3.5+. | |
35 | ||
36 | %prep | |
37 | %setup -q -n ujson-%{version} | |
38 | ||
39 | %build | |
40 | %py3_build | |
41 | ||
42 | %if %{with tests} | |
43 | PYTHONPATH=$(readlink -f build-3/lib.*) \ | |
44 | %{__python3} -m pytest tests | |
45 | %endif | |
46 | ||
47 | %install | |
48 | rm -rf $RPM_BUILD_ROOT | |
49 | ||
50 | %py3_install | |
51 | ||
52 | %clean | |
53 | rm -rf $RPM_BUILD_ROOT | |
54 | ||
55 | %files | |
56 | %defattr(644,root,root,755) | |
57 | %doc LICENSE.txt README.rst | |
58 | %attr(755,root,root) %{py3_sitedir}/ujson.cpython-*.so | |
59 | %{py3_sitedir}/ujson-%{version}-py*.egg-info |