Package pinentry: Specfile

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
%def_disable libcap
%def_enable qt5
%def_disable qt4
%def_disable fltk

Name: pinentry
Version: 1.1.0
Release: alt6

Summary: Simple PIN or passphrase entry dialog
License: GPLv2+
Group: File tools
Url: http://gnupg.org/related_software/pinentry/

Requires: %name-common = %version-%release
%{?_enable_qt4:Requires: %name-qt4 = %version-%release}
Requires: %name-gtk2 = %version-%release

# ftp://ftp.gnupg.org/gcrypt/pinentry/%name-%version.tar.gz
Source: %name-%version.tar
Source1: pinentry-wrapper
# ALT
Patch10: alt-mask-xprop.patch

%if_enabled qt5
BuildRequires: qt5-base-devel
%endif
%if_enabled libfltk-devel
BuildRequires: libfltk-devel
%endif
%if_enabled qt4
BuildRequires: libqt4-devel
%endif
%if_enabled libcap
BuildRequires: libcap-devel
%endif
BuildRequires: gcc-c++ libgtk+2-devel libncursesw-devel
BuildRequires: libsecret-devel gcr-libs-devel libassuan-devel
BuildRequires: texinfo

%description
This is simple PIN or passphrase entry dialog which utilize
the Assuan protocol as described by the aegypten project.

%package common
Group: %group
Summary: %summary
Provides: %name = %version-%release
Provides: %name-terminal = %version-%release
Provides: %name-console = %version-%release
Provides: %name-tty = %EVR
Provides: %name-curses = %EVR
Obsoletes: %name-curses < %EVR
Conflicts: pinentry < 0.7.2 pinentry-curses < 0.7.2
Conflicts: pinentry-qt < 0.7.2 pinentry-gtk < 0.7.2

%package gtk2
Group: %group
Summary: %summary
Requires: %name-common = %EVR
Requires: xprop
Provides: %name = %version-%release
Provides: %name-x11 = %version-%release
Provides: pinentry-gtk = %EVR
Obsoletes: pinentry-gtk < %EVR

%package gnome3
Group: %group
Summary: %summary
Requires: %name-common = %EVR
Requires: xprop
Provides: %name = %version-%release
Provides: %name-x11 = %version-%release

%package qt5
Group: %group
Summary: %summary
Requires: xprop
Requires: %name-common = %EVR
Provides: %name = %version-%release
Provides: %name-x11 = %version-%release
Provides: pinentry-qt = %EVR
Obsoletes: pinentry-qt < %EVR

%package qt4
Group: %group
Summary: %summary
Requires: xprop
Requires: %name-common = %EVR
Provides: %name = %version-%release
Provides: %name-x11 = %version-%release

%description gtk2
This is simple PIN or passphrase entry dialog which utilize
the Assuan protocol as described by the aegypten project.
%description gnome3
This is simple PIN or passphrase entry dialog which utilize
the Assuan protocol as described by the aegypten project.
%description qt5
This is simple PIN or passphrase entry dialog which utilize
the Assuan protocol as described by the aegypten project.
%description qt4
This is simple PIN or passphrase entry dialog which utilize
the Assuan protocol as described by the aegypten project.
%description common
This package contains common files and documentation for %name.

%prep
%setup -T -c
tar xf %SOURCE0
mv %name-%version gui

%{?_enable_qt4:cp -a gui gui-qt4}
%{?_enable_qt5:cp -a gui gui-qt5}
cp -a gui tui

install -pm644 %SOURCE1 pinentry-wrapper
%patch10 -p0

for d in tui gui \
             %{?_enable_qt4:gui-qt4} \
             %{?_enable_qt5:gui-qt5} ; do
    pushd $d
    %autoreconf
    popd
done

%build
%add_optflags -std=gnu++11

pushd tui
%configure \
    --disable-rpath \
    --enable-pinentry-curses \
    --enable-pinentry-tty \
    --disable-pinentry-gtk2 \
    --disable-pinentry-fltk \
    --disable-pinentry-gnome3 \
    --disable-pinentry-qt \
    --disable-libsecret \
    %{?_enable_libcap:--with-libcap}%{!?_enable_libcap:--without-libcap} \
    #
%make_build
popd

pushd gui
%configure \
    --disable-rpath \
    --disable-pinentry-curses \
    --disable-pinentry-tty \
    --enable-pinentry-gtk2 \
    %{?_enable_fltk:--enable-pinentry-fltk} \
    --enable-pinentry-gnome3 \
    --disable-pinentry-qt \
    --disable-pinentry-qt5 \
    --disable-pinentry-qt-clipboard \
    --enable-libsecret \
    %{?_enable_libcap:--with-libcap}%{!?_enable_libcap:--without-libcap} \
    #
%make_build
popd

