commit f5c108795c1c3a0344f30131448ae62f38585826 Author: Daniel Uvehag Date: Thu Apr 14 16:34:32 2022 +0200 Initial package diff --git a/python-argon2-cffi.spec b/python-argon2-cffi.spec new file mode 100644 index 0000000..b7fd3d7 --- /dev/null +++ b/python-argon2-cffi.spec @@ -0,0 +1,70 @@ +%global pypi_name argon2-cffi +%global pypi_version 20.1.0 +%global pypi_prefix %(c=%{pypi_name}; echo ${c:0:1}) +%global python_version_min 3.6 + +Name: python-%{pypi_name} +Version: %{pypi_version} +Release: 1%{?dist} +Summary: The secure Argon2 password hashing algorithm + +License: MIT +URL: https://argon2-cffi.readthedocs.io/ +Source0: https://files.pythonhosted.org/packages/source/%{pypi_prefix}/%{pypi_name}/%{pypi_name}-%{version}.tar.gz + +BuildRequires: gcc +BuildRequires: python%{python3_pkgversion}-devel +BuildRequires: python3dist(setuptools) +BuildRequires: python3dist(cffi) >= 1 +BuildRequires: python3dist(six) +BuildRequires: python3dist(sphinx) + +%global _description %{expand: +CFFI-based Argon2 Bindings for Python.} + +%description %{_description} + + +%package -n python3-%{pypi_name} +Summary: %{summary} +%{?python_provide:%python_provide python3-%{pypi_name}} + +Requires: python3dist(cffi) >= 1 +Requires: python3dist(six) +Requires: python3dist(sphinx) + +%description -n python3-%{pypi_name} +%{common_description} + + +%package -n python-%{pypi_name}-doc +Summary: argon2-cffi documentation + +%description -n python-%{pypi_name}-doc +Documentation for argon2-cffi + + +%prep +%autosetup -n %{pypi_name}-%{version} +rm -rf %{pypi_name}.egg-info + +%build +%py3_build +PYTHONPATH=${PWD} sphinx-build-3 docs html +rm -rf html/.{doctrees,buildinfo} + +%install +%py3_install + +%files -n python3-%{pypi_name} +%license LICENSE docs/license.rst extras/libargon2/LICENSE +%doc README.rst extras/libargon2/README.md +%{python3_sitearch}/argon2 +%{python3_sitearch}/argon2_cffi-%{version}-py%{python3_version}.egg-info + +%files -n python-%{pypi_name}-doc +%doc html + +%changelog +* Thu Apr 14 2022 Daniel Uvehag - 20.1.0-1 +- Initial package.