]> git.pld-linux.org Git - packages/python-secretstorage.git/blob - python-secretstorage.spec
f18a44a43242323467bb08bbf6675d3e3fa7c5b9
[packages/python-secretstorage.git] / python-secretstorage.spec
1 #
2 # Conditional build:
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
7
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
11 Version:        2.1.4
12 Release:        1
13 License:        BSD
14 Group:          Libraries/Python
15 #Source0Download: https://pypi.python.org/simple/secretstorage
16 Source0:        https://pypi.python.org/packages/c9/b0/833d13a07319ff9b9815d1683c5ece719f6e467b8217c1c6a42bc37a3aa9/SecretStorage-%{version}.tar.gz
17 # Source0-md5:  80ca4a4a0614daf45ee3d0fb17eb41cd
18 URL:            https://github.com/mitya57/secretstorage
19 BuildRequires:  rpm-pythonprov
20 # for the py_build, py_install macros
21 BuildRequires:  rpmbuild(macros) >= 1.714
22 %if %{with python2}
23 BuildRequires:  python-modules >= 1:2.7
24 BuildRequires:  python-setuptools
25 %endif
26 %if %{with python3}
27 BuildRequires:  python3-modules >= 1:3.2
28 BuildRequires:  python3-setuptools
29 %if %{with doc}
30 BuildRequires:  python3-Sphinx
31 %endif
32 %endif
33 Requires:       python-modules >= 1:2.7
34 BuildArch:      noarch
35 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37 %description
38 This module provides a way for securely storing passwords and other
39 secrets.
40
41 It uses D-Bus Secret Service API that is supported by GNOME Keyring
42 (since version 2.30) and KSecretsService.
43
44 %description -l pl.UTF-8
45 Ten moduł udostępnia sposób bezpiecznego przechowywania haseł i innych
46 tajnych danych.
47
48 Wykorzystuje API D-Bus Secret Service, obsługiwane przez GNOME Keyring
49 (od wersji 2.30) oraz KSecretsService.
50
51 %package -n python3-secretstorage
52 Summary:        Python 3 bindings to Freedesktop.org Secret Service API
53 Summary(pl.UTF-8):      Wiązania Pythona 3 do API Secret Service z Freedesktop.org
54 Group:          Libraries/Python
55 Requires:       python3-modules >= 1:3.2
56
57 %description -n python3-secretstorage
58 This module provides a way for securely storing passwords and other
59 secrets.
60
61 It uses D-Bus Secret Service API that is supported by GNOME Keyring
62 (since version 2.30) and KSecretsService.
63
64 %description -n python3-secretstorage -l pl.UTF-8
65 Ten moduł udostępnia sposób bezpiecznego przechowywania haseł i innych
66 tajnych danych.
67
68 Wykorzystuje API D-Bus Secret Service, obsługiwane przez GNOME Keyring
69 (od wersji 2.30) oraz KSecretsService.
70
71 %package apidocs
72 Summary:        secretstorage API documentation
73 Summary(pl.UTF-8):      Dokumentacja API secretstorage
74 Group:          Documentation
75
76 %description apidocs
77 API documentation for secretstorage.
78
79 %description apidocs -l pl.UTF-8
80 Dokumentacja API secretstorage.
81
82 %prep
83 %setup -q -n SecretStorage-%{version}
84
85 %build
86 %if %{with python2}
87 %py_build %{?with_tests:test}
88
89 %if %{with tests}
90 %{__python} -m unittest discover -s tests
91 %endif
92 %endif
93
94 %if %{with python3}
95 %py3_build %{?with_tests:test} %{?with_doc:build_sphinx}
96
97 %if %{with tests}
98 %{__python3} -m unittest discover -s tests
99 %endif
100 %endif
101
102 %install
103 rm -rf $RPM_BUILD_ROOT
104
105 %if %{with python2}
106 %py_install
107
108 %py_postclean
109 %endif
110
111 %if %{with python3}
112 %py3_install
113 %endif
114
115 %clean
116 rm -rf $RPM_BUILD_ROOT
117
118 %if %{with python2}
119 %files
120 %defattr(644,root,root,755)
121 %doc LICENSE README.rst changelog
122 %{py_sitescriptdir}/secretstorage
123 %{py_sitescriptdir}/SecretStorage-%{version}-py*.egg-info
124 %endif
125
126 %if %{with python3}
127 %files -n python3-secretstorage
128 %defattr(644,root,root,755)
129 %doc LICENSE README.rst changelog
130 %{py3_sitescriptdir}/secretstorage
131 %{py3_sitescriptdir}/SecretStorage-%{version}-py*.egg-info
132 %endif
133
134 %if %{with doc}
135 %files apidocs
136 %defattr(644,root,root,755)
137 %doc build-3/sphinx/html/{_modules,_static,*.html,*.js}
138 %endif
This page took 0.068956 seconds and 2 git commands to generate.