%if_enabled qt4
pushd gui-qt4
%configure \
    --disable-rpath \
    --disable-pinentry-curses \
    --disable-pinentry-tty \
    --disable-pinentry-gtk2 \
    --disable-pinentry-fltk \
    --disable-pinentry-gnome3 \
    --enable-pinentry-qt \
    --disable-pinentry-qt5 \
    --enable-pinentry-qt-clipboard \
    --enable-libsecret \
    %{?_enable_libcap:--with-libcap}%{!?_enable_libcap:--without-libcap} \
    #
%make_build
popd
%endif

%if_enabled qt5
pushd gui-qt5
%configure \
    --disable-rpath \
    --disable-pinentry-curses \
    --disable-pinentry-tty \
    --disable-pinentry-gtk2 \
    --disable-pinentry-fltk \
    --disable-pinentry-gnome3 \
    --enable-pinentry-qt \
    --enable-pinentry-qt5 \
    --enable-pinentry-qt-clipboard \
    --enable-libsecret \
    %{?_enable_libcap:--with-libcap}%{!?_enable_libcap:--without-libcap} \
    #
%make_build
popd
%endif

%install
pushd tui
%makeinstall_std
popd
rm %buildroot%_bindir/%name

pushd gui
%makeinstall_std
popd
rm %buildroot%_bindir/%name

%if_enabled qt4
pushd gui-qt4
%makeinstall_std
popd
mv %buildroot/%_bindir/%name-qt %buildroot/%_bindir/%name-qt4
%endif

%if_enabled qt5
pushd gui-qt5
%makeinstall_std
popd
mv %buildroot/%_bindir/%name-qt %buildroot/%_bindir/%name-qt5
%endif

ln -s %name-gtk-2 %buildroot/%_bindir/%name-gtk
%{?_enable_qt5:ln -s %name-qt5 %buildroot/%_bindir/%name-qt}

install -pDm755 pinentry-wrapper %buildroot/%_bindir/pinentry

%files gtk2
%_bindir/%name-gtk
%_bindir/%name-gtk-2

%if_enabled qt4
%files qt4
%_bindir/%name-qt4
%endif

%if_enabled qt5
%files qt5
%_bindir/%name-qt5
%_bindir/%name-qt
%endif

%files gnome3
%_bindir/%name-gnome3

