Summary:	Document viewer
Summary(ja): 	文書ビューワー
Name:		evince
Version:	3.18.2
Release: 	1%{?_dist_release}
Source0:	http://ftp.gnome.org/pub/GNOME/sources/%{name}/3.18/%{name}-%{version}.tar.xz

License:	GPL
Group:		Applications/Publishing
URL:		http://www.gnome.org/projects/%{name}/

BuildRequires:	gtk3-devel >= 3.0.0
BuildRequires:	gnome-desktop3-devel
BuildRequires:	libsecret-devel
BuildRequires:	poppler-devel >= 0.24.0
BuildRequires:	desktop-file-utils
BuildRequires:	adwaita-icon-theme >= 3.14.0
BuildRequires:  libxml2-devel
BuildRequires:  libspectre-devel >= 0.2.1
BuildRequires:  libkpathsea-devel
BuildRequires:  nautilus-devel
BuildRequires:  libSM-devel
BuildRequires:  libtiff-devel
BuildRequires:  libgxps-devel
BuildRequires:	gtk-doc
BuildRequires:	gsettings-desktop-schemas-devel
BuildRequires:	yelp-tools

Requires(posttrans):   desktop-file-utils glib2
Requires(postun): desktop-file-utils glib2

BuildRoot:	%{_tmppath}/%{name}-%{version}-root

Vendor: Project Vine
Distribution: Vine Linux
Packager:	daisuke, kazutaka, inagaki, Takemikaduchi

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

%description -l ja
Evince は 複数ページをに渡る PDF や Postscript 文書を表示することが
できる文書ビューワーです。

#-----------------------------------------------------------------------------

%package devel
Summary:        Libraries and headers for %{name}
Summary(ja):    %{name} 用の開発ライブラリおよびヘッダファイル
Group:          Development/Libraries
Requires:       %{name} = %{version}

%description devel
This package includes the files needed for developing and compiling
applications which use the %{name} library.

You should install the %{name}-devel package if you would like to
develop applications using %{name}.

%description devel -l ja
このパッケージは %{name} ライブラリを使用するアプリケーションを開発
するのに必要なライブラリやヘッダファイルを含んでいます。

%{name} を使用したアプリケーションを開発するなら、このパッケージ
をインストールしてください。

#-----------------------------------------------------------------------------

%package dvi
Summary:        Evince dvi backend
Summary(ja):    %{name} の dvi バックエンド
Group:		Applications/Publishing
Requires:       %{name} = %{version}-%{release}

%description dvi
This package contains a backend to let evince display dvi files.

%description dvi -l ja
このパッケージには evince で dvi ファイルを表示するためのバックエンドが
含まれています。


#-----------------------------------------------------------------------------

%prep
%setup -q

%build
%configure \
  --disable-djvu \
  --enable-introspection \
  --enable-dvi \
  --enable-ps
make %{?_smp_mflags}


%install
rm  -rf $RPM_BUILD_ROOT
make DESTDIR=$RPM_BUILD_ROOT install

desktop-file-install --vendor ''							\
	--dir $RPM_BUILD_ROOT%{_datadir}/applications			\
	--add-only-show-in GNOME								\
	$RPM_BUILD_ROOT%{_datadir}/applications/%{name}.desktop

%find_lang %{name} --with-gnome --all-name

# remove unnecessary files
rm -rf $RPM_BUILD_ROOT/%{_datadir}/icons/hicolor/icon-theme.cache
%{_bindir}/find %{buildroot}%{_libdir} -name "*.la" -exec %{__rm} -f "{}" \;
%{_bindir}/find %{buildroot}%{_libdir} -name "*.a" -exec %{__rm} -f "{}" \;

%clean
rm -rf $RPM_BUILD_ROOT


%post
touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :

%posttrans
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
update-desktop-database %{_datadir}/applications >& /dev/null || :
glib-compile-schemas %{_datadir}/glib-2.0/schemas ||:

%postun
if [ $1 -eq 0 ] ; then
    touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
    gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
    update-desktop-database %{_datadir}/applications >& /dev/null ||:
    glib-compile-schemas --allow-any-name %{_datadir}/glib-2.0/schemas || :
fi

