3 %bcond_without doc # API documentation
4 %bcond_with tests # unit tests
7 Summary: JSON Web Token implementation in Python 3
8 Summary(pl.UTF-8): Implementacja JSON Web Token w Pythonie 3
9 Name: python3-%{module}
13 Group: Libraries/Python
14 #Source0Download: https://pypi.org/simple/pyjwt/
15 Source0: https://files.pythonhosted.org/packages/source/P/PyJWT/PyJWT-%{version}.tar.gz
16 # Source0-md5: 93b74f59d08be8c852a3c259da2ea121
17 URL: http://github.com/jpadilla/pyjwt
18 BuildRequires: python3-modules >= 1:3.6
19 BuildRequires: python3-setuptools
21 BuildRequires: python3-cryptography >= 3.3.1
22 BuildRequires: python3-pytest >= 5.0.0
24 BuildRequires: rpm-pythonprov
25 BuildRequires: rpmbuild(macros) >= 1.714
27 BuildRequires: python3-sphinx_rtd_theme
28 BuildRequires: sphinx-pdg-3
30 # file and namespace conflict
31 Conflicts: python3-jwt
33 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36 A Python implementation of RFC 7519. Original implementation was
39 %description -l pl.UTF-8
40 Pythonowa implementacja RFC 7519. Oryginalna implementacja została
41 napisana przez @progrium.
44 Summary: API documentation for PyJWT
45 Summary(pl.UTF-8): Dokumentacja API moduły PyJWT
49 API documentation for PyJWT.
51 %description apidocs -l pl.UTF-8
52 Dokumentacja API moduły PyJWT.
55 %setup -q -n PyJWT-%{version}
57 # Remove bundled egg-info
58 %{__rm} -r PyJWT.egg-info
64 %{__python3} -m pytest tests
68 %{__make} -C docs html \
69 SPHINXBUILD=sphinx-build-3
73 rm -rf $RPM_BUILD_ROOT
78 rm -rf $RPM_BUILD_ROOT
81 %defattr(644,root,root,755)
82 %doc AUTHORS.rst CHANGELOG.rst LICENSE README.rst
83 %{py3_sitescriptdir}/jwt
84 %{py3_sitescriptdir}/PyJWT-%{version}-py*.egg-info
88 %defattr(644,root,root,755)
89 %doc docs/_build/html/{_static,*.html,*.js}