%files common
%doc gui/AUTHORS gui/NEWS gui/README gui/THANKS
%_bindir/%name
%_bindir/%name-curses
%_bindir/%name-tty
%_infodir/*.info*

%changelog
* Mon Jun 28 2021 Sergey V Turchin <zerg@altlinux.org> 1.1.0-alt6
- disable qt4 UI

* Mon Jul 29 2019 Nikita Ermakov <arei@altlinux.org> 1.1.0-alt5
- NMU: Clean up spec file.
  + Make qt4 optional and disable it for riscv64 architecture.
  + Make qt5 option actually work.
  + Remove obsolete libtqt3-devel (trinity-tqt3 package was removed).

* Sun Jun 23 2019 Igor Vlasenko <viy@altlinux.ru> 1.1.0-alt4
- NMU: remove rpm-build-ubt from BR:

* Mon Apr 01 2019 Sergey V Turchin <zerg@altlinux.org> 1.1.0-alt3
- fix spec cleanup

* Sat Mar 30 2019 Michael Shigorin <mike@altlinux.org> 1.1.0-alt2
- minor spec cleanup
  + dropped unused macros
  + dropped %%ubt

* Thu Apr 19 2018 Sergey V Turchin <zerg@altlinux.org> 1.1.0-alt1%ubt
- new version

* Thu Dec 07 2017 Sergey V Turchin <zerg@altlinux.org> 1.0.0-alt2%ubt
- fix detect pinentry-qt5 (ALT#34290)

* Mon Apr 17 2017 Sergey V Turchin <zerg@altlinux.org> 1.0.0-alt1%ubt
- new version

* Fri Apr 29 2016 Sergey V Turchin <zerg@altlinux.org> 0.9.7-alt2
- build pinentry-qt5

* Tue Dec 08 2015 Sergey V Turchin <zerg@altlinux.org> 0.9.7-alt1
- new version

* Tue Dec 08 2015 Sergey V Turchin <zerg@altlinux.org> 0.9.6-alt2
- fix build requires

* Mon Oct 26 2015 Sergey V Turchin <zerg@altlinux.org> 0.9.6-alt1
- new version

* Tue Jun 23 2015 Sergey V Turchin <zerg@altlinux.org> 0.9.4-alt1
- new version

* Tue Dec 02 2014 Sergey V Turchin <zerg@altlinux.org> 0.9.0-alt2
- don't require xprop for console subpackage

* Tue Nov 25 2014 Sergey V Turchin <zerg@altlinux.org> 0.9.0-alt1
- new version
- using wrapper script instead of alternatives

* Fri Jun 20 2014 Sergey V Turchin <zerg@altlinux.org> 0.8.3-alt2
- rename pinentry-qt to pinentry-qt4

* Thu Oct 31 2013 Sergey V Turchin <zerg@altlinux.org> 0.8.3-alt0.M70P.1
- built for M70P

* Fri Oct 25 2013 Sergey V Turchin <zerg@altlinux.org> 0.8.3-alt1
- new version

* Thu Dec 20 2012 Alexander Plehanov <tonik@altlinux.org> 0.8.2-alt2
- fix text encoding

* Tue Dec 04 2012 Sergey V Turchin <zerg@altlinux.org> 0.8.2-alt1
- new version

* Mon Jul 04 2011 Sergey V Turchin <zerg@altlinux.org> 0.8.1-alt1
- new version

* Mon Jun 07 2010 Sergey V Turchin <zerg@altlinux.org> 0.8.0-alt2
- add fixes from FC

* Wed Jun 02 2010 Sergey V Turchin <zerg@altlinux.org> 0.8.0-alt1
- new version

* Sun Feb 07 2010 Dmitry V. Levin <ldv@altlinux.org> 0.7.6-alt3
- Rebuilt with libassuan0.so.0.
- Cleaned up specfile.

* Wed Feb 03 2010 Sergey V Turchin <zerg@altlinux.org> 0.7.6-alt2
- rebuilt with static assuan

* Mon Jul 06 2009 Sergey V Turchin <zerg@altlinux.org> 0.7.6-alt1
- new version

* Tue Dec 02 2008 Sergey V Turchin <zerg at altlinux dot org> 0.7.5-alt3
- built with libcap
- remove deprecated macroses from specfile

* Tue Sep 16 2008 Sergey V Turchin <zerg at altlinux dot org> 0.7.5-alt2
- built without libcap

* Tue May 13 2008 Sergey V Turchin <zerg at altlinux dot org> 0.7.5-alt1
- new version
- update build requires
- don't use internal g_malloc if defined

* Mon Dec 24 2007 Sergey V Turchin <zerg at altlinux dot org> 0.7.4-alt2
- fix requires

* Wed Dec 19 2007 Sergey V Turchin <zerg at altlinux dot org> 0.7.4-alt1
- new version

* Tue Jul 10 2007 Sergey V Turchin <zerg at altlinux dot org> 0.7.3-alt1
- new version

* Tue May 23 2006 Sergey V Turchin <zerg at altlinux dot org> 0.7.2-alt2
- rebuilt with new gcc

* Thu Jun 23 2005 Sergey V Turchin <zerg at altlinux dot org> 0.7.2-alt1
- new version; built with gtk-2

* Thu Jan 20 2005 Sergey V Turchin <zerg at altlinux dot org> 0.7.1-alt2
- rebuild with gcc3.4

* Mon Oct 11 2004 Sergey V Turchin <zerg at altlinux dot org> 0.7.1-alt1
- new version

* Tue Apr 06 2004 Sergey V Turchin <zerg at altlinux dot org> 0.7.0-alt2
- build all qt/gtk/curses
- update BuildRequires
- patch from PLD for build with system libassuan

* Thu Feb 12 2004 Sergey V Turchin <zerg at altlinux dot org> 0.7.0-alt1
- new version

* Fri Sep 05 2003 Sergey V Turchin <zerg at altlinux dot org> 0.6.9-alt3
- rebuild with Qt and with --enable-fallback-curses

* Wed May 07 2003 Sergey V Turchin <zerg at altlinux dot ru> 0.6.9-alt2
- fix requires
- fix update of alternatives

* Wed May 07 2003 Sergey V Turchin <zerg at altlinux dot ru> 0.6.9-alt1
- new version

* Wed Apr 09 2003 Stanislav Ievlev <inger@altlinux.ru> 0.6.6-alt3.1
- new alternatives config format

* Fri Mar 14 2003 Stanislav Ievlev <inger@altlinux.ru> 0.6.6-alt3
- PreReq fixes

* Thu Mar 13 2003 Stanislav Ievlev <inger@altlinux.ru> 0.6.6-alt2
- move to new alternatives scheme
- texinfo fix, added missing script to install info pages into info dir
- added trigger 'cause pervious scripts was proken

* Fri Feb 07 2003 Sergey V Turchin <zerg@altlinux.ru> 0.6.6-alt1
- build for ALT

* Wed Dec 11 2002 Laurent MONTEL <lmontel@mandrakesoft.com> 0.6.6-1mdk
- update spec file from Fabrice MARIE <fabrice-marie-sec@ifrance.com>

* Sat Oct 19 2002 Laurent MONTEL <lmontel@mandrakesoft.com> 0.6.5-1mdk
- Initial package