File catdoc.spec of Package catdoc

#
# spec file for package catdoc
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2024 Asterios Dramis <asterios.dramis@gmail.com>.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.


Name:           catdoc
Version:        0.95
Release:        0
Summary:        Convert Microsoft Office Files to Plain Text
License:        GPL-2.0-or-later
Group:          Productivity/Publishing/Other
URL:            https://www.wagner.pp.ru/~vitus/software/catdoc/
Source0:        http://ftp.wagner.pp.ru/pub/catdoc/%{name}-%{version}.tar.gz
# PATCH-FIX-OPENSUSE CVE-2017-11110.patch bsc#1047877 CVE-2017-11110 astieger@suse.com -- Fix for CVE-2017-11110
Patch0:         CVE-2017-11110.patch
BuildRequires:  tk
Recommends:     catdoc-xls2csv

%description
catdoc is a program which reads one or more Microsoft word files and outputs
text, contained insinde them to standard output. It is accompanied by catppt
utility to extract textual information from Powerpoint files.

%package xls2csv
Summary:        Convert Microsoft Excel Files to Plain Text
Group:          Productivity/Publishing/Other
Requires:       catdoc = %{version}
Conflicts:      libxls-tools
Conflicts:      xls2csv

%description xls2csv
xls2csv is a program which converts Excel spreadsheet into comma-separated
value file.

%prep
%autosetup -p1

# Fix rpmlint warning "wrong-file-end-of-line-encoding"
sed -i 's/\r$//' TODO

%build
%configure
%make_build

%install
install -dp -m 0755 %{buildroot}%{_mandir}/man1
%make_install installroot=%{buildroot}

%files
%license COPYING
%doc NEWS README TODO
%{_bindir}/catdoc
%{_bindir}/catppt
%{_bindir}/wordview
%{_datadir}/catdoc/
%{_mandir}/man1/catdoc.1%{?ext_man}
%{_mandir}/man1/catppt.1%{?ext_man}
%{_mandir}/man1/wordview.1%{?ext_man}

%files xls2csv
%license COPYING
%{_bindir}/xls2csv
%{_mandir}/man1/xls2csv.1%{?ext_man}

%changelog
openSUSE Build Service is sponsored by