File pilot-mailsync.spec of Package pilot-mailsync

#
# spec file for package pilot-mailsync
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

# norootforbuild


Name:           pilot-mailsync
BuildRequires:  bison gnome-pilot-devel gtk2-devel openssl-devel pam-devel pilot-link-devel
Url:            http://wissrech.iam.uni-bonn.de/people/garcke/pms/
License:        Public Domain, Freeware
Group:          Hardware/Palm
AutoReqProv:    on
Version:        0.9.2
Release:        7.<RELEASE2>
Summary:        An e-mail Synchronization Program for Palm OS-based Organisers
Source:         %{name}-%{version}.tar.bz2
Patch:          %{name}-0.9.1.diff
Patch2:         %{name}-0.9.1-implicit.diff
Patch4:         %{name}-0.9.1-nostrip.patch
Patch5:         %{name}-0.9.1-warning.patch
Patch6:         pilot-mailsync-no-gtk1.patch
Patch7:         pilot-mailsync-no-gnome.h.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
An application to transfer outgoing mail from and deliver incoming mail
to a Palm OS device. Pilot-mailsync relies on the libraries installed
by pilot-link.

%package gnome-pilot
License:        Public Domain, Freeware
Summary:        GNOME Pilot Plug-in for e-mail Synchronization
Requires:       pilot-mailsync
# Has biarch problems:
# http://bugzilla.gnome.org/show_bug.cgi?id=302727
Conflicts:      pilot-mailsync-gnome-pilot-32bit

%description gnome-pilot
The plug-in for GNOME-pilot is a simple hack, GNOME-pilot simply calls
pilot-mailsync. You should set up your .pilotmailrc so that it works
the way you want it to with the executable pilot-mailsync. If that
works you can use the plug-in.

%package jpilot
License:        Public Domain, Freeware
Summary:        J-Pilot Plug-in for e-mail Synchronization
Requires:       pilot-mailsync
Requires:       jpilot

%description jpilot
The plug-in for J-Pilot is a simple hack, J-Pilot simply calls
pilot-mailsync. You should set up your .pilotmailrc so that it works
the way you want it to with the executable pilot-mailsync. If that
works you can use the plug-in.

%prep
%setup -q
%patch
%patch2
%patch4
%patch5
%patch6 -p1
%patch7 -p1
# Work-around biarch problems:
# http://bugzilla.gnome.org/show_bug.cgi?id=302727
sed -i s:/usr/lib:/usr/%{_lib}:g *.conduit

%build
autoreconf -fi
export EXTRABASECFLAGS="-fno-strict-aliasing -fPIC $RPM_OPT_FLAGS"
%configure
%__make
%configure --enable-gpilot
%__make
%configure --enable-jpilot
%__make
# This last configure is needed to enable all install rules for %install
%configure --enable-gpilot --enable-jpilot

%install
%makeinstall
# gnome-pilot
make gplugin_install
# jpilot
mkdir home
HOME=$PWD/home make jplugin_install
rm -f $PWD/home/.jpilot/plugins/*.*a
install -d %{buildroot}%{_libdir}/jpilot/plugins
mv $PWD/home/.jpilot/plugins/* %{buildroot}%{_libdir}/jpilot/plugins

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root)
%doc README docs/*
%{_bindir}/*

%files gnome-pilot
%defattr(-,root,root)
%{_libdir}/gnome-pilot/conduits/*.so
%{_datadir}/gnome-pilot/conduits/*.conduit

%files jpilot
%defattr(-,root,root)
%dir %{_libdir}/jpilot
%dir %{_libdir}/jpilot/plugins
%{_libdir}/jpilot/plugins/libmailsync.so

%changelog
openSUSE Build Service is sponsored by