Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37593377
en ru br
ALT Linux repos
S:1.2.1-alt1
5.0: 0.7.5-alt3
4.1: 0.7.4-alt2
4.0: 0.7.4-alt2
3.0: 0.7.2-alt1

Group :: File tools
RPM: pinentry

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

%define qtdir %_qt3dir
%def_enable libcap

Name: pinentry
Version: 0.7.5
Release: alt3

Group: File tools
Summary: Simple PIN or passphrase entry dialog
URL: http://www.gnupg.org/
License: GPL

PreReq(post,preun): alternatives >= 0.2 info-install
Requires: %name-common = %version-%release

Requires: %name-qt = %version-%release
Requires: %name-gtk = %version-%release
Requires: %name-curses = %version-%release

Source0: %name-%version.tar.gz
Patch1: pinentry-0.7.2-system-assuan.patch
Patch2: pinentry-0.7.5-alt-no-internal-gmalloc.patch

# Automatically added by buildreq on Tue Apr 06 2004 (-bi)

#BuildRequires: XFree86-devel XFree86-libs fontconfig freetype2 gcc-c++ glib-devel gtk+-devel libalternatives-devel libassuan-devel libcap-devel libncurses-devel libqt3-devel libstdc++-devel libtinfo-devel

#for alternatives macros

BuildPreReq: libalternatives-devel
BuildRequires: xorg-x11-devel gcc-c++
BuildRequires: libassuan-devel libncurses-devel
BuildRequires: libqt3-devel libstdc++-devel libtinfo-devel
%if_enabled libcap
BuildRequires:  libcap-devel
%endif
#
BuildRequires: glib2-devel libgtk+2-devel
BuildRequires: libqt3-devel-cxx = %__gcc_version_base
# hack for apt in hasher
BuildRequires: libqt3 > 1 libqt3-devel > 1


%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
Conflicts: pinentry < 0.7.2 pinentry-curses < 0.7.2
Conflicts: pinentry-qt < 0.7.2 pinentry-gtk < 0.7.2

%package curses
Group: %group
Summary: %summary
Provides: %name-terminal = %version-%release
Provides: %name = %version-%release
Provides: %_bindir/%name
PreReq: alternatives >= 0.2 info-install
Requires: %name-common = %version-%release

%package gtk
Group: %group
Summary: %summary
Provides: %name = %version-%release
Provides: %name-x11 = %version-%release
Provides: %_bindir/%name
PreReq: alternatives >= 0.2 info-install
Requires: %name-common = %version-%release

%package qt
Group: %group
Summary: %summary
Provides: %name = %version-%release
Provides: %_bindir/%name
Obsoletes: %name <= %version-%release
Provides: %name-x11 = %version-%release
PreReq: alternatives >= 0.2 info-install
Requires: libqt3 >= %{get_version libqt3}
Requires: %name-common = %version-%release

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

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

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

%description common
Common files and documentation for %name

%prep
%setup -q
%patch1 -p1
%patch2 -p1
rm -f doc/*.info

%__libtoolize --copy --force
#%__aclocal
#%__automake
#%__autoconf
./autogen.sh

%build
export QTDIR=%qtdir

%configure \
   --with-x \
   --disable-rpath \
   --with-gnu-ld \
   --disable-pinentry-gtk \
   --enable-pinentry-gtk-2 \
   --enable-pinentry-curses \
%if_enabled libcap
   \
%else
   --without-libcap \
%endif
   --enable-pinentry-qt \
   --enable-fallback-curses

%make


%install
mkdir -p %buildroot/%_bindir
%make install DESTDIR=%buildroot
if [ -f %buildroot/%_bindir/%{name}-gtk-2 ]
then
   rm -f %buildroot/%_bindir/%{name}-gtk
   mv -f %buildroot/%_bindir/%{name}-gtk-2 %buildroot/%_bindir/%{name}-gtk
   ln -sf %_sysconfdir/sysconfig/system %buildroot/%_bindir/%{name}
fi

#made three alternatives entries

%__install -d %buildroot/%_altdir
WEIGHT=10
for i in curses gtk qt
do
cat >%buildroot/%_altdir/%name-$i<<EOF
%_bindir/%name %_bindir/%name-$i $WEIGHT
EOF
((WEIGHT+=10))
done

%__mkdir_p alt/
cat >alt/README <<__EOF__
see the documentation of %{name}-common package
__EOF__


%post common
%install_info %name.info
%preun common
%uninstall_info %name.info


%files curses
%_altdir/%name-curses
%_bindir/%name-curses

%files gtk
%_altdir/%name-gtk
%_bindir/%name-gtk

%files qt
%_altdir/%name-qt
%_bindir/%name-qt

%files common
%doc README TODO ChangeLog NEWS AUTHORS THANKS
%_infodir/*.info*
%ghost %_bindir/%name


%changelog

Full changelog you can see here

 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin