Пакет unison: Specfile

Name: unison
Version: 2.27.157
Release: alt1

Summary: File-synchronization tool for Unix and Windows
License: GPLv2
Url: http://www.cis.upenn.edu/~bcpierce/unison/
Group: File tools
Packager: Vladimir Scherbaev <vladimir at altlinux.org>

Source0: %name-%version.tar.gz
Source1: unison.png
Source2: %name-%version-manual.pdf
Patch1: Makefile.OCaml.patch
Patch2: %name-2.27.157-alt-makefile.patch

# Automatically added by buildreq on Tue Jul 28 2009
BuildRequires: lablgtk2 desktop-file-utils

%description
Unison is a file-synchronization tool for Unix and Windows. It allows
two replicas of a collection of files and directories to be stored on
different hosts (or different disks on the same host), modified
separately, and then brought up to date by propagating the changes in
each replica to the other. Unlike simple mirroring or backup
utilities, Unison can deal with updates to both replicas of a
distributed directory structure. Updates that do not conflict are
propagated automatically.  Conflicting updates are detected and
displayed. Unison can synchronize either locally (between volumes
mounted on the same computer) or remotely,between any pair of machines
connected to the internet, communicating over either a direct socket
link or tunneling over an rsh or an encrypted ssh connection. It is
careful with network bandwidth, and runs well over slow links such as
PPP connections. Unison is available for both Windows (95/98/NT/2K)
and Unix (Linux, Solaris). Moreover, Unison works across platforms,
allowing you to synchronize a Windows laptop with a Unix server, for
example.

%prep
%setup -q
%patch1 -p0
%patch2

%build
%make THREADS=true UISTYLE=gtk2

%install
rm -rf %buildroot
mkdir -p %buildroot%_bindir
mkdir -p %buildroot%_datadir/pixmaps
cp -f %name %buildroot%_bindir/%name
cp -f %SOURCE1 %buildroot%_datadir/pixmaps/unison.png
%__install -pD -m644 %SOURCE1 %buildroot%_liconsdir/%name.png
%__install -pD -m644 %SOURCE2 %buildroot%_defaultdocdir/%name-%version-manual.pdf

cat > unison.desktop <<EOF
[Desktop Entry]
Type=Application
Exec=unison
Name=Unison File Synchronizer
GenericName=File Synchronizer
Comment=Multi-master File synchronization tool
Terminal=false
Icon=unison
Encoding=UTF-8
StartupNotify=true
EOF

desktop-file-install  \
    --add-category Application \
    --add-category Utility \
    --dir %buildroot%_datadir/applications \
    unison.desktop


%files
##defattr(0644,root,root,0755)
%doc CONTRIB COPYING INSTALL INSTALL.gtk2 NEWS README ROADMAP.txt TODO.txt BUGS.txt
%_defaultdocdir/*
%_bindir/*
%_datadir/applications/%name.desktop
%_datadir/pixmaps/*
%_liconsdir/*
 
%changelog
* Tue Jul 28 2009 Vladimir Scherbaev <vladimir@altlinux.org> 2.27.157-alt1
- New version