Blame SPECS/pinentry.spec

d1ad85
d1ad85
%if 0%{?fedora} > 8 || 0%{?rhel} > 5
d1ad85
%define _enable_pinentry_qt4 --enable-pinentry-qt4
d1ad85
%define _enable_pinentry_qt --enable-pinentry-qt
d1ad85
%define qt_major 3
d1ad85
%define qt3 qt3
d1ad85
%else
d1ad85
%define qt3 qt
d1ad85
%define _enable_pinentry_qt --enable-pinentry-qt
d1ad85
%endif
d1ad85
d1ad85
%if 0%{?fedora} && 0%{?fedora} > 12
d1ad85
%define _enable_pinentry_qt4 --enable-pinentry-qt4
d1ad85
%define qt_major 4
d1ad85
%undefine _enable_pinentry_qt
d1ad85
%endif
d1ad85
d1ad85
Name:    pinentry
d1ad85
Version: 0.8.1
ff559a
Release: 17%{?dist}
d1ad85
Summary: Collection of simple PIN or passphrase entry dialogs
d1ad85
d1ad85
Group:   Applications/System
d1ad85
# qt & qt4 subpackage have different license, see subpackage definitions
d1ad85
License: GPLv2+
d1ad85
URL:     http://www.gnupg.org/aegypten/
d1ad85
Source0: ftp://ftp.gnupg.org/gcrypt/pinentry/%{name}-%{version}.tar.gz
d1ad85
Source1: ftp://ftp.gnupg.org/gcrypt/pinentry/%{name}-%{version}.tar.gz.sig
d1ad85
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
d1ad85
d1ad85
# borrowed from opensuse
d1ad85
Source10: pinentry-wrapper
d1ad85
d1ad85
## Patches not yet in SVN
d1ad85
Patch53: 0001-Fix-qt4-pinentry-window-created-in-the-background.patch
d1ad85
8461b8
## Backported patches
8461b8
Patch200: 0001-Add-wide-char-support-to-pinentry-curses.patch
ff559a
Patch201: 0001-Check-if-we-are-on-tty-before-initializing-curses.patch
8461b8
8461b8
BuildRequires: gettext-devel
8461b8
BuildRequires: autoconf, automake
d1ad85
BuildRequires: gtk2-devel
d1ad85
BuildRequires: libcap-devel
d1ad85
BuildRequires: ncurses-devel
d1ad85
%if 0%{?_enable_pinentry_qt:1}
d1ad85
BuildRequires: %{qt3}-devel
d1ad85
%endif
d1ad85
%if 0%{?_enable_pinentry_qt4:1}
d1ad85
BuildRequires: qt4-devel
d1ad85
%endif
d1ad85
d1ad85
Requires(pre): %{_sbindir}/update-alternatives
d1ad85
Requires(post): /sbin/install-info
d1ad85
Requires(preun): /sbin/install-info
d1ad85
d1ad85
Provides: %{name}-curses = %{version}-%{release}
d1ad85
d1ad85
%description
d1ad85
Pinentry is a collection of simple PIN or passphrase entry dialogs which
d1ad85
utilize the Assuan protocol as described by the aegypten project; see
d1ad85
http://www.gnupg.org/aegypten/ for details.
d1ad85
This package contains the curses (text) based version of the PIN entry dialog.
d1ad85
d1ad85
%package gtk
d1ad85
Summary: Passphrase/PIN entry dialog based on GTK+
d1ad85
Group:   Applications/System
d1ad85
Requires: %{name} = %{version}-%{release}
d1ad85
Provides: %{name}-gui = %{version}-%{release}
d1ad85
%description gtk
d1ad85
Pinentry is a collection of simple PIN or passphrase entry dialogs which
d1ad85
utilize the Assuan protocol as described by the aegypten project; see
d1ad85
http://www.gnupg.org/aegypten/ for details.
d1ad85
This package contains the GTK GUI based version of the PIN entry dialog.
d1ad85
d1ad85
%package qt
d1ad85
Summary: Passphrase/PIN entry dialog based on Qt%{?qt_major}
d1ad85
Group:   Applications/System
d1ad85
# Original license for secq* files doesn't allow higher GPL versions to be used
d1ad85
License: GPLv2
d1ad85
Requires: %{name} = %{version}-%{release}
d1ad85
Provides: %{name}-gui = %{version}-%{release}
d1ad85
%if ! 0%{?_enable_pinentry_qt:1}
d1ad85
Obsoletes: %{name}-qt4 < 0.8.0-2
d1ad85
Provides:  %{name}-qt4 = %{version}-%{release}
d1ad85
%endif
d1ad85
%description qt
d1ad85
Pinentry is a collection of simple PIN or passphrase entry dialogs which
d1ad85
utilize the Assuan protocol as described by the aegypten project; see
d1ad85
http://www.gnupg.org/aegypten/ for details.
d1ad85
This package contains the Qt%{?qt_major} GUI based version of the PIN entry dialog.
d1ad85
d1ad85
%package qt4
d1ad85
Summary: Passphrase/PIN entry dialog based on Qt4
d1ad85
Group:   Applications/System
d1ad85
# original code for secstring.cpp doesn't allow GPL versions higher than 3 to be
d1ad85
# used
d1ad85
License: GPLv2 or GPLv3
d1ad85
Requires: %{name} = %{version}-%{release}
d1ad85
Provides: %{name}-gui = %{version}-%{release}
d1ad85
%description qt4
d1ad85
Pinentry is a collection of simple PIN or passphrase entry dialogs which
d1ad85
utilize the Assuan protocol as described by the aegypten project; see
d1ad85
http://www.gnupg.org/aegypten/ for details.
d1ad85
This package contains the Qt4 GUI based version of the PIN entry dialog.
d1ad85
Support for Qt4 is new, and a bit experimental.
d1ad85
d1ad85
d1ad85
%prep
d1ad85
%setup -q
d1ad85
d1ad85
%patch53 -p1 -b .rhbug_589532
8461b8
%patch200 -p1
ff559a
%patch201 -p1
8461b8
8461b8
# patch200 changes configure.ac so we need to regenerate
8461b8
./autogen.sh
d1ad85
d1ad85
# hack around auto* madness, lack of proper support for moc
d1ad85
%if %{?_enable_pinentry_qt4:1}
d1ad85
pushd qt4
d1ad85
moc-qt4 pinentrydialog.h > pinentrydialog.moc
d1ad85
moc-qt4 qsecurelineedit.h > qsecurelineedit.moc
d1ad85
popd
d1ad85
%endif
d1ad85
d1ad85
%build
d1ad85
%if 0%{?_enable_pinentry_qt:1}
d1ad85
unset QTDIR || : ; . /etc/profile.d/qt.sh
d1ad85
%endif
d1ad85
d1ad85
%configure \
d1ad85
  --disable-rpath \
