File mcal.spec of Package mcal
#
# spec file for package mcal (Version 0.7)
#
# Copyright (c) 2006 SUSE LINUX Products GmbH, Nuernberg, Germany.
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
# Please submit bugfixes or comments via http://bugs.opensuse.org
#
# norootforbuild
Name: mcal
#!BuildIgnore: flex
BuildRequires: flex-old
Version: 0.7
Release: 125
%define dver 0.9
%define mver 0.3
Autoreqprov: on
Group: Productivity/Office/Organizers
License: GPL
URL: http://mcal.chek.com/
Summary: A Calendar based on Libmcal
Source0: http://download.sourceforge.net/libmcal/libmcal-%{version}.tar.gz
Source1: http://download.sourceforge.net/libmcal/mcaldrivers-%{dver}.tar.gz
Source2: http://download.sourceforge.net/libmcal/mcal-%{mver}.tar.gz
Patch0: libmcal-%{version}.diff
Patch1: mcaldrivers-%{dver}.diff
Patch2: mcal-%{mver}.diff
Patch3: libmcal-makefile.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
MCAL is a calendar based on libmcal. The MCAL library is very similar
to the C-client IMAP library. It offers a common and simple interface
for accessing calendars that can be stored in many different formats.
Both local and remote formats are supported.
Authors:
--------
Mark Musone <musone@chek.com>
Andrew Skalski <askalski@chek.com>
Jonathon Jude <jonathan.jude@telmat.fr>
Bob Allen <allenb@home-networking.org>
%package -n libmcal
License: LGPL, Other License(s), see package
Autoreqprov: on
Group: System/Libraries
Summary: Modular Calendar Access Library
%description -n libmcal
The MCAL library is very similar to the c-client IMAP library. It
offers a common, simple interface for accessing calendars that can be
stored in many different formats, both local and remote formats are
supported.
Authors:
--------
Mark Musone <musone@chek.com>
Andrew Skalski <askalski@chek.com>
Jonathon Jude <jonathan.jude@telmat.fr>
Bob Allen <allenb@home-networking.org>
%prep
%setup -q -n libmcal -a1 -a2
%patch0
%patch3
cd mcal-drivers
%patch1
cd ../mcal
%patch2
%build
export CFLAGS="$RPM_OPT_FLAGS -fPIC -Wall"
mv mcal-drivers/* .
(cd mstore;make CFLAGS="$CFLAGS")
(cd icap;make CFLAGS="$CFLAGS")
./configure \
--libdir=%{_libdir} \
--includedir=%{_includedir} \
--with-mstore \
--with-icap
make CFLAGS="$CFLAGS"
(cd mcal; make CFLAGS="$CFLAGS")
%install
make DESTDIR=$RPM_BUILD_ROOT install
install -d $RPM_BUILD_ROOT%{_includedir}/mcal/{icap,mstore}
install -d $RPM_BUILD_ROOT%{_bindir}
install -m 644 icap/icap.h $RPM_BUILD_ROOT%{_includedir}/mcal/icap/
install -m 644 mstore/mstore.h $RPM_BUILD_ROOT%{_includedir}/mcal/mstore/
install -m 755 mcal/mcal $RPM_BUILD_ROOT%{_bindir}
install -d -m 1777 $RPM_BUILD_ROOT/var/calendar
mv $RPM_BUILD_ROOT%{_libdir}/libmcal.so $RPM_BUILD_ROOT%{_libdir}/libmcal.so.%{version}
ln -sf libmcal.so.%{version} $RPM_BUILD_ROOT%{_libdir}/libmcal.so
chmod 755 $RPM_BUILD_ROOT%{_libdir}/*.so*
%post -n libmcal
%{run_ldconfig}
%postun -n libmcal
%{run_ldconfig}
%clean
rm -rf $RPM_BUILD_ROOT
%files -n libmcal
%defattr(-,root,root)
%doc CHANGELOG FAQ-MCAL FEATURE-IMPLEMENTATION FUNCTION-REF.html HOW-TO-MCAL
%doc LICENSE README
%{_libdir}/lib*
%{_includedir}/*
%files -n mcal
%defattr(-,root,root)
%doc mcal/LICENSE
%{_bindir}/*
%changelog -n mcal
* Wed Jan 25 2006 - mls@suse.de
- converted neededforbuild to BuildRequires
* Sun Jan 15 2006 - schwab@suse.de
- Don't strip binaries.
* Wed Dec 21 2005 - ro@suse.de
- build with flex-old for the moment
* Sun Apr 10 2005 - coolo@suse.de
- fix build with gcc4 (more of a work around for the broken C)
* Mon Mar 01 2004 - hmacht@suse.de
- building as nonroot user
- added patch libmcal-makefile.patch for fixing permissions
* Thu Jul 31 2003 - mjancar@suse.cz
- use %%run_ldconfig
* Thu Jul 24 2003 - mjancar@suse.cz
- update libmcal to 0.7
- update mcaldrivers to 0.9
* Tue May 14 2002 - ro@suse.de
- fix build on lib64 platforms
* Mon Aug 27 2001 - grimmer@suse.de
- fixed License tag for libmcal (libmcal is LGPL, while
the mcal package is GPLed) - PDB entry has been fixed as well.
* Tue Jan 23 2001 - nadvornik@suse.cz
- fixed usage of -fPIC
* Mon Jun 26 2000 - ro@suse.de
- added tester.o to libobjects
* Fri Jun 23 2000 - rolf@suse.de
- compile and install libmcal.so
* Tue Jun 20 2000 - nadvornik@suse.cz
- new packages libmcal and mcal