58602c
%global apiversion 0.0
58602c
58602c
Name: libstaroffice
58602c
Version: 0.0.7
58602c
Release: 5%{?dist}
58602c
Summary: A library for import of binary StarOffice documents
58602c
58602c
License: MPLv2.0 or LGPLv2+
58602c
URL: https://github.com/fosnola/libstaroffice/wiki
58602c
Source: https://github.com/fosnola/%{name}/releases/download/%{version}/%{name}-%{version}.tar.xz
58602c
58602c
BuildRequires: doxygen
58602c
BuildRequires: gcc-c++
58602c
BuildRequires: help2man
58602c
BuildRequires: pkgconfig(librevenge-0.0)
58602c
BuildRequires: pkgconfig(librevenge-generators-0.0)
58602c
BuildRequires: pkgconfig(librevenge-stream-0.0)
58602c
BuildRequires: pkgconfig(zlib)
58602c
BuildRequires: make
58602c
58602c
%description
58602c
%{name} is a library for import of binary StarOffice documents.
58602c
58602c
%package devel
58602c
Summary: Development files for %{name}
58602c
Requires: %{name}%{?_isa} = %{version}-%{release}
58602c
58602c
%description devel
58602c
The %{name}-devel package contains libraries and header files for
58602c
developing applications that use %{name}.
58602c
58602c
%package doc
58602c
Summary: Documentation of %{name} API
58602c
BuildArch: noarch
58602c
58602c
%description doc
58602c
The %{name}-doc package contains documentation files for %{name}.
58602c
58602c
%package tools
58602c
Summary: Tools to transform StarOffice documents into other formats
58602c
Requires: %{name}%{?_isa} = %{version}-%{release}
58602c
58602c
%description tools
58602c
Tools to transform StarOffice documents into other formats. Currently
58602c
supported: CSV, HTML, plain text, SVG, raw.
58602c
58602c
%prep
58602c
%autosetup -p1
58602c
58602c
%build
58602c
%configure --disable-static --disable-silent-rules --enable-zip
58602c
sed -i \
58602c
    -e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' \
58602c
    -e 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' \
58602c
    libtool
58602c
make %{?_smp_mflags}
58602c
58602c
%install
58602c
%make_install
58602c
rm -f %{buildroot}/%{_libdir}/*.la
58602c
# rhbz#1001245 we install API docs directly from build
58602c
rm -rf %{buildroot}/%{_docdir}/%{name}
58602c
58602c
# generate and install man pages
58602c
export LD_LIBRARY_PATH=%{buildroot}/%{_libdir}${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
58602c
for tool in sd2raw sd2svg sd2text sdc2csv sdw2html; do
58602c
    help2man -N -S '%{name} %{version}' -o ${tool}.1 %{buildroot}%{_bindir}/${tool}
58602c
done
58602c
install -m 0755 -d %{buildroot}/%{_mandir}/man1
58602c
install -m 0644 sd2*.1 sd?2*.1 %{buildroot}/%{_mandir}/man1
58602c
58602c
%ldconfig_scriptlets
58602c
58602c
%files
58602c
%doc CREDITS NEWS README
58602c
%license COPYING.LGPL COPYING.MPL
58602c
%{_libdir}/%{name}-%{apiversion}.so.*
58602c
58602c
%files devel
58602c
%doc ChangeLog
58602c
%{_includedir}/%{name}-%{apiversion}
58602c
%{_libdir}/%{name}-%{apiversion}.so
58602c
%{_libdir}/pkgconfig/%{name}-%{apiversion}.pc
58602c
58602c
%files doc
58602c
%license COPYING.LGPL COPYING.MPL
58602c
%doc docs/doxygen/html
58602c
58602c
%files tools
58602c
%{_bindir}/sdw2html
58602c
%{_bindir}/sd2raw
58602c
%{_bindir}/sd2svg
58602c
%{_bindir}/sd2text
58602c
%{_bindir}/sdc2csv
58602c
%{_mandir}/man1/sdw2html.1*
58602c
%{_mandir}/man1/sd2raw.1*
58602c
%{_mandir}/man1/sd2svg.1*
58602c
%{_mandir}/man1/sd2text.1*
58602c
%{_mandir}/man1/sdc2csv.1*
58602c
58602c
%changelog
58602c
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 0.0.7-5
58602c
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
58602c
  Related: rhbz#1991688
58602c
58602c
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 0.0.7-4
58602c
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
58602c
58602c
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.7-3
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
58602c
58602c
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.7-2
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
58602c
58602c
* Sun Apr 05 2020 David Tardon <dtardon@redhat.com> - 0.0.7-1
58602c
- new upstream release
58602c
58602c
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.6-5
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
58602c
58602c
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.6-4
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
58602c
58602c
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.6-3
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
58602c
58602c
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.6-2
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
58602c
58602c
* Thu Apr 26 2018 David Tardon <dtardon@redhat.com> - 0.0.6-1
58602c
- new upstream release
58602c
58602c
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.5-2
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
58602c
58602c
* Tue Nov 07 2017 David Tardon <dtardon@redhat.com> - 0.0.5-1
58602c
- new upstream release
58602c
58602c
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.4-3
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
58602c
58602c
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.4-2
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
58602c
58602c
* Sun Jul 16 2017 David Tardon <dtardon@redhat.com> - 0.0.4-1
58602c
- new upstream release
58602c
58602c
* Tue Jun 06 2017 David Tardon <dtardon@redhat.com> - 0.0.3-3
58602c
- Resolves: rhbz#1458800 CVE-2017-9432 Stack-buffer overflow in the
58602c
  StarWriterStruct::DatabaseName::read
58602c
58602c
* Mon May 15 2017 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.3-2
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_27_Mass_Rebuild
58602c
58602c
* Wed Feb 22 2017 David Tardon <dtardon@redhat.com> - 0.0.3-1
58602c
- new upstream release
58602c
58602c
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.2-2
58602c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
58602c
58602c
* Thu Aug 11 2016 David Tardon <dtardon@redhat.com> - 0.0.2-1
58602c
- new upstream release
58602c
58602c
* Thu Feb 11 2016 David Tardon <dtardon@redhat.com> - 0.0.1-1
58602c
- initial import