%define major 0 %define libname %mklibname %name %major %define libnamedev %mklibname -d %name %define xmlcatalog %{_sysconfdir}/xml/catalog Summary: Cataloging system for documentation on open systems Name: rarian Version: 0.8.1 Release: %mkrel 10 Source0: http://rarian.freedesktop.org/Releases/%{name}-%{version}.tar.bz2 Source1: scrollkeeper-omf.dtd # gw https://bugs.freedesktop.org/show_bug.cgi?id=11779 Patch0: rarian-0.5.4-mv.patch Patch1: rarian-0.8.1-xz-support.patch License: GPLv2+ Group: Publishing Url: http://rarian.freedesktop.org/ Provides: scrollkeeper = %version-%release Obsoletes: scrollkeeper Requires(post): libxml2-utils sgml-common util-linux-ng coreutils Requires(preun): libxml2-utils sgml-common %description Rarian is a cataloging system for the installed documentation. Rarian is designed to be a replacement for scrollkeeper. It is currently undergoing heavy development. As of writing, rarian can be installed in place of scrollkeeper and everything will work okay. %package -n %libname Group: System/Libraries Summary: Rarian cataloging system library %description -n %libname Rarian is a cataloging system for the installed documentation. Rarian is designed to be a replacement for scrollkeeper. It is currently undergoing heavy development. As of writing, rarian can be installed in place of scrollkeeper and everything will work okay. %package -n %libnamedev Group: Development/C Summary: Rarian cataloging system - development files Requires: %libname = %version Provides: %name-devel = %version-%release Provides: lib%name-devel = %version-%release Provides: scrollkeeper-devel = %version-%release %description -n %libnamedev Rarian is a cataloging system for the installed documentation. Rarian is designed to be a replacement for scrollkeeper. It is currently undergoing heavy development. As of writing, rarian can be installed in place of scrollkeeper and everything will work okay. %prep %setup -q %apply_patches %build %configure2_5x --disable-skdb-update --localstatedir=/var --disable-static %make %install %makeinstall_std localstatedir=%buildroot/var rm -f %buildroot%{_libdir}/*.la mkdir -p %buildroot/var/lib/rarian touch %buildroot/var/lib/rarian/rarian-update-mtimes install -D -m 644 %SOURCE1 %buildroot%{_datadir}/xml/scrollkeeper/dtds/scrollkeeper-omf.dtd # automatic cache update on rpm installs/removals # (see http://wiki.mandriva.com/en/Rpm_filetriggers) install -d %buildroot%{_var}/lib/rpm/filetriggers cat > %buildroot%{_var}/lib/rpm/filetriggers/rarian.filter << EOF ^./usr/share/omf/.*\.omf$ EOF cat > %buildroot%{_var}/lib/rpm/filetriggers/rarian.script << EOF #!/bin/sh /usr/bin/scrollkeeper-update -q EOF chmod 755 %buildroot%{_var}/lib/rpm/filetriggers/rarian.script %post if [ "$1" = "1" ]; then %_bindir/rarian-sk-update %{_bindir}/xmlcatalog --noout --add "public" \ "-//OMF//DTD Scrollkeeper OMF Variant V1.0//EN" \ "%{_datadir}/xml/scrollkeeper/dtds/scrollkeeper-omf.dtd" %xmlcatalog fi %_bindir/rarian-sk-rebuild > /dev/null || true %preun if [ "$1" = "0" -a -f %xmlcatalog -a -x %{_bindir}/xmlcatalog ] ; then %{_bindir}/xmlcatalog --noout --del \ "%{_datadir}/xml/scrollkeeper/dtds/scrollkeeper-omf.dtd" %xmlcatalog fi %postun if [ "$1" = "0" ]; then # rarian is being removed, not upgraded. rm -f %_datadir/help/*.document fi %files %doc README NEWS %_bindir/rarian* %_bindir/scrollkeeper* %dir %_datadir/help/ %_datadir/help/rarian.document %_datadir/librarian %dir %{_datadir}/xml/scrollkeeper/ %dir %{_datadir}/xml/scrollkeeper/dtds/ %{_datadir}/xml/scrollkeeper/dtds/scrollkeeper-omf.dtd %dir /var/lib/rarian %ghost /var/lib/rarian/rarian-update-mtimes %{_var}/lib/rpm/filetriggers/rarian.* %files -n %libname %_libdir/librarian.so.%{major}* %files -n %libnamedev %doc ChangeLog TODO %_libdir/librarian.so %_includedir/rarian %_libdir/pkgconfig/rarian.pc %changelog * Mon Jan 14 2013 umeabot <umeabot> 0.8.1-10.mga3 + Revision: 380200 - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild * Wed Feb 15 2012 ovitters <ovitters> 0.8.1-9.mga2 + Revision: 209271 - clean spec * Wed Nov 30 2011 fwang <fwang> 0.8.1-8.mga2 + Revision: 174358 - drop .la files * Tue Mar 15 2011 misc <misc> 0.8.1-7.mga2 + Revision: 71529 - add a Requires on coreutils, needed to run rarian-sk-update, spotted by jbj buildbot * Sun Jan 09 2011 blino <blino> 0.8.1-7.mga1 + Revision: 3243 - remove old scrollkeeper migration - imported package rarian