Sophie

Sophie

distrib > Mandriva > 10.0-com > i586 > by-pkgid > a1e43079d33341d7b7995743d0e73459 > files > 3

putty-0.54-0.20040216.3mdk.src.rpm

%define name		putty
%define version		0.54
%define rel		3mdk
%define snapshot	2004-02-16
%define release 0.%(echo %{snapshot} | sed 's|-||g').%{rel}

%define title   Putty
%define summary Free SSH, Telnet and Rlogin client

Summary:		%summary
Name:			%name
Version:		%version
Release:		%release
Epoch:			1
License:		MIT
Group:			Networking/Remote access
URL:			http://www.tartarus.org/~simon/putty-unix/
Source0:		%name-%version-%snapshot.tar.bz2
Source1:		%name-icons.tar.bz2
BuildRoot:		%_tmppath/%name-buildroot
Buildrequires:		gtk+-devel

%description
This is the Unix port of the popular Windows ssh client, PuTTY. It
supports flexible terminal setup, mid-session reconfiguration using
Ctrl-rightclick, multiple X11 authentication protocols, and various
other interesting things not provided by ssh in an xterm.

%prep
%setup -q -n %name-%version-%snapshot
%setup -q -T -D -a1 -n %name-%version-%snapshot

%build
cd unix && %make -f Makefile.gtk VER="-DSNAPSHOT=%{snapshot}" \
CC="%{__cc}" CFLAGS="%{optflags} `gtk-config --cflags` -I. -I.. -I../charset"

# temporary man pages
echo ".so putty.1" > pscp.1
echo ".so putty.1" > psftp.1

%install
rm -rf %buildroot

# preparing directories
%__mkdir_p %{buildroot}%{_bindir}
%__mkdir_p %{buildroot}%{_mandir}/man1

(cd unix && %__make -f Makefile.gtk install DESTDIR=%buildroot \
prefix=%{_prefix} mandir=%{_mandir})

# Menu
mkdir -p %buildroot/%_menudir
cat > %buildroot/%_menudir/%name << EOF
?package(%name): \
command="%_bindir/%name" \
needs="X11" \
icon="%name.png" \
section="Internet/Remote access" \
title="%title" \
longtitle="%summary"
EOF

# icon
# Use {curly braces} here to protect the variable name.
# ie: Is name48.png %{name}48.png or %{name48}.png?
%__install -D -m 644 %{name}48.png %buildroot/%_liconsdir/%name.png
%__install -D -m 644 %{name}32.png %buildroot/%_iconsdir/%name.png
%__install -D -m 644 %{name}16.png %buildroot/%_miconsdir/%name.png

%post
%update_menus

%postun
%clean_menus

%clean
rm -rf %buildroot

%files
%defattr(-,root,root)
%doc LICENCE README README.txt
%_bindir/*
%defattr(0644,root,root,0755)
%_mandir/man1/*
%_menudir/*
%_miconsdir/*
%_iconsdir/*
%_liconsdir/*

%changelog
* Mon Feb 16 2004 David Walluck <walluck@linux-mandrake.com> 1:0.54-0.20040216.3mdk
- fix changelog entries

* Sun Feb 15 2004 David Walluck <walluck@linux-mandrake.com> 1:0.54-0.20040216.2mdk
- bump epoch to fix improper version tag in the 0.53b release

* Sun Feb 15 2004 David Walluck <walluck@linux-mandrake.com> 0:0.54-0.20040216.1mdk
- 0.54 (20040216)

* Thu Sep 18 2003 Laurent Culioli <laurent@pschit.net> 0.53b-0.cvs.20030917.2mdk
- fix menu
- drop requires

* Wed Sep 17 2003 Tibor Pittich <Tibor.Pittich@phuture.sk> 0.53b-0.cvs.20030917.1mdk
- initial cooker inport of this famous ssh/telnet client