]>
Commit | Line | Data |
---|---|---|
2a95feb1 JB |
1 | # |
2 | # Conditional build: | |
b167f38b | 3 | %bcond_without static_libs # do not build static libraries |
3b3330f6 | 4 | %bcond_without commonlisp # Common Lisp interface |
04bb14bc JB |
5 | %bcond_without cxx # C++ interface (GpgMEpp library) |
6 | %bcond_without qt5 # Qt 5 interface (QGpgME library), requires cxx | |
7 | %bcond_without python # Python interfaces (PyME, both python2+python3) | |
8 | %bcond_without python2 # Python 2 interface (PyME) | |
9 | %bcond_without python3 # Python 3 interface (PyME) | |
146a76ab | 10 | %bcond_without tests # perform tests |
2a95feb1 | 11 | # |
04bb14bc JB |
12 | %if %{without python} |
13 | %undefine with_python2 | |
14 | %undefine with_python3 | |
15 | %endif | |
16 | %if %{without cxx} | |
17 | %undefine with_qt5 | |
18 | %endif | |
01babd9f | 19 | Summary: Library for accessing GnuPG |
ab1d0abf | 20 | Summary(pl.UTF-8): Biblioteka dająca dostęp do funkcji GnuPG |
01babd9f | 21 | Name: gpgme |
ef89bcd2 | 22 | Version: 1.13.0 |
ddea86d7 | 23 | Release: 1 |
92e3a3cd | 24 | Epoch: 1 |
57d17492 | 25 | License: LGPL v2.1+ |
01babd9f | 26 | Group: Libraries |
57d17492 | 27 | Source0: ftp://ftp.gnupg.org/gcrypt/gpgme/%{name}-%{version}.tar.bz2 |
ef89bcd2 | 28 | # Source0-md5: e511a0d95c507ab87e713140c82fc7d0 |
41e9547e | 29 | Patch0: %{name}-info.patch |
2b597a7e | 30 | Patch1: %{name}-kill-tests.patch |
04bb14bc JB |
31 | Patch2: %{name}-largefile.patch |
32 | Patch3: %{name}-python.patch | |
01babd9f | 33 | URL: http://www.gnupg.org/gpgme.html |
50116f20 | 34 | BuildRequires: autoconf >= 2.59 |
74664a9d | 35 | BuildRequires: automake >= 1:1.14 |
a4b4d7c9 | 36 | %{?with_tests:BuildRequires: gnupg-agent} |
6359b091 | 37 | %{?with_tests:BuildRequires: gnupg-smime} |
d3ec171e | 38 | BuildRequires: libassuan-devel >= 1:2.4.2 |
a7d28b40 | 39 | BuildRequires: libgpg-error-devel >= 1.29 |
04bb14bc | 40 | %{?with_cxx:BuildRequires: libstdc++-devel >= 6:4.7} |
f85acd43 | 41 | BuildRequires: libtool >= 2:2.2.6 |
04bb14bc JB |
42 | %{?with_python2:BuildRequires: python-devel >= 1:2.7} |
43 | %{?with_python3:BuildRequires: python3-devel >= 1:3.4} | |
44 | %{?with_python:BuildRequires: rpm-pythonprov} | |
45 | BuildRequires: rpmbuild(macros) >= 1.219 | |
46 | %{?with_python:BuildRequires: swig-python} | |
41e9547e | 47 | BuildRequires: texinfo |
04bb14bc JB |
48 | %if %{with qt5} |
49 | BuildRequires: Qt5Core-devel >= 5.0.0 | |
50 | %{?with_tests:BuildRequires: Qt5Test-devel >= 5.0.0} | |
51 | BuildRequires: doxygen | |
52 | BuildRequires: graphviz | |
53 | BuildRequires: qt5-build >= 5.0.0 | |
54 | %endif | |
4c03fa3d | 55 | BuildConflicts: gnupg < 1.3.0 |
86e07236 TP |
56 | Suggests: gnupg >= 1.4.0 |
57 | Suggests: gnupg-smime >= 1.9.8 | |
58 | Suggests: gnupg2 >= 2.0.4 | |
d3ec171e | 59 | Requires: libassuan >= 1:2.4.2 |
a7d28b40 | 60 | Requires: libgpg-error >= 1.29 |
8ceb1a35 | 61 | Obsoletes: cryptplug |
01babd9f | 62 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
63 | ||
64 | %description | |
65 | A library for accessing GnuPG. | |
66 | ||
1dd36cc5 JR |
67 | %description -l pl.UTF-8 |
68 | Biblioteka dająca dostęp do funkcji GnuPG. | |
01babd9f | 69 | |
70 | %package devel | |
bed1b366 | 71 | Summary: Header files for GPGME library |
ab1d0abf | 72 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki GPGME |
3b45cfe6 | 73 | Group: Development/Libraries |
92e3a3cd | 74 | Requires: %{name} = %{epoch}:%{version}-%{release} |
d3ec171e | 75 | Requires: libassuan-devel >= 1:2.4.2 |
a7d28b40 | 76 | Requires: libgpg-error-devel >= 1.29 |
01babd9f | 77 | |
78 | %description devel | |
bed1b366 JB |
79 | Header files for GPGME library, needed for compiling programs using |
80 | GPGME. | |
01babd9f | 81 | |
1dd36cc5 JR |
82 | %description devel -l pl.UTF-8 |
83 | Pliki nagłówkowe biblioteki GPGME, potrzebne do kompilacji programów | |
84 | używających GPGME. | |
01babd9f | 85 | |
86 | %package static | |
bed1b366 | 87 | Summary: Static version of GPGME library |
ab1d0abf | 88 | Summary(pl.UTF-8): Statyczna wersja biblioteki GPGME |
01babd9f | 89 | Group: Development/Libraries |
92e3a3cd | 90 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
01babd9f | 91 | |
92 | %description static | |
bed1b366 | 93 | Static version of GPGME library. |
01babd9f | 94 | |
1dd36cc5 | 95 | %description static -l pl.UTF-8 |
bed1b366 | 96 | Statyczna wersja biblioteki GPGME. |
01babd9f | 97 | |
04bb14bc JB |
98 | %package c++ |
99 | Summary: GpgMEpp - C++ interface for GPGME library | |
100 | Summary(pl.UTF-8): GpgMEpp - interfejs C++ do biblioteki GPGME | |
101 | Group: Libraries | |
7f5e677d | 102 | Requires: %{name} = %{epoch}:%{version}-%{release} |
04bb14bc JB |
103 | |
104 | %description c++ | |
105 | GpgMEpp is a C++ wrapper (or C++ bindings) for the GnuPG project's | |
106 | gpgme (GnuPG Made Easy). It's based on KF5gpgmepp library. | |
107 | ||
108 | %description c++ -l pl.UTF-8 | |
109 | GpgMEpp to interfejs C++ (wiązania C++) do biblioteki gpgme (GnuPG | |
110 | Made Easy) z projektu GnuPG. Jest oparty na bibliotece KF5gpgme.pp. | |
111 | ||
112 | %package c++-devel | |
113 | Summary: Header files for GpgMEpp library | |
114 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki GpgMEpp | |
115 | Group: Development/Libraries | |
7f5e677d | 116 | Requires: %{name}-c++ = %{epoch}:%{version}-%{release} |
04bb14bc | 117 | Requires: libstdc++-devel >= 6:4.7 |
a4b4d7c9 | 118 | Conflicts: kde4-kdepimlibs-devel |
04bb14bc JB |
119 | |
120 | %description c++-devel | |
121 | Header files for GpgMEpp library. | |
122 | ||
123 | %description c++-devel -l pl.UTF-8 | |
124 | Pliki nagłówkowe biblioteki GpgMEpp. | |
125 | ||
126 | %package c++-static | |
127 | Summary: Static GpgMEpp library | |
128 | Summary(pl.UTF-8): Statyczna biblioteka GpgMEpp | |
129 | Group: Development/Libraries | |
7f5e677d | 130 | Requires: %{name}-c++-devel = %{epoch}:%{version}-%{release} |
04bb14bc JB |
131 | |
132 | %description c++-static | |
133 | Static GpgMEpp library. | |
134 | ||
135 | %description c++-static -l pl.UTF-8 | |
136 | Statyczna biblioteka GpgMEpp. | |
137 | ||
138 | %package qt5 | |
139 | Summary: QGpgME - Qt 5 interface for GPGME library | |
140 | Summary(pl.UTF-8): QGpgME - interfejs Qt 5 do biblioteki GPGME | |
141 | License: GPL v2+ with Qt linking exception | |
142 | Group: Libraries | |
7f5e677d | 143 | Requires: %{name}-c++ = %{epoch}:%{version}-%{release} |
04bb14bc JB |
144 | Requires: Qt5Core >= 5.0.0 |
145 | ||
146 | %description qt5 | |
147 | QGpgME is Qt 5 interface for GPGME library, based on library from | |
148 | KF5gpgmepp. QGpgME provides a very high level Qt API around GpgMEpp. | |
149 | ||
150 | %description qt5 -l pl.UTF-8 | |
151 | QGpgME to interfejs Qt 5 do biblioteki GPGME, oparty na bibliotece z | |
152 | KF5gpgmepp. QGpgME udostępnia API Qt do GpgMEpp bardzo wysokiego | |
153 | poziomu. | |
154 | ||
155 | %package qt5-devel | |
156 | Summary: Header files for QGpgME library | |
157 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki QGpgME | |
158 | License: GPL v2+ with Qt linking exception | |
159 | Group: Development/Libraries | |
7f5e677d JR |
160 | Requires: %{name}-c++-devel = %{epoch}:%{version}-%{release} |
161 | Requires: %{name}-qt5 = %{epoch}:%{version}-%{release} | |
04bb14bc | 162 | Requires: Qt5Core-devel >= 5.0.0 |
a4b4d7c9 | 163 | Conflicts: kde4-kdepimlibs-devel |
04bb14bc JB |
164 | |
165 | %description qt5-devel | |
166 | Header files for QGpgME library. | |
167 | ||
168 | %description qt5-devel -l pl.UTF-8 | |
169 | Pliki nagłówkowe biblioteki QGpgME. | |
170 | ||
171 | %package qt5-static | |
172 | Summary: Static QGpgME library | |
173 | Summary(pl.UTF-8): Statyczna biblioteka QGpgME | |
174 | License: GPL v2+ with Qt linking exception | |
175 | Group: Development/Libraries | |
7f5e677d | 176 | Requires: %{name}-qt5-devel = %{epoch}:%{version}-%{release} |
04bb14bc JB |
177 | |
178 | %description qt5-static | |
179 | Static QGpgME library. | |
180 | ||
181 | %description qt5-static -l pl.UTF-8 | |
182 | Statyczna biblioteka QGpgME. | |
183 | ||
3b3330f6 JB |
184 | %package -n common-lisp-gpgme |
185 | Summary: Common Lisp binding for GPGME library | |
186 | Summary(pl.UTF-8): Wiązanie Common Lispa do biblioteki GPGME | |
187 | Group: Libraries | |
7f5e677d | 188 | Requires: %{name} = %{epoch}:%{version}-%{release} |
3b3330f6 JB |
189 | Requires: common-lisp-controller |
190 | ||
191 | %description -n common-lisp-gpgme | |
192 | Common Lisp binding for GPGME library. | |
193 | ||
194 | %description -n common-lisp-gpgme -l pl.UTF-8 | |
195 | Wiązanie Common Lispa do biblioteki GPGME. | |
196 | ||
ac6cdcae | 197 | %package -n python-gpg |
04bb14bc JB |
198 | Summary: PyME - Python 2 interface for GPGME library |
199 | Summary(pl.UTF-8): PyME - interfejs Pythona 2 do biblioteki GPGME | |
200 | Group: Libraries/Python | |
7f5e677d | 201 | Requires: %{name} = %{epoch}:%{version}-%{release} |
04bb14bc | 202 | Requires: python-libs >= 1:2.7 |
ac6cdcae | 203 | Obsoletes: python-pyme < 1.8.0 |
04bb14bc | 204 | |
ac6cdcae | 205 | %description -n python-gpg |
04bb14bc JB |
206 | PyME is a Python interface for GPGME library. |
207 | ||
ac6cdcae | 208 | %description -n python-gpg -l pl.UTF-8 |
04bb14bc JB |
209 | PyME to interfejs Pythona do biblioteki GPGME. |
210 | ||
ac6cdcae | 211 | %package -n python3-gpg |
04bb14bc JB |
212 | Summary: PyME - Python 3 interface for GPGME library |
213 | Summary(pl.UTF-8): PyME - interfejs Pythona 3 do biblioteki GPGME | |
214 | Group: Libraries/Python | |
7f5e677d | 215 | Requires: %{name} = %{epoch}:%{version}-%{release} |
04bb14bc | 216 | Requires: python3-libs >= 1:3.4 |
ac6cdcae | 217 | Obsoletes: python3-pyme < 1.8.0 |
04bb14bc | 218 | |
ac6cdcae | 219 | %description -n python3-gpg |
04bb14bc JB |
220 | PyME is a Python interface for GPGME library. |
221 | ||
ac6cdcae | 222 | %description -n python3-gpg -l pl.UTF-8 |
04bb14bc JB |
223 | PyME to interfejs Pythona do biblioteki GPGME. |
224 | ||
01babd9f | 225 | %prep |
226 | %setup -q | |
41e9547e | 227 | %patch0 -p1 |
146a76ab | 228 | %patch1 -p1 |
44f0380a | 229 | %patch2 -p1 |
04bb14bc | 230 | %patch3 -p1 |
01babd9f | 231 | |
232 | %build | |
ba43bb7f | 233 | %{__libtoolize} |
2c260d51 | 234 | %{__aclocal} -I m4 |
7cde39a6 | 235 | %{__autoconf} |
b7ca4280 | 236 | %{__autoheader} |
7cde39a6 | 237 | %{__automake} |
04bb14bc JB |
238 | # in enable-languages: |
239 | # "python" means both pythons (if available), "python2" just python2, "python3" just python3 | |
240 | # (cannot specify "python2 python3" due to script limitations) | |
01babd9f | 241 | %configure \ |
146a76ab JB |
242 | %if %{without tests} |
243 | --disable-g13-test \ | |
244 | --disable-gpg-test \ | |
245 | --disable-gpgconf-test \ | |
246 | --disable-gpgsm-test \ | |
247 | %endif | |
04bb14bc | 248 | --enable-languages="%{?with_commonlisp:cl} %{?with_cxx:cpp} %{?with_python2:python%{!?with_python3:2}} %{?with_python3:%{!?with_python2:python3}} %{?with_qt5:qt}" \ |
86e07236 | 249 | %{?with_static_libs:--enable-static} |
01babd9f | 250 | |
251 | %{__make} | |
252 | ||
253 | %install | |
254 | rm -rf $RPM_BUILD_ROOT | |
01babd9f | 255 | |
8815e16b JB |
256 | %{__make} install \ |
257 | DESTDIR=$RPM_BUILD_ROOT | |
01babd9f | 258 | |
ef89bcd2 JB |
259 | # Win32 specific |
260 | %{__rm} $RPM_BUILD_ROOT%{_pkgconfigdir}/gpgme-glib.pc | |
261 | ||
04bb14bc JB |
262 | %if %{with python2} |
263 | %py_postclean | |
264 | %endif | |
265 | ||
01babd9f | 266 | %clean |
267 | rm -rf $RPM_BUILD_ROOT | |
268 | ||
180ddcb9 JB |
269 | %post -p /sbin/ldconfig |
270 | %postun -p /sbin/ldconfig | |
271 | ||
f85acd43 | 272 | %post devel -p /sbin/postshell |
1cf551df | 273 | -/usr/sbin/fix-info-dir -c %{_infodir} |
01babd9f | 274 | |
f85acd43 | 275 | %postun devel -p /sbin/postshell |
1cf551df | 276 | -/usr/sbin/fix-info-dir -c %{_infodir} |
01babd9f | 277 | |
04bb14bc JB |
278 | %post c++ -p /sbin/ldconfig |
279 | %postun c++ -p /sbin/ldconfig | |
280 | ||
281 | %post qt5 -p /sbin/ldconfig | |
282 | %postun qt5 -p /sbin/ldconfig | |
283 | ||
01babd9f | 284 | %files |
285 | %defattr(644,root,root,755) | |
04bb14bc | 286 | %doc AUTHORS ChangeLog README NEWS THANKS TODO |
a7d28b40 | 287 | %attr(755,root,root) %{_bindir}/gpgme-json |
d158acd8 | 288 | %attr(755,root,root) %{_bindir}/gpgme-tool |
5276b199 JB |
289 | %attr(755,root,root) %{_libdir}/libgpgme.so.*.*.* |
290 | %attr(755,root,root) %ghost %{_libdir}/libgpgme.so.11 | |
01babd9f | 291 | |
292 | %files devel | |
3b45cfe6 JB |
293 | %defattr(644,root,root,755) |
294 | %attr(755,root,root) %{_bindir}/gpgme-config | |
5276b199 | 295 | %attr(755,root,root) %{_libdir}/libgpgme.so |
5276b199 | 296 | %{_libdir}/libgpgme.la |
5276b199 | 297 | %{_includedir}/gpgme.h |
ef89bcd2 | 298 | %{_pkgconfigdir}/gpgme.pc |
5276b199 JB |
299 | %{_aclocaldir}/gpgme.m4 |
300 | %{_infodir}/gpgme.info* | |
01babd9f | 301 | |
fa55d1b4 | 302 | %if %{with static_libs} |
01babd9f | 303 | %files static |
3b45cfe6 | 304 | %defattr(644,root,root,755) |
5276b199 | 305 | %{_libdir}/libgpgme.a |
fa55d1b4 | 306 | %endif |
04bb14bc JB |
307 | |
308 | %if %{with cxx} | |
309 | %files c++ | |
310 | %defattr(644,root,root,755) | |
311 | %doc lang/cpp/README | |
312 | %attr(755,root,root) %{_libdir}/libgpgmepp.so.*.*.* | |
313 | %attr(755,root,root) %ghost %{_libdir}/libgpgmepp.so.6 | |
314 | ||
315 | %files c++-devel | |
316 | %defattr(644,root,root,755) | |
317 | %attr(755,root,root) %{_libdir}/libgpgmepp.so | |
318 | %{_libdir}/libgpgmepp.la | |
319 | %{_includedir}/gpgme++ | |
ac6cdcae | 320 | %{_libdir}/cmake/Gpgmepp |
04bb14bc JB |
321 | |
322 | %if %{with static_libs} | |
323 | %files c++-static | |
324 | %defattr(644,root,root,755) | |
325 | %{_libdir}/libgpgmepp.a | |
326 | %endif | |
327 | ||
328 | %if %{with qt5} | |
329 | %files qt5 | |
330 | %defattr(644,root,root,755) | |
331 | %doc lang/qt/README | |
332 | %attr(755,root,root) %{_libdir}/libqgpgme.so.*.*.* | |
ac6cdcae | 333 | %attr(755,root,root) %ghost %{_libdir}/libqgpgme.so.7 |
04bb14bc JB |
334 | |
335 | %files qt5-devel | |
336 | %defattr(644,root,root,755) | |
337 | %attr(755,root,root) %{_libdir}/libqgpgme.so | |
338 | %{_libdir}/libqgpgme.la | |
339 | %{_includedir}/QGpgME | |
340 | %{_includedir}/qgpgme | |
ac6cdcae | 341 | %{_libdir}/cmake/QGpgme |
04bb14bc JB |
342 | |
343 | %if %{with static_libs} | |
344 | %files qt5-static | |
345 | %defattr(644,root,root,755) | |
346 | %{_libdir}/libqgpgme.a | |
347 | %endif | |
348 | %endif | |
349 | %endif | |
350 | ||
3b3330f6 JB |
351 | %if %{with commonlisp} |
352 | %files -n common-lisp-gpgme | |
353 | %defattr(644,root,root,755) | |
354 | %doc lang/cl/README | |
355 | %{_datadir}/common-lisp/source/gpgme | |
356 | %endif | |
357 | ||
04bb14bc | 358 | %if %{with python2} |
ac6cdcae | 359 | %files -n python-gpg |
04bb14bc JB |
360 | %defattr(644,root,root,755) |
361 | %doc lang/python/README | |
ac6cdcae JB |
362 | %dir %{py_sitedir}/gpg |
363 | %attr(755,root,root) %{py_sitedir}/gpg/_gpgme.so | |
364 | %{py_sitedir}/gpg/*.py[co] | |
365 | %{py_sitedir}/gpg/constants | |
ef89bcd2 | 366 | %{py_sitedir}/gpg-%{version}_unknown-py*.egg-info |
04bb14bc JB |
367 | %endif |
368 | ||
369 | %if %{with python3} | |
ac6cdcae | 370 | %files -n python3-gpg |
04bb14bc JB |
371 | %defattr(644,root,root,755) |
372 | %doc lang/python/README | |
ac6cdcae JB |
373 | %dir %{py3_sitedir}/gpg |
374 | %attr(755,root,root) %{py3_sitedir}/gpg/_gpgme.cpython-*.so | |
375 | %{py3_sitedir}/gpg/*.py | |
376 | %{py3_sitedir}/gpg/__pycache__ | |
377 | %{py3_sitedir}/gpg/constants | |
ef89bcd2 | 378 | %{py3_sitedir}/gpg-%{version}_unknown-py*.egg-info |
04bb14bc | 379 | %endif |