3 %bcond_without doc # Sphinx documentation
4 %bcond_with tests # unit tests [require dbus and some Secret Service daemon running]
5 %bcond_without python2 # CPython 2.x module
6 %bcond_without python3 # CPython 3.x module
8 Summary: Python 2 bindings to Freedesktop.org Secret Service API
9 Summary(pl.UTF-8): Wiązania Pythona 2 do API Secret Service z Freedesktop.org
10 Name: python-secretstorage
14 Group: Libraries/Python
15 #Source0Download: https://pypi.python.org/simple/secretstorage
16 Source0: https://pypi.python.org/packages/a5/a5/0830cfe34a4cfd0d1c3c8b614ede1edb2aaf999091ac8548dd19cb352e79/SecretStorage-%{version}.tar.gz
17 # Source0-md5: 3b9465831b069e2622973afb7deb7bc2
18 URL: https://github.com/mitya57/secretstorage
20 BuildRequires: python-modules >= 1:2.7
21 BuildRequires: python-setuptools
23 BuildRequires: python-cryptography
24 BuildRequires: python-dbus
28 BuildRequires: python3-modules >= 1:3.3
29 BuildRequires: python3-setuptools
31 BuildRequires: python3-Sphinx
34 BuildRequires: python3-cryptography
35 BuildRequires: python3-dbus
38 BuildRequires: rpm-pythonprov
39 BuildRequires: rpmbuild(macros) >= 1.714
40 Requires: python-modules >= 1:2.7
42 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45 This module provides a way for securely storing passwords and other
48 It uses D-Bus Secret Service API that is supported by GNOME Keyring
49 (since version 2.30) and KSecretsService.
51 %description -l pl.UTF-8
52 Ten moduł udostępnia sposób bezpiecznego przechowywania haseł i innych
55 Wykorzystuje API D-Bus Secret Service, obsługiwane przez GNOME Keyring
56 (od wersji 2.30) oraz KSecretsService.
58 %package -n python3-secretstorage
59 Summary: Python 3 bindings to Freedesktop.org Secret Service API
60 Summary(pl.UTF-8): Wiązania Pythona 3 do API Secret Service z Freedesktop.org
61 Group: Libraries/Python
62 Requires: python3-modules >= 1:3.3
64 %description -n python3-secretstorage
65 This module provides a way for securely storing passwords and other
68 It uses D-Bus Secret Service API that is supported by GNOME Keyring
69 (since version 2.30) and KSecretsService.
71 %description -n python3-secretstorage -l pl.UTF-8
72 Ten moduł udostępnia sposób bezpiecznego przechowywania haseł i innych
75 Wykorzystuje API D-Bus Secret Service, obsługiwane przez GNOME Keyring
76 (od wersji 2.30) oraz KSecretsService.
79 Summary: secretstorage API documentation
80 Summary(pl.UTF-8): Dokumentacja API secretstorage
84 API documentation for secretstorage.
86 %description apidocs -l pl.UTF-8
87 Dokumentacja API secretstorage.
90 %setup -q -n SecretStorage-%{version}
94 %py_build %{?with_tests:test}
97 %{__python} -m unittest discover -s tests
102 %py3_build %{?with_tests:test} %{?with_doc:build_sphinx}
105 %{__python3} -m unittest discover -s tests
110 rm -rf $RPM_BUILD_ROOT
123 rm -rf $RPM_BUILD_ROOT
127 %defattr(644,root,root,755)
128 %doc LICENSE README.rst changelog
129 %{py_sitescriptdir}/secretstorage
130 %{py_sitescriptdir}/SecretStorage-%{version}-py*.egg-info
134 %files -n python3-secretstorage
135 %defattr(644,root,root,755)
136 %doc LICENSE README.rst changelog
137 %{py3_sitescriptdir}/secretstorage
138 %{py3_sitescriptdir}/SecretStorage-%{version}-py*.egg-info
143 %defattr(644,root,root,755)
144 %doc build-3/sphinx/html/{_static,*.html,*.js}