Files
libmobi/libmobi.spec
Luigi Baldoni 2061409424 Accepting request 1186144 from home:alois:branches:devel:libraries:c_c++
- Update to version 0.12
  * Fix some build issues:
    + build with libxml >= 2.12
    + clang warnings
  * Minor fix: potential undefined behavior on corrupt input
  * Code cleanup
  version 0.11:
  * fixed multiple buffer over-reads and null pointer
    dereferences that can be triggered with crafted input. The
    security impact of these bugs is low, they can cause crashes.
    These bugs were identified by extensive fuzzing by various
    researchers.
    Some of these vulnerabilities have been assigned CVEs:
    CVE-2022-1533, CVE-2022-1534, CVE-2022-1907, CVE-2022-1908,
    CVE-2022-1987, CVE-2022-2279, CVE-2022-29788.
  * fixed potential leak in dictionary parsing on corrupt data
  * improved portability of encryption key generation
  version 0.10:
  * adds functions to allow encryption of documents
  * improves decryption routines
  * adds new tool mobidrm that handles documents encryption and
    decryption
  Other changes:
  * adds function to split hybrid files
  * adds helper functions for retrieving orthographic index
    entries
  * adds basic CMake support
  * small fixes in autotools project

OBS-URL: https://build.opensuse.org/request/show/1186144
OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/libmobi?expand=0&rev=2
2024-07-08 11:03:33 +00:00

119 lines
3.4 KiB
RPMSpec

#
# spec file for package libmobi
#
# Copyright (c) 2024 SUSE LLC
#
# 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.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define sover 0
Name: libmobi
Version: 0.12
Release: 0
Summary: Library for handling Kindle (MOBI) formats of ebook documents
License: LGPL-3.0-or-later
URL: https://github.com/bfabiszewski/libmobi
Source0: https://github.com/bfabiszewski/libmobi/archive/refs/tags/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires: automake
BuildRequires: libtool
BuildRequires: rpm >= 4.12
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: pkgconfig(zlib)
%description
Features:
* reading and parsing:
- some older text Palmdoc formats (pdb),
- Mobipocket files (prc, mobi),
- newer MOBI files including KF8 format (azw, azw3),
- Replica Print files (azw4)
* recreating source files using indices
* reconstructing references (links and embedded) in html files
* reconstructing source structure that can be fed back to kindlegen
* reconstructing dictionary markup (orth, infl tags)
* writing back loaded documents
* metadata editing
* handling encrypted documents
%package -n %{name}%{sover}
Summary: Library for handling Kindle (MOBI) formats of ebook documents
%description -n %{name}%{sover}
Features:
* reading and parsing:
- some older text Palmdoc formats (pdb),
- Mobipocket files (prc, mobi),
- newer MOBI files including KF8 format (azw, azw3),
- Replica Print files (azw4)
* recreating source files using indices
* reconstructing references (links and embedded) in html files
* reconstructing source structure that can be fed back to kindlegen
* reconstructing dictionary markup (orth, infl tags)
* writing back loaded documents
* metadata editing
* handling encrypted documents
%package tools
Summary: CLI tools for libmobi
%description tools
This package contains the CLI tools for libmobi.
%package devel
Summary: Development files for %{name}%{sover}
Requires: %{name}%{sover} = %{version}
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.
%prep
%autosetup -p1
%build
autoreconf -vfi
%configure \
--disable-static \
--enable-encryption \
--with-libxml2 \
--with-zlib
%make_build
%install
%make_install
find %{buildroot} -type f -name "*.la" -delete -print
%post -n %{name}%{sover} -p /sbin/ldconfig
%postun -n %{name}%{sover} -p /sbin/ldconfig
%files -n %{name}%{sover}
%license COPYING
%{_libdir}/%{name}.so.%{sover}
%{_libdir}/%{name}.so.%{sover}.*
%files tools
%{_bindir}/mobidrm
%{_bindir}/mobimeta
%{_bindir}/mobitool
%{_mandir}/man1/mobidrm.1%{?ext_man}
%{_mandir}/man1/mobimeta.1%{?ext_man}
%{_mandir}/man1/mobitool.1%{?ext_man}
%files devel
%{_includedir}/mobi.h
%{_libdir}/%{name}.so
%{_libdir}/pkgconfig/%{name}.pc
%changelog