File docbook-dsssl-stylesheets.spec of Package docbook-dsssl-stylesheets
#
# spec file for package docbook-dsssl-stylesheets (Version 1.79)
#
# 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: docbook-dsssl-stylesheets
BuildRequires: sgml-skel
License: distributable, Other License(s), see package
Group: Productivity/Publishing/DocBook
Autoreqprov: on
%define regcat /usr/bin/sgml-register-catalog
PreReq: %{regcat}
BuildArchitectures: noarch
Summary: DSSSL Stylesheets for the DocBook DTD
Version: 1.79
Release: 18
URL: http://sourceforge.net/projects/docbook/
Source0: http://belnet.dl.sourceforge.net/sourceforge/docbook/docbook-dsssl-%{version}.tar.gz
Source1: http://belnet.dl.sourceforge.net/sourceforge/docbook/docbook-dsssl-doc-%{version}.tar.gz
%define db2html dbtohtml.dsl
Source2: dbtohtml.dsl
%define ld2db ld2db.dsl
Source3: ld2db.dsl
Source4: %{name}-README.SuSE
# Source5: html-dbqanda.dsl
# Source6: print-dbqanda.dsl
%define pkgdif docbkdsl.dif
Patch: docbkdsl.dif
# Patch1: dds-cvs.diff
Requires: docbook_3 docbook_4
Obsoletes: docbkdsl
Provides: docbkdsl
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
You can use these DSSSL stylesheets to convert DocBook documents into
other formats. "Print" (TeX and RTF) and "online" (HTML) output formats
are available.
The stylesheets are customizable and, within limits, it is possible to
adapt them for your own needs. Numerous native languages are supported.
Authors:
--------
Norman Walsh <ndw@nwalsh.com>
%define INSTALL install -m755 -s
%define INSTALL_DIR install -d -m755
%define INSTALL_DATA install -m644
%define INSTALL_SCRIPT install -m755 -o root -g root
%define sgml_dir %{_datadir}/sgml
%prep
%setup -q -n docbook-dsssl-%{version} -b 1
# cp -p %{S:5} html/dbqanda.dsl
# cp -p %{S:6} print/dbqanda.dsl
cp -p $RPM_SOURCE_DIR/%{db2html} .
cp -p $RPM_SOURCE_DIR/%{ld2db} .
cp -p %{S:4} README.SuSE
%patch -P 0 -p 0
# %patch -P 1 -p 1 -b .cvs
%build
%install
export RPM_BUILD_ROOT
if [ ! "x" = "x$RPM_BUILD_ROOT" ]; then
rm -fr $RPM_BUILD_ROOT
%{INSTALL_DIR} $RPM_BUILD_ROOT
fi
doc_dir=$RPM_BUILD_ROOT%{_defaultdocdir}/%{name}
sgml_dir=$RPM_BUILD_ROOT%{_datadir}/sgml
sgml_dir_db=$RPM_BUILD_ROOT%{_datadir}/sgml/docbook
sgml_dir_db_sty=$RPM_BUILD_ROOT%{_datadir}/sgml/docbook/dsssl-stylesheets-%{version}
sgml_config_dir=$RPM_BUILD_ROOT/var/lib/sgml
%{INSTALL_DIR} $sgml_dir_db_sty
cp -a [a-z]* $sgml_dir_db_sty
cp -a VERSION $sgml_dir_db_sty
%{INSTALL_DIR} $doc_dir
%{INSTALL_DIR} $sgml_config_dir/%{name}-%{version}
%{INSTALL_DIR} $sgml_dir/Norman_Walsh/document
%{INSTALL_DIR} $sgml_dir/Norman_Walsh/dtd
%{INSTALL_DIR} $sgml_dir/IDN_nwalsh.com/dtd
sed -e 's:^ \([a-z]\): %{_datadir}/sgml/docbook/dsssl-stylesheets-%{version}/\1:' \
-e 's:^SGMLDECL ":SGMLDECL "%{_datadir}/sgml/docbook/dsssl-stylesheets-%{version}/:' \
< catalog > CATALOG.docbkdsl
# echo -e "\
# CATALOG \"/var/lib/sgml/CATALOG.iso_ent\"\n\
# CATALOG \"/var/lib/sgml/CATALOG.docbk31\"\n\
# CATALOG \"/var/lib/sgml/CATALOG.docbk30\"\n\
# CATALOG \"/var/lib/sgml/CATALOG.docbk41\"\n"\
# >> docbook/CATALOG.docbkdsl
%{INSTALL_DATA} CATALOG.docbkdsl $sgml_config_dir/CATALOG.%{name}
pushd $sgml_config_dir
ln -sf CATALOG.%{name} CATALOG.docbkdsl
popd
pushd $sgml_dir
ln -sf ../../../var/lib/sgml/CATALOG.%{name} CATALOG.%{name}
ln -sf ../../../var/lib/sgml/CATALOG.%{name} CATALOG.docbkdsl
popd
# documentation
# pushd docbook
for f in README BUGS TODO WhatsNew; do
[ -f $f ] && %{INSTALL_DATA} $f $doc_dir/$f
done
# popd
# misc
%{INSTALL_DIR} $sgml_dir_db_sty/misc
cp %{db2html} $sgml_dir_db_sty/misc
cp %{ld2db} $sgml_dir_db_sty/misc
# cp index.html $doc_dir
cp -p README.SuSE $doc_dir
pushd common
rm -f $sgml_dir_db_sty/common/dbl1*.dsl
rm -f $sgml_dir_db_sty/common/*.ent
%{INSTALL_DATA} dbl1*.dsl $sgml_config_dir/%{name}-%{version}
%{INSTALL_DATA} *.ent $sgml_config_dir/%{name}-%{version}
popd
pushd $sgml_dir_db_sty/common
for l in ../../../../../../var/lib/sgml/%{name}-%{version}/*.{dsl,ent}; do
ln -sf $l .
done
popd
pushd $sgml_dir/docbook
rm -f dsssl-stylesheets
ln -sf dsssl-stylesheets-%{version} dsssl-stylesheets
# remove this when docbook-toys is updated
# 2001-11-29 10:56:56 CET -ke-
rm -f %{name}
ln -sf dsssl-stylesheets-%{version} %{name}
popd
%post
# remove empty dirs if present (from ghost; pre 8.0)
# also remove dangling symlinks
D=usr/share/sgml
rmdir $D/docbkdsl >/dev/null 2>&1 || :
test -L $D/docbkdsl -a ! -e $D/docbkdsl && rm -f $D/docbkdsl
D=var/lib/sgml
rmdir $D/docbkdsl >/dev/null 2>&1 || :
test -L $D/docbkdsl -a ! -e $D/docbkdsl && rm -f $D/docbkdsl
D=usr/share/sgml/docbook
rmdir $D/%{name} >/dev/null 2>&1 || :
test -L $D/%{name} -a ! -e $D/%{name} && rm -f $D/%{name}
# register catalog
if [ -x %{regcat} ]; then
for c in %{name}; do
grep -q -e "%{sgml_dir}/CATALOG.$c\"\?$" /etc/sgml/catalog \
|| %{regcat} -a %{sgml_dir}/CATALOG.$c >/dev/null 2>&1
done
fi
exit 0
%postun
if [ "$1" = "0" -a -x %{regcat} ]; then
for c in %{name}; do
%{regcat} -r %{sgml_dir}/CATALOG.$c >/dev/null 2>&1
done
fi
exit 0
%clean
rm -fr $RPM_BUILD_ROOT
%files
%defattr(-, root, root)
%config /var/lib/sgml/CATALOG.%{name}
/var/lib/sgml/CATALOG.docbkdsl
%dir /var/lib/sgml/%{name}-%{version}
%config /var/lib/sgml/%{name}-%{version}/*.dsl
%config /var/lib/sgml/%{name}-%{version}/*.ent
%{_datadir}/sgml/CATALOG.*
%dir %{_datadir}/sgml/docbook/dsssl-stylesheets
%dir %{_datadir}/sgml/docbook/%{name}
%{_datadir}/sgml/docbook/dsssl-stylesheets-%{version}
%{_defaultdocdir}/%{name}
%changelog -n docbook-dsssl-stylesheets
* Mon May 29 2006 - ke@suse.de
- Use %%postun instead of %%preun and check for the update case; reported
by Marcus Meissner.
* Wed Jan 25 2006 - mls@suse.de
- converted neededforbuild to BuildRequires
* Wed Dec 21 2005 - aj@suse.de
- Package symlink.
* Fri Nov 05 2004 - ke@suse.de
- Update to version 1.79 which also includes "bs" and "bg" localization
files.
- Drop obsolete CVS ariginated patch.
* Tue Oct 12 2004 - ke@suse.de
- Apply all current changes from CVS, only leave out "bs" and "bg"
localization files because building .ent files failed ATM.
* Mon Feb 23 2004 - hmacht@suse.de
- building as non-root
* Wed Mar 26 2003 - ke@suse.de
- Update to version 1.78, which comes with all the patches applied on
2003-01-31; thus drop them here.
* Fri Jan 31 2003 - ke@suse.de
- Apply some fixes from the SF CVS:
- bookinfo-legal-product.diff: Fix HTML formatting when <productname>
occurs in legalinfo in bookinfo (from CVS 2003/01/21).
- indexterm-seealso.diff: Fix bin/collateindex.pl when indexterm has
two different seealso's (from CVS 2003/01/19).
- navig-level-chunk.diff: Fix PDF bookmark hierarchy (from CVS
2003/01/15); provided by Susanne Oberhauser.
- dbl1en-case-folding.diff: Fix some case folding of some English standard
phrases (from CVS 2002/12/20).
- db-html-dbgraph-syntax-fix.diff: Fix syntax in html/dbgraph.dsl,
append wants a list (from CVS 2003/01/20).
* Fri Nov 29 2002 - ke@suse.de
- Register catalog file using sgml-register-catalog.
* Fri Jul 12 2002 - mls@suse.de
- fixed postinstall script
* Mon Jul 08 2002 - ke@suse.de
- Update to version 1.77: Mostly a bug-fix release, but also includes a
few user-requested feature enhancements: footnote, list, title page
formatting and more.
* Fri Apr 26 2002 - ke@suse.de
- Update to version 1.76 (patches added on 2002-03-16 and 2002-02-20 are
superfluous):
Bug fixes concerning formatting (lists) and index creation.
* Thu Mar 14 2002 - ke@suse.de
- Backport images from docbook-dsssl-1.76; or in other words: add PDF
and EPS.
Reported by Pavel Janik [# 14905].
* Wed Feb 20 2002 - ke@suse.de
- Apply docbook-dsssl-1.74b-lfr.diff to fix a quoting problem (for
French texts only); discussed on the DocBook Apps mailinglist by
Norman Walsh and camille [# 13501].
* Mon Dec 03 2001 - ke@suse.de
- Update to version 1.74b (bugfix release).
* Thu Nov 29 2001 - ke@suse.de
- Update to version 1.74:
- Better localization support.
- Enhancements (e.g., more line numberings; support glossary and index
in article correctly).
- Bug fixes (e.g., keep-with-next properties, callouts).
- As announced for 8.0 remove convenience links.
- Cleanup spec file.
* Thu Oct 18 2001 - ke@suse.de
- For HTML output process "emphasis" elements correctly; apply
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/docbook/dsssl/html/dbinline.dsl.diff?r1=1.5&r2=1.6.
Reported by Ulrich Windl [# 11886].
* Tue Aug 07 2001 - ke@suse.de
- Update to version 1.72.
* Thu Jul 12 2001 - ke@suse.de
- Update to version 1.71 (experimental).
- Adjust .spec file (now we've proper .tar.gz files instead of .zip
files).
- Provide an additional convenience link through %%post.
* Thu Mar 29 2001 - ro@suse.de
- tweaked postinstall again.
* Wed Mar 28 2001 - ro@suse.de
- fixed postinstall
- redefining version macro is dangerous.
* Mon Mar 26 2001 - ke@suse.de
- Rename package: docbkdsl -> docbook-dsssl-stylesheets.
- Provide compatibility links.
- Adjust README.SuSE.
* Mon Mar 19 2001 - ke@suse.de
- Update to version 1.64
* Thu Feb 01 2001 - ke@suse.de
- Update to version 1.62.
* Mon Dec 18 2000 - ke@suse.de
- Update to version 1.60 (to fix a TOC creation bug).
* Thu Nov 02 2000 - ke@suse.de
- Update to version 1.59.
- spec file cleanup (more macros); reduce CATALOG file.
* Fri Sep 22 2000 - ke@suse.de
- Update to version 1.57.
* Wed Aug 16 2000 - ke@suse.de
- Update to version 1.56.
- Require docbk30 and docbk_4.
* Tue May 30 2000 - ke@suse.de
- Update to version 1.54.
- Use %%{_defaultdocdir}
* Fri Jan 28 2000 - ke@suse.de
- Update to version 1.52.
- Add groupt tag.
- User %%version macro.
- Apply patch from Norm Walsh to correct a typo.
* Fri Dec 17 1999 - ke@suse.de
- Update: 1.49 (bugfix release).
* Sun Oct 24 1999 - ke@suse.de
- Update: 1.46 (bugfix release).
- Mark the package as "noarch".
* Fri Oct 01 1999 - ke@suse.de
- Update: 1.45.
- Fix check marco.
* Mon Sep 13 1999 - bs@suse.de
- ran old prepare_spec on spec file to switch to new prepare_spec.
* Mon Aug 09 1999 - ke@suse.de
- Update: version 1.43.
- Add `Check'.
* Mon Jul 12 1999 - ke@suse.de
- Update: version 1.42 (bugfix release).
* Tue Jun 29 1999 - ke@suse.de
- Update: version 1.41.
* Wed Apr 21 1999 - ke@suse.de
- Update: version 1.40.
* Thu Apr 08 1999 - ke@suse.de
- Update: version 1.38b.
* Sun Mar 28 1999 - ke@suse.de
- Add the stylesheet ld2db.dsl from SGMLtools.
* Sun Mar 21 1999 - ke@suse.de
- Update: version 1.37.
* Fri Mar 12 1999 - ke@suse.de
- Take care about usr/doc/packages/docbkdsl/* links (%%post, &preun).
- Don't install the broken index.html.
* Tue Dec 08 1998 - ke@suse.de
- Update: version 1.28.
- Install the collateindex.pl library as a data file under .../share/...
* Tue Nov 24 1998 - ke@suse.de
- Update: version 1.24.
- Update: dbtohtml.dsl.
- Fix typo in CATALOG.docbkdsl (refer CATALOG.dokbk30).
* Fri Nov 13 1998 - bs@suse.de
- removed trailing blanks (problem with new rpm)
* Fri Nov 06 1998 - ke@suse.de
- Update: version 1.23 (bug fix release).
* Thu Nov 05 1998 - ke@suse.de
- Update: version 1.22.
* Mon Oct 26 1998 - ke@suse.de
- Formerly, this software was part of the package `dokbk30'.
Version 1.19.