dblatex/dblatex.spec

138 lines
4.5 KiB
RPMSpec
Raw Normal View History

Name: dblatex
2021-02-18 11:00:32 +00:00
Version: 0.3.12
Release: %autorelease
Summary: DocBook to LaTeX/ConTeXt Publishing
BuildArch: noarch
# Most of package is GPLv2+, except:
# xsl/ directory is DMIT
# lib/dbtexmf/core/sgmlent.txt is Public Domain
# latex/misc/enumitem.sty, multirow2.sry and ragged2e.sty are LPPL
# latex/misc/lastpage.sty is GPLv2 (no +)
# latex/misc/passivetex is MIT (not included in binary RPM so not listed)
2022-12-06 15:29:12 +00:00
License: GPL-2.0-or-later AND GPL-2.0-only AND LPPL-1.3a AND LicenseRef-DMIT AND LicenseRef-Fedora-Public-Domain
URL: http://dblatex.sourceforge.net/
2021-02-18 11:00:32 +00:00
Source0: http://downloads.sourceforge.net/%{name}/%{name}3-%{version}.tar.bz2
# Source1 is from http://docbook.sourceforge.net/release/xsl/current/COPYING
Source1: COPYING-docbook-xsl
2020-02-05 14:49:40 +00:00
Patch0: dblatex-0.3.11-disable-debian.patch
Patch1: dblatex-0.3.11-which-shutil.patch
2021-02-18 11:24:27 +00:00
Patch2: dblatex-0.3.11-replace-inkscape-by-rsvg.patch
# Patch3 sent upstream: https://sourceforge.net/p/dblatex/patches/12/
Patch3: dblatex-0.3.12-replace-imp-by-importlib.patch
2023-07-06 13:04:32 +00:00
# Patch4 sent upstream: https://sourceforge.net/p/dblatex/patches/13/
Patch4: dblatex-0.3.12-adjust-submodule-imports.patch
2019-09-23 08:38:00 +00:00
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: libxslt
BuildRequires: texlive-base
BuildRequires: texlive-collection-latex
BuildRequires: texlive-collection-xetex
BuildRequires: texlive-xmltex-bin
BuildRequires: texlive-anysize
BuildRequires: texlive-appendix
BuildRequires: texlive-changebar
BuildRequires: texlive-fancybox
BuildRequires: texlive-jknapltx
BuildRequires: texlive-multirow
BuildRequires: texlive-overpic
BuildRequires: texlive-passivetex
BuildRequires: texlive-pdfpages
BuildRequires: texlive-subfigure
BuildRequires: texlive-stmaryrd
BuildRequires: texlive-wasysym
Requires: texlive-base
Requires: texlive-collection-latex
Requires: texlive-collection-xetex
Requires: texlive-collection-fontsrecommended
Requires: texlive-xmltex texlive-xmltex-bin
Requires: texlive-anysize
Requires: texlive-appendix
Requires: texlive-bibtopic
Requires: texlive-changebar
Requires: texlive-ec
Requires: texlive-fancybox
Requires: texlive-jknapltx
Requires: texlive-multirow
Requires: texlive-overpic
Requires: texlive-passivetex
Requires: texlive-pdfpages
Requires: texlive-subfigure
Requires: texlive-stmaryrd
Requires: texlive-wasysym
Requires: texlive-xmltex-bin
Requires: libxslt docbook-dtds
Recommends: ImageMagick
Recommends: texlive-epstopdf-bin
Recommends: transfig
2021-02-18 11:24:27 +00:00
Recommends: librsvg2-tools
2007-11-13 17:46:05 +00:00
%description
dblatex is a program that transforms your SGML/XMLDocBook
documents to DVI, PostScript or PDF by translating them
into pure LaTeX as a first process. MathML 2.0 markups
are supported, too. It started as a clone of DB2LaTeX.
Authors:
--------
Benoît Guillon <marsgui at users dot sourceforge dot net>
Andreas Hoenen <andreas dot hoenen at arcor dot de>
%prep
%autosetup -n %{name}3-%{version} -p 1
2019-09-23 08:38:00 +00:00
rm -rf lib/contrib
%py3_shebang_fix .
2007-11-13 17:46:05 +00:00
%build
2019-09-23 08:38:00 +00:00
%{__python3} setup.py build
2007-11-13 17:46:05 +00:00
%install
2019-09-23 08:38:00 +00:00
%{__python3} setup.py install --root $RPM_BUILD_ROOT
%py3_shebang_fix $RPM_BUILD_ROOT%{_bindir}/dblatex
2007-11-13 17:46:05 +00:00
# these are already in tetex-latex:
for file in bibtopic.sty enumitem.sty ragged2e.sty passivetex/ xelatex/; do
2007-11-13 17:46:05 +00:00
rm -rf $RPM_BUILD_ROOT%{_datadir}/dblatex/latex/misc/$file
done
mkdir -p $RPM_BUILD_ROOT%{_datadir}/texlive/texmf-dist/tex/latex/dblatex
for file in ` find $RPM_BUILD_ROOT%{_datadir}/dblatex/latex/ -name '*.sty' ` ; do
mv $file $RPM_BUILD_ROOT%{_datadir}/texlive/texmf-dist/tex/latex/dblatex/`basename $file`;
2007-11-13 17:46:05 +00:00
done
## also move .xetex files
for file in ` find $RPM_BUILD_ROOT%{_datadir}/dblatex/latex/ -name '*.xetex' ` ; do
mv $file $RPM_BUILD_ROOT%{_datadir}/texlive/texmf-dist/tex/latex/dblatex/`basename $file`;
done
2007-11-13 17:46:05 +00:00
rmdir $RPM_BUILD_ROOT%{_datadir}/dblatex/latex/{misc,contrib/example,style}
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/dblatex
# shipped in %%docs
rm -rf $RPM_BUILD_ROOT%{_datadir}/doc/
sed -e 's/\r//' xsl/mathml2/README > README-xsltml
touch -r xsl/mathml2/README README-xsltml
cp -p %{SOURCE1} COPYING-docbook-xsl
%files
%{_mandir}/man1/dblatex.1*
%doc COPYRIGHT docs/manual.pdf COPYING-docbook-xsl README-xsltml
2019-09-23 08:38:00 +00:00
%{python3_sitelib}/dbtexmf/
%{python3_sitelib}/dblatex-*.egg-info
2007-11-13 17:46:05 +00:00
%{_bindir}/dblatex
%{_datadir}/dblatex/
%{_datadir}/texlive/texmf-dist/tex/latex/dblatex/
2007-11-13 17:46:05 +00:00
%dir %{_sysconfdir}/dblatex
%post -p /usr/bin/texhash
%postun -p /usr/bin/texhash
%changelog
%autochangelog