d1ad85
  --disable-dependency-tracking \
d1ad85
  --disable-pinentry-gtk \
d1ad85
  --without-libcap \
d1ad85
  %{?_enable_pinentry_qt} %{!?_enable_pinentry_qt:--disable-pinentry-qt} \
d1ad85
  %{?_enable_pinentry_qt4} %{!?_enable_pinentry_qt4:--disable-pinentry-qt4}
d1ad85
d1ad85
make %{?_smp_mflags}
d1ad85
d1ad85
d1ad85
%install
d1ad85
rm -rf $RPM_BUILD_ROOT
d1ad85
d1ad85
make install DESTDIR=$RPM_BUILD_ROOT
d1ad85
d1ad85
# Backwards compatibility
d1ad85
ln -s pinentry-gtk-2 $RPM_BUILD_ROOT%{_bindir}/pinentry-gtk
d1ad85
%if ! 0%{?_enable_pinentry_qt:1}
d1ad85
ln -s pinentry-qt4 $RPM_BUILD_ROOT%{_bindir}/pinentry-qt
d1ad85
%endif
d1ad85
d1ad85
install -p -m755 -D %{SOURCE10} $RPM_BUILD_ROOT%{_bindir}/pinentry
d1ad85
d1ad85
# unpackaged files
d1ad85
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
d1ad85
d1ad85
d1ad85
%clean
d1ad85
rm -rf $RPM_BUILD_ROOT
d1ad85
d1ad85
d1ad85
# alternatives dropped at 0.7.6-3 (use %%trigger instead?)
d1ad85
%pre
d1ad85
%{_sbindir}/update-alternatives --remove pinentry %{_bindir}/pinentry-curses ||:
d1ad85
%{_sbindir}/update-alternatives --remove pinentry %{_bindir}/pinentry-gtk ||:
d1ad85
%{_sbindir}/update-alternatives --remove pinentry %{_bindir}/pinentry-qt ||:
d1ad85
d1ad85
%post
d1ad85
if [ -f %{_infodir}/pinentry.info* ]; then
d1ad85
/sbin/install-info %{_infodir}/pinentry.info %{_infodir}/dir ||:
d1ad85
fi
d1ad85
d1ad85
%preun
d1ad85
if [ $1 -eq 0 -a -f %{_infodir}/pinentry.info* ] ; then
d1ad85
  /sbin/install-info --delete %{_infodir}/pinentry.info %{_infodir}/dir ||:
