base-specs/evince.spec
author dkenny
Mon, 14 Jul 2008 14:46:05 +0000
branchgnome-2-22
changeset 12467 6830bb7a5bbd
parent 12384 be3f033597e3
permissions -rw-r--r--
2008-07-14 Darren Kenny <[email protected]> * base-specs/evince.spec, patches/evince-03-static-enum.diff: Add patch to fix crash when using presentation mode (bug#6724495), and logged upstream bugzilla bug#542924.

#
# spec file for package evince
#
# Copyright (c) 2008 Sun Microsystems, Inc.
# This file and all modifications and additions to the pristine
# package are under the same license as the package itself.
#
# Owner: dkenny
#
%include l10n.inc
Name:         evince
License:      GPL
Group:        System/GUI/GNOME
# poppler should be bumped at the same time - evince depends on poppler.
Version:      2.22.2
Release:      1
Distribution: Java Desktop System
Vendor:       Sun Microsystems, Inc.
Summary:      Document viewer
Source:       http://ftp.gnome.org/pub/GNOME/sources/evince/2.22/%{name}-%{version}.tar.bz2
Source1:      %{name}-po-sun-%{po_sun_version}.tar.bz2
%if %build_l10n
Source2:                 l10n-configure.sh
%endif
# date:2006-06-06 type:branding owner:gman
Patch1:	      evince-01-menu-entry.diff
# date:2006-05-29 type:branding owner:dkenny bugster:6430428,6431474,6553312
Patch2:	      evince-02-gs-sfw.diff
# date:2008-07-14 type:bug owner:dkenny bugster:6724495 bugzilla:542924
Patch3:       evince-03-static-enum.diff
URL:          http://www.gnome.org
BuildRoot:    %{_tmppath}/%{name}-%{version}-build
Docdir:       %{_defaultdocdir}/%{name}
Autoreqprov:  on

%define gtk2_version 2.6.0
%define libgnomeui_version 2.6.0
%define dbus_version 0.33
%define poppler_version 0.4.0
%define libgnomeprintui_version 2.5.1

Requires:	gtk2 >= %{gtk2_version}
Requires:	libgnomeui >= %{libgnomeui_version}
Requires:	dbus >= %{dbus_version}
Requires:	poppler >= %{poppler_version}
Requires:       libgnomeprintui >= %{libgnomeprintui_version}
BuildRequires:  gtk2-devel >= %{gtk2_version}
BuildRequires:  libgnomeui-devel >= %{libgnomeui_version}
BuildRequires:  dbus-devel >= %{dbus_version}
BuildRequires:  poppler-devel >= %{poppler_version}
BuildRequires:  libgnomeprintui-devel >= %{libgnomeprintui_version}

%description
Evince is a document viewer capable of displaying multiple and single page document formats like PDF and Postscript.

%prep
%setup -q
%if %build_l10n
bzcat %SOURCE1 | tar xf -
cd po-sun; make; cd ..
%endif
%patch1 -p1
%patch2 -p1
%patch3 -p1

# Remove DOS line end chars. Fixes #395105.
dos2unix -ascii po/be.po po/be.po

%build
%ifos linux
if [ -x /usr/bin/getconf ]; then
  CPUS=`getconf _NPROCESSORS_ONLN`
fi
%else
  CPUS=`/usr/sbin/psrinfo | grep on-line | wc -l | tr -d ' '`
%endif
if test "x$CPUS" = "x" -o $CPUS = 0; then
  CPUS=1
fi
export PKG_CONFIG_TOP_BUILD_DIR=${PWD}

libtoolize --force
intltoolize --force --copy --automake

%if %build_l10n
bash -x %SOURCE2 --enable-copyright
%endif

aclocal $ACLOCAL_FLAGS 
automake -a -c -f
autoconf
CFLAGS="$RPM_OPT_FLAGS -I/usr/include/libxml2" \
  ./configure \
	--prefix=%{_prefix} \
        --libexecdir=%{_libexecdir} \
	--sysconfdir=%{_sysconfdir} \
	--disable-comics		\
	--mandir=%{_mandir}
make -j $CPUS

%install
make -i install DESTDIR=$RPM_BUILD_ROOT
rm $RPM_BUILD_ROOT%{_libdir}/nautilus/extensions-2.0/*.a
rm $RPM_BUILD_ROOT%{_libdir}/nautilus/extensions-2.0/*.la

%post
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
SCHEMAS="evince.schemas evince-thumbnailer.schemas"
for S in $SCHEMAS; do
        gconftool-2 --makefile-install-rule %{_sysconfdir}/gconf/schemas/$S >/dev/null
done

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr (-, root, root)
%{_bindir}/*
%{_libdir}/nautilus/extensions-2.0/*.so*
%{_datadir}/locale/*/LC_MESSAGES/*.mo
%{_datadir}/applications/*
%{_datadir}/evince/*
%{_datadir}/gnome/help/*
%{_datadir}/omf/*
%{_sysconfdir}/gconf/schemas/*

%changelog
* Mon Jul 14 2008 - [email protected]
- Add patch evince-03-static-enum.diff to make GEnum types be "static const".
  fixing bug#6724495, logged upstream bug#542924
* Thu May 29 2008 - [email protected]
- Bump to 2.22.2.
* Wed Apr 09 2008 - [email protected]
- Bump to 2.22.1.1.
* Tue Mar 11 2008 - [email protected]
- Bump to 2.22.0.
* Tue Feb 12 2008 - [email protected]
- Bump to 2.21.91.
* Tue Jan 29 2008 - [email protected]
- Bump to 2.21.90. Remove upstream patch 03-nautilus-dir.
* Fri Jan 11 2008 - [email protected]
- Add patch 03-nautilus-dir to determine nautilus extension dir via pkgconfig.
* Fri Dec 07 2007 - [email protected]
- added --disable-comics to configure option as it failed on Solaris.
* Tue Dec 04 2007 - [email protected]
- Bump to 2.21.1.
* Tue Nov 27 2007 - [email protected]
- Bump to 2.20.2. Remove upstream patch, 03-zero-pages-up.
* Mon Nov 19 2007 - [email protected]
- Add a new patch, evince-03-zero-pages-up.diff, to fix bug#6631614 
* Fri Oct 19 2007 - [email protected]
- Bump to 2.20.1.
* Tue Sep 18 2007 - [email protected]
- Bump to 2.20.0.
* Thu Aug 30 2007 - [email protected]
- Add intltoolize call to update intltool scripts.
* Tue Aug 28 2007 - [email protected]
- Bump to 2.19.4.
* Tue Jul 31 2007 - [email protected]
- Bump to 0.9.3.
* Tue Jul 10 2007 - [email protected]
- Bump to 0.9.2.
* Tue Jun 19 2007 - [email protected]
- Bump to 0.9.1.
* Tue May 15 2007 - [email protected]
- Bump to 0.9.0.
* Thu May 10 2007 - [email protected]
- Add bug#6553312 ref for gs-sfw patch. 
* Thu Apr 19 2007 - [email protected]
- add -ascii option to dos2unix so that utf8 strings are not messed up
* Thu Apr 12 2007 - [email protected]
- Bump to 0.8.1.
* Tue Mar 13 2007 - [email protected]
- Bump to 0.8.0.
* Tue Feb 13 2007 - [email protected]
- Add l10n tarball.
* Tue Feb 13 2007 - [email protected]
- Bump to 0.7.2.
* Wed Jan 10 2006 - [email protected]
- Bump to 0.7.1. Remove upstream patch, 03-lc-measurement. Add code to dos2unix
  po/be.po to fix #395105.
* Wed Jan 10 2007 - [email protected]
- Add dir to CFLAGS so that libxml headers can be found.
* Wed Dec 20 2006 - [email protected]
- Add patch, 03-lc-measurement, to fix #387887. Patch written by Glynn.
* Tue Dec 19 2006 - [email protected]
- Bump to 0.7.0.
* Tue Oct 10 2006 - [email protected]
- Bump to 0.6.1.
* Tue Sep 05 2006 - [email protected]
- Bump to 0.6.0.
* Tue Aug 08 2006 - [email protected]
- Bump to 0.5.5.
* Wed Jul 20 2006 - [email protected]
- Bump to 0.5.4.
  And remove patch 03 (upstream)
* Thu Jun 15 2006 - [email protected]
- Fixed 6437235 stop evince from crashing on PAPI print backend.
* Fri Jun 02 2006 - [email protected]
- Bump to 0.5.3
* Fri Apr 28 2006 - [email protected]
- Add patch to install into Office submenu
  with 'Evince Document Viewer'.
* Tue Mar 14 2006 - [email protected]
- Bump to 0.5.2.
* Fri Jan 20 2006 - [email protected]
- Bump to 0.5.0.
* Tue Nov 08 2005 - [email protected]
- Show the .desktop file entry for the moment.
* Fri Sep 30 2005 - [email protected]
- Bump to 0.4.0
* Wed Aug 24 2005 - [email protected]
- Add libgnomeprintui dependency.
* Tue Aug 16 2005 - [email protected]
- New spec file for evince