Blob Blame History Raw
Name:           doclifter
Version:        2.15
Release:        4%{?dist}
Summary:        Translates documents written in troff macros to DocBook

License:        BSD
URL:            http://www.catb.org/~esr/doclifter/
Source0:        http://www.catb.org/~esr/%{name}/%{name}-%{version}.tar.gz
# The template for man page translations can be created with this command:
# po4a-updatepo -v -M utf-8 -f man --option groff_code=verbatim -m manlifter.1 -p manlifter.pot
Source1:        https://mariobl.fedorapeople.org/Translations/%{name}/manlifter.1.de.po
Patch0:         %{name}.patch

BuildArch:      noarch
BuildRequires:  po4a
BuildRequires:  python2

%description
The doclifter program translates documents written in troff macros to DocBook.

Lifting documents from presentation level to semantic level is hard, and
a really good job requires human polishing.  This tool aims to do everything
that can be mechanized, and to preserve any troff-level information that might
have structural implications in XML comments.

This tool does the hard parts.  TBL tables are translated into DocBook
table markup, PIC into SVG, and EQN into MathML (relying on pic2svg
and GNU eqn for the last two).

%prep
%setup -q
%patch0


%build
# Nothing to build


%install
mkdir -p "$RPM_BUILD_ROOT"%{_bindir}
mkdir -p "$RPM_BUILD_ROOT"%{_mandir}/man1/
cp doclifter manlifter "$RPM_BUILD_ROOT"%{_bindir}
cp doclifter.1 manlifter.1 "$RPM_BUILD_ROOT"%{_mandir}/man1/

# Generate and install localized man page
mkdir -p man/de
po4a-translate -M utf-8 -f man \
               --option groff_code=verbatim \
               -p %SOURCE1 -m manlifter.1 \
               -l man/de/manlifter.1

mkdir -p $RPM_BUILD_ROOT/%{_mandir}/de/man1
install -p man/de/manlifter.1 $RPM_BUILD_ROOT/%{_mandir}/de/man1

%check
make check


%files
%doc README TODO
%license COPYING
%{_bindir}/*
%{_mandir}/man1/*.1.*
%{_mandir}/*/man1/*.1.*


%changelog
* Sat Nov 07 2015 Mario Blättermann <mario.blaettermann@gmail.com> - 2.15-4
- Rebuilt for f24

* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.15-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild

* Tue Dec 30 2014 Mario Blättermann <mario.blaettermann@gmail.com> - 2.15-2
- Add German version of manlifter.1
- Use %%license macro

* Mon Jun 02 2014 Mario Blättermann <mariobl@fedoraproject.org> - 2.15-1
- New upstream version

* Mon Jun 02 2014 Mario Blättermann <mariobl@fedoraproject.org> - 2.14-1
- New upstream version

* Mon Nov 04 2013 Mario Blättermann <mariobl@fedoraproject.org> - 2.13-2
- Patch for fixing the shebangs to python2

* Sun Nov 3 2013 Mario Blättermann <mariobl@fedoraproject.org> - 2.13-1
- Initial package