%files -f %{name}.lang
%defattr(-,root,root)
%doc AUTHORS COPYING ChangeLog INSTALL NEWS README TODO
%{_bindir}/evince*
%{_datadir}/applications/%{name}.desktop
%{_datadir}/applications/evince-previewer.desktop
%{_datadir}/evince
%{_datadir}/gtk-doc/html/evince
%{_datadir}/gtk-doc/html/libevdocument-3.0
%{_datadir}/gtk-doc/html/libevview-3.0
%{_datadir}/icons/hicolor/*/apps/evince.*
%{_libdir}/girepository-1.0/EvinceDocument-3.0.typelib
%{_libdir}/girepository-1.0/EvinceView-3.0.typelib
%{_libdir}/evince/4/backends
%exclude %{_libdir}/evince/4/backends/libdvidocument.so*
%exclude %{_libdir}/evince/4/backends/dvidocument.evince-backend
%{_libdir}/lib*.so.*
%{_libdir}/mozilla/plugins/libevbrowserplugin.so
%{_libdir}/nautilus/extensions-3.0/libevince-properties-page.*
%{_libexecdir}/evinced
%{_datadir}/dbus-1/services/*
%{_mandir}/man1/evince.*
%{_datadir}/GConf/gsettings/evince.convert
%{_datadir}/appdata/evince-comicsdocument.metainfo.xml
%{_datadir}/appdata/evince-dvidocument.metainfo.xml
%{_datadir}/appdata/evince-pdfdocument.metainfo.xml
%{_datadir}/appdata/evince-psdocument.metainfo.xml
%{_datadir}/appdata/evince-tiffdocument.metainfo.xml
%{_datadir}/appdata/evince-xpsdocument.metainfo.xml
%{_datadir}/appdata/evince.appdata.xml
%{_datadir}/glib-2.0/schemas/org.gnome.Evince.gschema.xml
%{_datadir}/thumbnailers/evince.thumbnailer

%files devel
%{_includedir}/evince
%{_libdir}/lib*.so
%{_libdir}/pkgconfig/*.pc
%{_datadir}/gir-1.0/EvinceDocument-3.0.gir
%{_datadir}/gir-1.0/EvinceView-3.0.gir

%files dvi
%{_libdir}/evince/4/backends/libdvidocument.so*
%{_libdir}/evince/4/backends/dvidocument.evince-backend


%changelog
* Fri Nov 13 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.18.2-1
- new upstream release

* Sun Nov 01 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.18.1-1
- new upstream release

* Sat May 30 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.16.1-1
- new upstream release

* Sun Mar 29 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.16.0-1
- new upstream release
- add BuildRequires: gnome-desktop3-devel

* Sun Oct 26 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.14.1-1
- new upstream release
- change BuildRequires: adwaita-icon-theme instead of gnome-icon-theme

* Thu Aug 21 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.2-1
- new upstream release

* Tue Jul 08 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.1-5
- rebuild with poppler-0.26.2

* Sun Jul 06 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.1-4
- rebuild with libarchive-3.1.2

* Wed Jun 11 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.1-3
- add OnlyShowIn=GNOME; to evince.desktop

* Sat May 03 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.1-2
- rebuild with poppler-0.24.5

* Sun Apr 20 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.1-1
- new upstream release

* Sat Mar 29 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.0-1
- new upstream release

* Sun Nov 24 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.10.3-1
- new upstream release

* Sat Oct 26 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.10.0-1
- new upstream release

* Mon Jul 15 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.8.3-1
- new upstream release

* Sun May 19 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.8.2-1
- new upstream release

* Sun Apr 21 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.8.0-1
- new upstream release
- remove Patch0	(evince-3.4.0-desktop.patch)

* Tue Oct 16 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.6.1-1
- new upstream release

* Sat Sep 29 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.6.0-1
- new upstream release
- add BuildRequires: libgxps-devel
- change BuildRequires: yelp-tools instead of gnome-doc-utils

* Sun Apr 29 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.4.0-1
- new upstream release
- add BuildRequires: gsettings-desktop-schemas-devel
- add Patch0 (evince-3.4.0-desktop.patch)

* Mon Nov 28 2011 Munehiro Yamamoto <munepi@vinelinux.org> 3.2.1-2
- rebuilt with libkpathsea-devel-2011

* Sat Oct 22 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.2.1-1
- new upstream release

* Thu Sep 29 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.2.0-1
- new upstream release

* Sat Sep 24 2011 Yasumichi Akahoshi <yasumichi@vinelinux.org> 3.1.90.1-2
- add configure option '--enable-introspection'

* Fri Sep 23 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.1.90.1-1
- new upstream release
- add BuildRequires: libtiff-devel

* Mon Aug 15 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.1.2-1
- new upstream release

* Sat Mar 12 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.32.0-2
- rebuilt with poppler-0.16.3

* Sun Oct 03 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.32.0-1
- new upstream release

* Thu Sep 23 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.2-3
- rebuild with rpm-4.8.1 for pkg-config file

* Sun Aug 22 2010 SHu KONNO <owa@bg.wakwak.com> 2.30.2-2
- rebuilt with libkpathsea-2009-9

* Sat Jun 26 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.2-1
- new upstream release

* Sun May 30 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.1-1
- new upstream release

* Sun Apr 04 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.30.0-1
- new upstream release
- change BuildRequires: gnome-keyring-devel -> libgnome-keyring-devel
- add BuildRequires: gtk-doc

* Sat Mar 13 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.28.2-1
- new upstream release
- add BuildRequires: libSM-devel, GConf2-devel

* Sat Nov  7 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.28.1-2
- added --disable-djvu option to %%configue

* Mon Nov  2 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.28.1-1
- new upstream release
- built with poppler-0.12.1
- added %%posttrans section 

* Mon May 18 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.26.2-1
- new upstream release

* Fri May 01 2009 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 2.26.1-3
- modify scriptlet for gconf schemas to make it faster [VineSeed:17360]
- add BuildRequires: nautilus-devel

* Fri Apr 24 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.26.1-2
- add BuildRequires: libkpathsea-devel for dvi backend
- split dvi backend to subpackage
- fix scriptlets

* Thu Apr 23 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.26.1-1
- new upstream release

* Sun Mar 22 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.26.0-1
- new upstream release

* Sat Dec 13 2008 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 2.24.2-1
- new upstream release
- build with poppler-0.10.2

* Wed Oct 29 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 2.24.1-1
- new upstream release
- add BR: libspectre >= 0.2.1

* Tue Oct 14 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.24.0-3
- fixed %pre, %post, %preun (for evince-thumbnailer-ps.schemas)

* Mon Oct 13 2008 Shu KONNO <owa@bg.wakwak.com> 2.24.0-2
- built without libdjvulibre.so

* Mon Oct 13 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.24.0-1
- new upstream release

* Thu Jun  5 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.22.2-1
- new upstream release
- removed BuildRequires: libgnomeprint[ui]-devel

* Sat Apr 19 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.22.1.1-1
- new upstream release
- added %%pre and %%preun section

* Fri Apr 11 2008 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 2.22.1-1
- source update.
- add devel sub package.
- use %%{__make} install instead of %%%makeinstall.

* Mon Mar 31 2008 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 2.21.1-1
- source update.
- build with poppler-0.8.0.
- apply new versioning policy.

* Tue Dec 11 2007 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 2.21.1-0vl1
- source update.

* Sat Oct 27 2007 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 2.20.1-0vl1
- source update.

* Sat Sep 08 2007 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 2.19.92-0vl1
- source update.
- build with poppler-0.6.
- drop Patch1 and increase required gnome-theme-icon version >= 2.17.1.

* Sun Sep  2 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.9.3-0vl1
- source update.

* Sat May 19 2007 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.9.0-0vl1
- source update.

* Wed Apr 25 2007 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.8.1-0vl1
- source update.

* Tue Mar 20 2007 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.8.0-0vl1
- source update.

* Wed Feb 14 2007 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.7.2-0vl1
- source update.
- update patch1.

* Wed Dec 20 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.7.0-0vl1
- source update.
- drop patch100. (included in upstream)
- add pathc1 to lowering required version of gnome-icon-theme.

* Sun Dec 17 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 0.6.1-0vl2
- rebuild

* Wed Dec 13 2006 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 0.6.1-0vl1.1
- add patch100 for fix CVE-2006-5864

* Wed Oct 18 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.6.1-0vl1
- source update.

* Sun Sep 10 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.6.0-0vl1
- source update.
- reuse %%{name} for find_lang.

* Fri Aug 11 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.5.5-0vl1
- source update.
- use "Evince" instead of %%{name} for find_lang because of naming change.

* Wed Jul 19 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.5.4-0vl1
- source update.

* Sun May 28 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.5.3-0vl1
- source update.
- add some hicolor theme icons in %%files section.
- remove unnecessary icon-theme.cache file.
- update BuildRequires.

* Tue Mar 07 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.5.1-0vl1
- source update.

* Wed Mar 01 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.5.0-0vl1
- source update.
- change BuildRequires of poppler-devel (from >= 0.4.3 to >= 0.5.0)

* Wed Sep 21 2005 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.4.0-0vl1
- source update.
- add BuildRequires: poppler-devel >= 0.4.0, libgnomeprint-devel,
  libgnomeprintui-devel.
- add configure option --disable-scrollkeeper.
- add %%{_libdir}/nautilus/extensions-1.0/libevince-properties-page.* in
  %%files section.

* Sat Jun 25 2005 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.3.2-0vl1
- source update.

* Tue May 24 2005 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.3.1-0vl1
- source update.

* Wed May 18 2005 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.3.0-0vl1
- source update.
- add %doc in %file section.

* Thu May 05 2005 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.2.1-0vl1
- initial build for VineSeed Plus.