d1ad85
fi
d1ad85
d1ad85
d1ad85
%files
d1ad85
%defattr(-,root,root,-)
d1ad85
%doc AUTHORS ChangeLog COPYING NEWS README THANKS TODO
d1ad85
%{_bindir}/pinentry-curses
d1ad85
%{_bindir}/pinentry
d1ad85
%{_infodir}/pinentry.info*
d1ad85
d1ad85
%files gtk
d1ad85
%defattr(-,root,root,-)
d1ad85
%{_bindir}/pinentry-gtk
d1ad85
%{_bindir}/pinentry-gtk-2
d1ad85
d1ad85
%files qt
d1ad85
%defattr(-,root,root,-)
d1ad85
%{_bindir}/pinentry-qt
d1ad85
%if ! 0%{?_enable_pinentry_qt:1}
d1ad85
%{_bindir}/pinentry-qt4
d1ad85
%else
d1ad85
d1ad85
%if 0%{?_enable_pinentry_qt4:1}
d1ad85
%files qt4
d1ad85
%defattr(-,root,root,-)
d1ad85
%{_bindir}/pinentry-qt4
d1ad85
%endif
d1ad85
%endif
d1ad85
d1ad85
d1ad85
%changelog
ff559a
* Thu Mar 17 2016 Boris Ranto <branto@redhat.com> - 0.8.1-17
ff559a
- actually apply the previous patch in the spec file
ff559a
- resolves: rhbz#1058972
ff559a
ff559a
* Fri Feb 19 2016 Boris Ranto <branto@redhat.com> - 0.8.1-16
ff559a
- curses: detect non-tty environment and exit gracefully
ff559a
- resolves: rhbz#1058972
ff559a
ff559a
* Fri Feb 19 2016 Boris Ranto <branto@redhat.com> - 0.8.1-15
ff559a
- rewrite the pinentry-wrapper shell script to better handle corner cases
ff559a
- resolves: rhbz#1231229
ff559a
8461b8
* Thu Jan 30 2014 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.1-14
8461b8
- Add wide-char support to pinentry-curses
8461b8
- Resolves: rhbz#1059729
8461b8
8461b8
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 0.8.1-13
8461b8
- Mass rebuild 2014-01-24
8461b8
8461b8
* Wed Jan 15 2014 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.1-12
8461b8
- Provide final fallback to pinetry-curses
8461b8
- Resolves: #rhbz1002599
8461b8
8461b8
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 0.8.1-11
8461b8
- Mass rebuild 2013-12-27
8461b8
d1ad85
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.1-10
d1ad85
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
d1ad85
d1ad85
* Wed Nov 14 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.1-9
d1ad85
- Fix macros expansions so that conditionals work
d1ad85
d1ad85
* Mon Nov 12 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.1-8
d1ad85
- Fix up licenses for qt and qt4 subpackages (#875875)
d1ad85
d1ad85
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.1-7
d1ad85
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
d1ad85
d1ad85
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.1-6
d1ad85
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
d1ad85
d1ad85
* Mon Nov 14 2011 Adam Jackson <ajax@redhat.com> 0.8.1-5
d1ad85
- Rebuild for new libpng
d1ad85
d1ad85
* Tue Jul 26 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.1-4
d1ad85
- Improve wrapper to fallback to curses even with DISPLAY set (#622077)
d1ad85
d1ad85
* Fri Feb 18 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.1-3
d1ad85
- Fix pinentry-curses running as root by disabling capabilities (#677670)
d1ad85
d1ad85
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.1-2
d1ad85
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
d1ad85
d1ad85
* Tue Feb  1 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.1-1
d1ad85
- Updated to latest upstream version (0.8.1)
d1ad85
d1ad85
* Fri May  7 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.0-3
d1ad85
- Fix X11 even race with gtk (#589998)
d1ad85
- Fix qt4 problems with creating window in the background (#589532)
d1ad85
d1ad85
* Thu Apr 29 2010 Rex Dieter <rdieter@fedoraproject.org> - 0.8.0-2
d1ad85
- -qt: build as qt4 version, and drop qt3 support (f13+ only)
d1ad85
d1ad85
* Tue Apr 27 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.8.0-1
d1ad85
- pinentry-0.8.0
d1ad85
- pinentry-gtk keyboard grab fail results in SIGABRT (#585422)
d1ad85
d1ad85
* Sun Apr 18 2010 Rex Dieter <rdieter@fedoraproject.org> - 0.7.6-5
d1ad85
- pinentry-gtk -g segfaults on focus change (#520236)
d1ad85
ff559a
* Sun Sep 13 2009 Rex Dieter <rdieter@fedoraproject.org> - 0.7.6-4
d1ad85
- Errors installing with --excludedocs (#515925)
d1ad85
ff559a
* Sun Sep 13 2009 Rex Dieter <rdieter@fedoraproject.org> - 0.7.6-3
d1ad85
- drop alternatives, use app-wrapper instead (borrowed from opensuse)
d1ad85
- -qt4 experimental subpkg, -qt includes qt3 version again  (#523488)
d1ad85
d1ad85
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.6-2
d1ad85
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
d1ad85
d1ad85
* Mon Jun 22 2009 Rex Dieter <rdieter@fedoraproject.org> - 0.7.6-1
d1ad85
- pinentry-0.7.6
d1ad85
- -qt switched qt4 version, where applicable (f9+, rhel6+)
d1ad85
- fixup scriptlets
d1ad85
d1ad85
* Sat Apr 25 2009 Rex Dieter <rdieter@fedoraproject.org> - 0.7.5-1
d1ad85
- pinentry-0.7.5
d1ad85
d1ad85
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.4-6
d1ad85
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
d1ad85
d1ad85
* Tue Mar 25 2008 Rex Dieter <rdieter@fedoraproject.org> - 0.7.4-5
d1ad85
- pinentry failed massrebuild attempt for GCC 4.3 (#434400)
d1ad85
d1ad85
* Tue Mar 25 2008 Rex Dieter <rdieter@fedoraproject.org> - 0.7.4-4
d1ad85
- s/qt-devel/qt3-devel/ (f9+)
d1ad85
d1ad85
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 0.7.4-3
d1ad85
- Autorebuild for GCC 4.3
d1ad85
d1ad85
* Sun Feb 17 2008 Adam Tkac <atkac redhat com> - 0.7.4-2
d1ad85
- rebuild against new libcap
d1ad85
d1ad85
* Sun Dec 09 2007 Rex Dieter <rdieter[AT]fedoraproject.org> - 0.7.4-1
d1ad85
- pinentry-0.7.4
d1ad85
- BR: libcap-devel
d1ad85
d1ad85
* Sat Aug 25 2007 Rex Dieter <rdieter[AT]fedoraproject.org> - 0.7.3-2
d1ad85
- respin (BuildID)
d1ad85
d1ad85
* Sat Aug 11 2007 Rex Dieter <rdieter[AT]fedoraproject.org> - 0.7.3-1
d1ad85
- pinentry-0.7.3
d1ad85
- License: GPLv2+
d1ad85
d1ad85
* Thu May 10 2007 Rex Dieter <rdieter[AT]fedoraproject.org> - 0.7.2-15
d1ad85
- respin (for ppc64)
d1ad85
d1ad85
* Mon Dec 04 2006 Rex Dieter <rexdieter[AT]users.sf.net> - 0.7.2-14
d1ad85
- -14 respin (to help retire ATrpms pinentry pkg)
d1ad85
d1ad85
* Mon Aug 28 2006 Rex Dieter <rexdieter[AT]users.sf.net> - 0.7.2-3
d1ad85
- fc6 respin
d1ad85
d1ad85
* Wed Aug 09 2006 Rex Dieter <rexdieter[AT]users.sf.net> - 0.7.2-2
d1ad85
- fc6 respin
d1ad85
d1ad85
* Wed Mar 01 2006 Rex Dieter <rexdieter[AT]users.sf.net>
d1ad85
- fc5: gcc/glibc respin
d1ad85
d1ad85
* Tue Oct 18 2005 Ville Skyttä <ville.skytta at iki.fi> - 0.7.2-1
d1ad85
- 0.7.2, docs patch applied upstream.
d1ad85
- Switch to GTK2 in -gtk.
d1ad85
- Fine tune dependencies.
d1ad85
- Build with dependency tracking disabled.
d1ad85
- Clean up obsolete pre-FC2 support.
d1ad85
ff559a
* Thu Apr  7 2005 Michael Schwendt <mschwendt[AT]users.sf.net> - 0.7.1-4
d1ad85
- rebuilt
d1ad85
d1ad85
* Wed Jun 30 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:0.7.1-0.fdr.3
d1ad85
- BuildRequires qt-devel >= 3.2.
d1ad85
d1ad85
* Sat May 22 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:0.7.1-0.fdr.2
d1ad85
- Spec cleanups.
d1ad85
d1ad85
* Sat Apr 24 2004 Ville Skyttä <ville.skytta at iki.fi> - 0:0.7.1-0.fdr.1
d1ad85
- Update to 0.7.1.
d1ad85
d1ad85
* Fri Dec 26 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:0.7.0-0.fdr.1
d1ad85
- Update to 0.7.0.
d1ad85
- Split GTK+ and QT dialogs into subpackages.
d1ad85
d1ad85
* Thu Jul 10 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:0.6.9-0.fdr.1
d1ad85
- Update to 0.6.9.
d1ad85
- Smoother experience with --excludedocs.
d1ad85
- Don't change alternative priorities on upgrade.
d1ad85
d1ad85
* Sat Mar 22 2003 Ville Skyttä <ville.skytta at iki.fi> - 0:0.6.8-0.fdr.1
d1ad85
- Update to current Fedora guidelines.
d1ad85
ff559a
* Wed Feb 12 2003 Warren Togami <warren@togami.com> 0.6.8-1.fedora.3
d1ad85
- info/dir temporary workaround
d1ad85
d1ad85
* Sat Feb  8 2003 Ville Skyttä <ville.skytta at iki.fi> - 0.6.8-1.fedora.1
d1ad85
- First Fedora release.