]>
Commit | Line | Data |
---|---|---|
79f30f85 | 1 | # |
03076a38 | 2 | # Conditional build: |
b5bc826d | 3 | %bcond_without tests # testsuite on build |
74217b8a | 4 | %bcond_without dirmngr # dirmngr packages build |
19e8899b | 5 | %bcond_without default_gpg # install as gpg/gpgv instead of gpg2/gpgv2 |
b5bc826d JB |
6 | %bcond_with gnutls # GnuTLS instead of NTBTLS |
7 | %bcond_with selinux # "SELinux hacks" | |
d54c94db | 8 | # |
f56b1d35 JB |
9 | Summary: GNU Privacy Guard - tool for secure communication and data storage - enhanced version |
10 | Summary(pl.UTF-8): GnuPG - narzędzie do bezpiecznej komunikacji i bezpiecznego przechowywania danych - wersja rozszerzona | |
c85d209c | 11 | Name: gnupg2 |
c5415c1e | 12 | Version: 2.2.7 |
aab2acb5 | 13 | Release: 2 |
71099ee5 | 14 | License: GPL v3+ |
b626fce0 | 15 | Group: Applications/File |
d47c18c2 | 16 | Source0: ftp://ftp.gnupg.org/gcrypt/gnupg/gnupg-%{version}.tar.bz2 |
c5415c1e | 17 | # Source0-md5: fc13424af7747a5dd6edb6086ec0cb2f |
b626fce0 | 18 | Source1: gnupg-agent.sh |
c85d209c | 19 | Patch0: %{name}-info.patch |
19e8899b | 20 | Patch1: %{name}-nogit.patch |
ea6e9952 | 21 | Patch2: %{name}-disable_tests.patch |
6f582fc9 | 22 | Patch3: %{name}-pl.po-update.patch |
b626fce0 | 23 | URL: http://www.gnupg.org/ |
71099ee5 | 24 | BuildRequires: autoconf >= 2.61 |
cc42aea4 | 25 | BuildRequires: automake >= 1:1.14 |
b636b9b9 | 26 | BuildRequires: bzip2-devel |
da0f8718 | 27 | BuildRequires: curl-devel >= 7.10 |
169b8933 JB |
28 | BuildRequires: gettext-tools >= 0.17 |
29 | %{?with_gnutls:BuildRequires: gnutls-devel >= 3.0} | |
b3e6ee32 | 30 | BuildRequires: libassuan-devel >= 1:2.5.0 |
169b8933 JB |
31 | BuildRequires: libgcrypt-devel >= 1.7.0 |
32 | BuildRequires: libgpg-error-devel >= 1.24 | |
33 | BuildRequires: libksba-devel >= 1.3.4 | |
34 | BuildRequires: libusb-devel >= 1.0 | |
35 | BuildRequires: npth-devel >= 1.2 | |
36 | %{!?with_gnutls:BuildRequires: ntbtls-devel >= 0.1.0} | |
74217b8a | 37 | %{?with_dirmngr:BuildRequires: openldap-devel >= 2.4.6} |
169b8933 JB |
38 | BuildRequires: pkgconfig |
39 | BuildRequires: readline-devel | |
f197b41f | 40 | BuildRequires: rpmbuild(macros) >= 1.177 |
6f441ca0 | 41 | BuildRequires: sqlite3-devel >= 3.7 |
b626fce0 AM |
42 | BuildRequires: texinfo |
43 | BuildRequires: zlib-devel | |
c85d209c | 44 | Requires: gnupg2-common = %{version}-%{release} |
b5bc826d | 45 | Requires: sqlite3 >= 3.7 |
5516c085 JP |
46 | %if %{with default_gpg} |
47 | Obsoletes: gnupg < 2 | |
19e8899b AM |
48 | Obsoletes: gnupg-plugin-keys_curl < 2 |
49 | Obsoletes: gnupg-plugin-keys_hkp < 2 | |
5516c085 JP |
50 | Provides: gnupg = %{version}-%{release} |
51 | %endif | |
150f8795 | 52 | Suggests: gnupg-agent |
b626fce0 AM |
53 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
54 | ||
b5bc826d | 55 | %define pkglibexecdir %{_libexecdir}/gnupg2 |
b626fce0 AM |
56 | |
57 | %description | |
c85d209c AF |
58 | GnuPG is GNU's tool for secure communication and data storage. It can |
59 | be used to encrypt data and to create digital signatures. It includes | |
60 | an advanced key management facility and is compliant with the proposed | |
61 | OpenPGP Internet standard as described in RFC2440. | |
62 | ||
f56b1d35 | 63 | This is enhanced version. |
b626fce0 | 64 | |
0998c692 JR |
65 | %description -l pl.UTF-8 |
66 | GnuPG (GNU Privacy Guard) jest narzędziem do bezpiecznej komunikacji i | |
67 | bezpiecznego przechowywania danych. Może być używany do szyfrowania | |
68 | oraz podpisywania danych. Umożliwia zaawansowane zarządzanie kluczami | |
69 | i spełnia normy zdefiniowane w standardzie OpenPGP, który jest opisany | |
c85d209c AF |
70 | w RFC2440. |
71 | ||
f56b1d35 | 72 | To jest wersja rozszerzona. |
c85d209c AF |
73 | |
74 | %package common | |
75 | Summary: GnuPG - common files | |
4049c7b1 | 76 | Summary(pl.UTF-8): GnuPG - pliki wspólne |
c85d209c | 77 | Group: Applications/File |
5d1bd0e6 JB |
78 | Requires: libassuan >= 1:2.5.0 |
79 | Requires: libgcrypt >= 1.7.0 | |
80 | Requires: libgpg-error >= 1.24 | |
81 | Requires: libksba >= 1.3.4 | |
82 | Requires: npth >= 1.2 | |
83 | Obsoletes: gnupg2-plugin-keys_curl | |
84 | Obsoletes: gnupg2-plugin-keys_finger | |
85 | Obsoletes: gnupg2-plugin-keys_hkp | |
86 | Obsoletes: gnupg2-plugin-keys_kdns | |
87 | Obsoletes: gnupg2-plugin-keys_ldap | |
88 | Conflicts: gnupg < 1.4.18-2 | |
c85d209c AF |
89 | Conflicts: gnupg-agent < 1.9.14-2 |
90 | ||
91 | %description common | |
92 | Common files used by tools from GnuPG project. | |
93 | ||
0998c692 JR |
94 | %description common -l pl.UTF-8 |
95 | Pliki wspólne używane przez różne narzędzia z projektu GnuPG. | |
c85d209c AF |
96 | |
97 | %package -n gnupg-agent | |
98 | Summary: GnuPG extension - agent | |
4049c7b1 | 99 | Summary(pl.UTF-8): Rozszerzenie GnuPG - agent |
c85d209c | 100 | Group: Applications/File |
7b3cd4e7 | 101 | Requires: %{name}-common = %{version}-%{release} |
1dbb261a | 102 | Requires: pinentry >= 0.7.5-2 |
c85d209c AF |
103 | Obsoletes: newpg |
104 | ||
105 | %description -n gnupg-agent | |
106 | GnuPG extension - agent. | |
107 | ||
0998c692 | 108 | %description -n gnupg-agent -l pl.UTF-8 |
b626fce0 AM |
109 | Rozszerzenie GnuPG - agent. |
110 | ||
f197b41f | 111 | %package -n gnupg-agent-profile_d |
112 | Summary: gnupg-agent start script for text mode | |
4049c7b1 | 113 | Summary(pl.UTF-8): Skrypt startowy gnupg-agenta dla trybu tekstowego |
f197b41f | 114 | Group: Applications/File |
115 | Requires: gnupg-agent = %{version}-%{release} | |
116 | ||
117 | %description -n gnupg-agent-profile_d | |
118 | gnupg-agent start script for text mode. | |
119 | ||
0998c692 | 120 | %description -n gnupg-agent-profile_d -l pl.UTF-8 |
f197b41f | 121 | Skrypt startowy gnupg-agenta dla trybu tekstowego. |
122 | ||
123 | %package -n gnupg-agent-xinitrc | |
124 | Summary: gnupg-agent start script for X-Window mode | |
4049c7b1 | 125 | Summary(pl.UTF-8): Skrypt startowy gnupg-agenta dla trybu X-Window |
f197b41f | 126 | Group: Applications/File |
127 | Requires: gnupg-agent = %{version}-%{release} | |
128 | Requires: xinitrc | |
129 | ||
130 | %description -n gnupg-agent-xinitrc | |
131 | gnupg-agent start script for X-Window mode. | |
132 | ||
0998c692 | 133 | %description -n gnupg-agent-xinitrc -l pl.UTF-8 |
f197b41f | 134 | Skrypt startowy gnupg-agenta dla trybu X-Window. |
135 | ||
c85d209c AF |
136 | %package -n gnupg-smime |
137 | Summary: GnuPG extension - S/MIME support | |
4049c7b1 | 138 | Summary(pl.UTF-8): Rozszerzenie GnuPG - obsługa S/MIME |
c85d209c | 139 | Group: Applications/File |
7b3cd4e7 | 140 | Requires: %{name}-common = %{version}-%{release} |
c85d209c AF |
141 | Conflicts: gnupg-agent < 1.9.14-2 |
142 | ||
143 | %description -n gnupg-smime | |
144 | GnuPG extension - S/MIME support. | |
145 | ||
0998c692 JR |
146 | %description -n gnupg-smime -l pl.UTF-8 |
147 | Rozszerzenie GnuPG - obsługa S/MIME. | |
c85d209c | 148 | |
74217b8a JB |
149 | %package -n dirmngr |
150 | Summary: X509/LDAP certificate and revocation list client | |
151 | Summary(pl.UTF-8): Klient certyfikatów i list anulujących X509/LDAP | |
152 | Group: Applications | |
153 | Requires: %{name}-common = %{version}-%{release} | |
154 | ||
155 | %description -n dirmngr | |
156 | DirMngr is a client for managing and downloading certificate | |
157 | revocation lists (CRLs) for X509 certificates and for downloading the | |
158 | certificates themselves. DirMngr is usually invoked by gpgsm and in | |
159 | general not used directly. | |
160 | ||
161 | %description -n dirmngr -l pl.UTF-8 | |
162 | DirMngr to klient do zarządzania i pobierania list anulujących | |
163 | certyfikaty (CRLs - certificate revocation lists) dla certyfikatów | |
164 | X509 oraz do pobierania samych certyfikatów. DirMngr jest zwykle | |
165 | wywoływany przez gpgsm i nie używany bezpośrednio. | |
166 | ||
b626fce0 AM |
167 | %prep |
168 | %setup -q -n gnupg-%{version} | |
c85d209c | 169 | %patch0 -p1 |
491f1c67 | 170 | %patch1 -p1 |
19e8899b | 171 | |
ea6e9952 | 172 | %{!?with_tests:%patch2 -p1} |
6f441ca0 | 173 | #%patch3 -p1 |
6f582fc9 JB |
174 | |
175 | %{__rm} po/stamp-po | |
b626fce0 AM |
176 | |
177 | %build | |
3d3dbf69 | 178 | %{__gettextize} |
6f441ca0 | 179 | %{__aclocal} -I m4 |
3d3dbf69 JB |
180 | %{__autoconf} |
181 | %{__autoheader} | |
155bb60b | 182 | %{__automake} |
19e8899b AM |
183 | if (grep -q ^development_version=yes configure); then |
184 | echo "configure incorrectly rebuild with messed up development status and likely version and revision." >&2 | |
185 | echo "Consider fixing nogit.patch" >&2 | |
186 | exit 1 | |
187 | fi | |
188 | ||
b626fce0 | 189 | %configure \ |
b5bc826d | 190 | --libexecdir=%{pkglibexecdir} \ |
74217b8a | 191 | %{!?with_dirmngr:--disable-dirmngr} \ |
b5bc826d JB |
192 | --enable-g13 \ |
193 | %{!?with_default_gpg:--enable-gpg-is-gpg2} \ | |
169b8933 JB |
194 | %{?with_gnutls:--disable-ntbtls} \ |
195 | %{?with_selinux:--enable-selinux-support} \ | |
d47c18c2 | 196 | --enable-symcryptrun \ |
b5bc826d | 197 | --enable-wks-tools \ |
d47c18c2 | 198 | --with-capabilities \ |
1dbb261a | 199 | --with-pinentry-pgm=%{_bindir}/pinentry \ |
b626fce0 AM |
200 | --with-mailprog=/usr/lib/sendmail |
201 | ||
6f441ca0 JR |
202 | # required for info rebuild |
203 | %{__make} -C doc defs.inc | |
204 | ||
62f46a6b | 205 | %{__make} |
b626fce0 AM |
206 | |
207 | %install | |
208 | rm -rf $RPM_BUILD_ROOT | |
b626fce0 AM |
209 | |
210 | %{__make} install \ | |
c85d209c AF |
211 | DESTDIR=$RPM_BUILD_ROOT \ |
212 | pkglibdir=%{_libexecdir} | |
b626fce0 | 213 | |
f197b41f | 214 | install -D %{SOURCE1} $RPM_BUILD_ROOT/etc/profile.d/gnupg-agent.sh |
215 | install -D %{SOURCE1} $RPM_BUILD_ROOT/etc/X11/xinit/xinitrc.d/gnupg-agent.sh | |
c85d209c | 216 | |
74217b8a JB |
217 | %if %{without dirmngr} |
218 | %{__rm} $RPM_BUILD_ROOT%{_mandir}/{man1/dirmngr-client.1,man8/dirmngr.8} | |
219 | %endif | |
220 | ||
221 | %{__rm} -f $RPM_BUILD_ROOT%{_datadir}/info/dir | |
222 | ||
223 | # files useful for users packaged as %doc | |
224 | %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/gnupg | |
225 | ||
f1d02fc8 | 226 | %find_lang gnupg2 |
b626fce0 AM |
227 | |
228 | %clean | |
229 | rm -rf $RPM_BUILD_ROOT | |
230 | ||
6f441ca0 | 231 | %post common -p /sbin/postshell |
4be7d664 | 232 | -/usr/sbin/fix-info-dir -c %{_infodir} |
b626fce0 | 233 | |
6f441ca0 | 234 | %postun common -p /sbin/postshell |
4be7d664 | 235 | -/usr/sbin/fix-info-dir -c %{_infodir} |
b626fce0 | 236 | |
f197b41f | 237 | %triggerpostun -n gnupg-agent -- gnupg-agent < 1.9.16-2 |
238 | %banner gnupg-agent-1.9.16-2 << EOF | |
239 | Scripts for starting gnupg-agent have been moved to separate | |
240 | subpackages: gnupg-agent-profile_d and gnupg-agent-xinitrc. | |
84ab814f | 241 | EOF |
f197b41f | 242 | |
84ab814f | 243 | %files |
b626fce0 | 244 | %defattr(644,root,root,755) |
b5bc826d JB |
245 | %if %{with default_gpg} |
246 | %attr(755,root,root) %{_bindir}/gpg | |
247 | %attr(755,root,root) %{_bindir}/gpgv | |
248 | %{_mandir}/man1/gpg.1* | |
249 | %{_mandir}/man1/gpgv.1* | |
250 | %else | |
c85d209c AF |
251 | %attr(755,root,root) %{_bindir}/gpg2 |
252 | %attr(755,root,root) %{_bindir}/gpgv2 | |
579ff0a0 JB |
253 | %{_mandir}/man1/gpg2.1* |
254 | %{_mandir}/man1/gpgv2.1* | |
b5bc826d | 255 | %endif |
c85d209c AF |
256 | |
257 | %files common -f gnupg2.lang | |
258 | %defattr(644,root,root,755) | |
6f441ca0 JR |
259 | %doc AUTHORS ChangeLog ChangeLog-2011 NEWS README THANKS TODO doc/{DETAILS,FAQ,KEYSERVER,OpenPGP} doc/examples |
260 | %attr(755,root,root) %{_bindir}/g13 | |
df2f3764 | 261 | %attr(755,root,root) %{_bindir}/gpg-connect-agent |
a83b3e7b | 262 | %attr(755,root,root) %{_bindir}/gpgconf |
da4fafa6 | 263 | %attr(755,root,root) %{_bindir}/gpgparsemail |
6f441ca0 JR |
264 | %attr(755,root,root) %{_bindir}/gpgscm |
265 | %attr(755,root,root) %{_bindir}/gpgtar | |
579ff0a0 | 266 | %attr(755,root,root) %{_bindir}/kbxutil |
c85d209c AF |
267 | %attr(755,root,root) %{_bindir}/watchgnupg |
268 | %attr(755,root,root) %{_sbindir}/addgnupghome | |
21eea941 | 269 | %attr(755,root,root) %{_sbindir}/applygnupgdefaults |
b5bc826d JB |
270 | %attr(755,root,root) %{_sbindir}/g13-syshelp |
271 | %dir %{pkglibexecdir} | |
272 | ||
c85d209c | 273 | %{_datadir}/gnupg |
579ff0a0 JB |
274 | %{_mandir}/man1/gpg-connect-agent.1* |
275 | %{_mandir}/man1/gpgconf.1* | |
276 | %{_mandir}/man1/gpgparsemail.1* | |
99fb3cd8 | 277 | %{_mandir}/man1/gpgtar.1* |
579ff0a0 | 278 | %{_mandir}/man1/watchgnupg.1* |
6f441ca0 | 279 | %{_mandir}/man7/gnupg.7* |
579ff0a0 | 280 | %{_mandir}/man8/addgnupghome.8* |
21eea941 | 281 | %{_mandir}/man8/applygnupgdefaults.8* |
00461e0e | 282 | %{_infodir}/gnupg.info* |
c85d209c AF |
283 | |
284 | %files -n gnupg-smime | |
285 | %defattr(644,root,root,755) | |
b626fce0 | 286 | %attr(755,root,root) %{_bindir}/gpgsm |
579ff0a0 | 287 | %{_mandir}/man1/gpgsm.1* |
c85d209c AF |
288 | |
289 | %files -n gnupg-agent | |
290 | %defattr(644,root,root,755) | |
c85d209c | 291 | %attr(755,root,root) %{_bindir}/gpg-agent |
b5bc826d | 292 | %attr(755,root,root) %{_bindir}/gpg-wks-server |
d47c18c2 | 293 | %attr(755,root,root) %{_bindir}/symcryptrun |
b5bc826d JB |
294 | %attr(755,root,root) %{pkglibexecdir}/gpg-check-pattern |
295 | %attr(755,root,root) %{pkglibexecdir}/gpg-protect-tool | |
296 | %attr(755,root,root) %{pkglibexecdir}/gpg-preset-passphrase | |
297 | %attr(755,root,root) %{pkglibexecdir}/gpg-wks-client | |
298 | %attr(755,root,root) %{pkglibexecdir}/scdaemon | |
579ff0a0 JB |
299 | %{_mandir}/man1/gpg-agent.1* |
300 | %{_mandir}/man1/gpg-preset-passphrase.1* | |
b5bc826d JB |
301 | %{_mandir}/man1/gpg-wks-client.1* |
302 | %{_mandir}/man1/gpg-wks-server.1* | |
579ff0a0 | 303 | %{_mandir}/man1/scdaemon.1* |
d47c18c2 | 304 | %{_mandir}/man1/symcryptrun.1* |
f197b41f | 305 | |
306 | %files -n gnupg-agent-profile_d | |
307 | %defattr(644,root,root,755) | |
c85d209c | 308 | %attr(755,root,root) /etc/profile.d/gnupg-agent.sh |
f197b41f | 309 | |
310 | %files -n gnupg-agent-xinitrc | |
311 | %defattr(644,root,root,755) | |
312 | %attr(755,root,root) /etc/X11/xinit/xinitrc.d/gnupg-agent.sh | |
74217b8a JB |
313 | |
314 | %if %{with dirmngr} | |
315 | %files -n dirmngr | |
316 | %defattr(644,root,root,755) | |
317 | %attr(755,root,root) %{_bindir}/dirmngr | |
318 | %attr(755,root,root) %{_bindir}/dirmngr-client | |
319 | %attr(755,root,root) %{pkglibexecdir}/dirmngr_ldap | |
320 | %{_mandir}/man1/dirmngr-client.1* | |
321 | %{_mandir}/man8/dirmngr.8* | |
322 | %endif |