%global pypi_name pykeepass
Name: python-%{pypi_name}
Version: 3.0.3
Release: 1%{?dist}
Summary: Python library to interact with keepass databases (supports KDBX3 and KDBX4)
License: GPLv3
URL: https://github.com/pschmitt/pykeepass
Source0: %{pypi_source}
BuildArch: noarch
BuildRequires: python3-devel
BuildRequires: python3dist(setuptools)
%description
pykeepass library allows you to write entries to a KeePass database.
%package -n python3-%{pypi_name}
Summary: %{summary}
%{?python_provide:%python_provide python3-%{pypi_name}}
Requires: python3dist(argon2-cffi)
Requires: python3dist(construct)
Requires: python3dist(future)
Requires: python3dist(lxml)
Requires: python3dist(pycryptodome)
Requires: python3dist(python-dateutil)
%description -n python3-%{pypi_name}
pykeepass library allows you to write entries to a KeePass database.
%prep
%autosetup -n %{pypi_name}-%{version}
sed -i '1{/^#!.*env python/d}' pykeepass/pykeepass.py pykeepass/kdbx_parsing/kdbx*.py
# Remove bundled egg-info
rm -rf %{pypi_name}.egg-info
%build
%py3_build
%install
%py3_install
rm -rf %{buildroot}%{$python_sitelib}/tests
%files -n python3-%{pypi_name}
%license LICENSE
%doc README.rst
%{python3_sitelib}/%{pypi_name}
%{python3_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info
%changelog
* Fri Jun 14 2019 Pavlo Rudyi <paulcarroty@fedoraproject.org> - 3.0.3-1
- initial build