fix shebangs for python 3.10; add more -py310 requirements [release 5.43.0-2mamba;Sat Jun 11 2022]

This commit is contained in:
Silvan Calarco 2024-01-05 21:05:20 +01:00
parent 43ed981aba
commit 1010f583c9

View File

@ -1,11 +1,11 @@
Name: calibre
Version: 5.22.1
Version: 5.43.0
Release: 2mamba
Summary: A free and open source e-book library management application
Group: Graphical Desktop/Applications/Multimedia
Vendor: openmamba
Distribution: openmamba
Packager: Ercole 'ercolinux' Carpanetto <ercole69@gmail.com>
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://calibre-ebook.com
Source: https://github.com/kovidgoyal/calibre.git/v%{version}/calibre-%{version}.tar.bz2
Source1: calibre.desktop
@ -30,70 +30,51 @@ BuildRequires: libicu-devel
BuildRequires: libmtp-devel
BuildRequires: libopenssl-devel
BuildRequires: libpodofo-devel
BuildRequires: libpython3-devel
BuildRequires: libqt5-devel
BuildRequires: libpython310-devel
BuildRequires: libstdc++6-devel
BuildRequires: libstemmer-devel
BuildRequires: libusb-devel
BuildRequires: libz-devel
BuildRequires: qt5-qtbase-devel
## AUTOBUILDREQ-END
BuildRequires: libpython3-devel
BuildRequires: libpython310-devel
BuildRequires: libpodofo-devel >= 0.9.3
BuildRequires: libwmf-devel
#BuildRequires: BeautifulSoup
#BuildRequires: dnspython
BuildRequires: python-apsw-py3
BuildRequires: python-beautifulsoup4-py3
#BuildRequires: python-cssutils
BuildRequires: python-cssselect-py3
BuildRequires: python-css-parser-py3
BuildRequires: python-dateutil-py3
#BuildRequires: python-dukpy
BuildRequires: python-feedparser-py3
BuildRequires: python-html5lib-py3
BuildRequires: python-html5-parser-py3
BuildRequires: python-lxml-py3
BuildRequires: python-mechanize-py3
BuildRequires: python-msgpack-py3
BuildRequires: python-ordereddict-py3
BuildRequires: python-regex-py3
BuildRequires: python-sip-py3
BuildRequires: python-six-py3
BuildRequires: python-soupsieve-py3
BuildRequires: python-webencodings-py3
#BuildRequires: pyicu
BuildRequires: python-apsw-py310
BuildRequires: python-beautifulsoup4-py310
BuildRequires: python-css-parser-py310
BuildRequires: python-dateutil-py310
BuildRequires: python-html5lib-py310
BuildRequires: python-html5-parser-py310
BuildRequires: python-lxml-py310
BuildRequires: python-mechanize-py310
BuildRequires: python-msgpack-py310
BuildRequires: python-regex-py310
BuildRequires: python-sip-py310
BuildRequires: python-six-py310
BuildRequires: python-soupsieve-py310
BuildRequires: python-webencodings-py310
BuildRequires: PyQt5-devel
BuildRequires: PyQt5-py3
BuildRequires: pyqtwebengine-py3
BuildRequires: PyQt-builder-py3
BuildRequires: python-zeroconf-py3
BuildRequires: python-ifaddr-py3
BuildRequires: PyQt5-py310
BuildRequires: pyqtwebengine-py310
BuildRequires: PyQt-builder-py310
Requires: PyQt5-py3 >= 5.15.2
Requires: pyqtwebengine-py3 >= 5.13.0
Requires: python3 >= %python3_version
#Requires: BeautifulSoup
#Requires: pyicu
Requires: python-apsw-py3
Requires: python-beautifulsoup4-py3
#Requires: python-chardet
Requires: python-cssselect-py3
#Requires: python-cssutils-py3
Requires: python-css-parser-py3
Requires: python-dateutil-py3
#Requires: python-dukpy
Requires: python-feedparser-py3
Requires: python-html5lib-py3
Requires: python-html5-parser-py3
Requires: python-ifaddr-py3
Requires: python-lxml-py3
Requires: python-mechanize-py3
Requires: python-msgpack-py3
Requires: python-netifaces-py3
Requires: python-regex-py3
Requires: python-six-py3
Requires: python-soupsieve-py3
Requires: python-webencodings-py3
Requires: python-zeroconf-py3
Requires: pyqtwebengine-py310 >= 5.13.0
Requires: python310
Requires: python-apsw-py310
Requires: python-beautifulsoup4-py310
Requires: python-css-parser-py310
Requires: python-dateutil-py310
Requires: python-html5lib-py310
Requires: python-html5-parser-py310
Requires: python-lxml-py310
Requires: python-mechanize-py310
Requires: python-msgpack-py310
Requires: python-Pillow-py310
Requires: python-regex-py310
Requires: python-six-py310
Requires: python-soupsieve-py310
Requires: python-webencodings-py310
Requires: liberation-fonts-ttf
%description
@ -103,9 +84,8 @@ calibre is a free and open source e-book library management application develope
%setup -q
#-D -T
#:<< _EOF
#%patch4 -p1
%patch5 -p1
%patch6 -p1
#%patch5 -p1
#%patch6 -p1
# Use uppercase naming scheme, don't delete config files under fakeroot.
sed -e "/import config_dir/,/os.rmdir(config_dir)/d" \
-e "s/'ctc-posml'/'text' not in mt and 'pdf' not in mt and 'xhtml'/" \
@ -118,23 +98,25 @@ sed -e "/import config_dir/,/os.rmdir(config_dir)/d" \
export QTWEBENGINE_DISABLE_SANDBOX=1
%endif
CFLAGS="%{optflags}" %{__python3} setup.py bootstrap
LANG='en_US.UTF-8' %{__python3} setup.py build
LANG='en_US.UTF-8' %{__python3} setup.py gui
%{__python3} setup.py liberation_fonts --path-to-liberation_fonts /usr/share/fonts/liberation --system-liberation_fonts
LANG='en_US.UTF-8' %{__python3} setup.py resources
LANG='en_US.UTF-8' %{__python3} setup.py rapydscript
CFLAGS="%{optflags}" %{__python310} setup.py bootstrap
LANG='en_US.UTF-8' %{__python310} setup.py build
LANG='en_US.UTF-8' %{__python310} setup.py gui
%{__python310} setup.py liberation_fonts --path-to-liberation_fonts /usr/share/fonts/liberation --system-liberation_fonts
LANG='en_US.UTF-8' %{__python310} setup.py resources
LANG='en_US.UTF-8' %{__python310} setup.py rapydscript
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
# If this directory doesn't exist, zsh completion won't install.
install -d %{buildroot}%{_datadir}/zsh/site-functions
%{__python3} setup.py install \
%{__python310} setup.py install \
--root=%{buildroot}/usr \
--staging-libdir=%{buildroot}%{_libdir} \
--libdir=%{_libdir}
sed -i "s|bin/env python3$|bin/env python3.10|" %{buildroot}%{_bindir}/*
%files
%defattr(-,root,root)
%{_bindir}/calibre
@ -152,60 +134,7 @@ install -d %{buildroot}%{_datadir}/zsh/site-functions
%{_datadir}/mime/packages/calibre-mimetypes.xml
%{_datadir}/bash-completion/completions/*
%dir %{_libdir}/calibre
#%dir %{_libdir}/calibre/backports
#%{_libdir}/calibre/backports/*
#%dir %{_libdir}/calibre/biplist
#%{_libdir}/calibre/biplist/*
%dir %{_libdir}/calibre/calibre
%{_libdir}/calibre/calibre/*.py
%dir %{_libdir}/calibre/calibre/db
%{_libdir}/calibre/calibre/db/*
%dir %{_libdir}/calibre/calibre/customize
%{_libdir}/calibre/calibre/customize/*.py
%dir %{_libdir}/calibre/calibre/devices
%{_libdir}/calibre/calibre/devices/*
%dir %{_libdir}/calibre/calibre/ebooks
%{_libdir}/calibre/calibre/ebooks/*
%dir %{_libdir}/calibre/calibre/gui2
%{_libdir}/calibre/calibre/gui2/*
%dir %{_libdir}/calibre/calibre/library
%{_libdir}/calibre/calibre/library/*
%dir %{_libdir}/calibre/calibre/plugins
#%dir %{_libdir}/calibre/calibre/plugins/3
#%{_libdir}/calibre/calibre/plugins/3/*
%dir %{_libdir}/calibre/calibre/srv
%{_libdir}/calibre/calibre/srv/*.py
%dir %{_libdir}/calibre/calibre/srv/tests
%{_libdir}/calibre/calibre/srv/tests/*.py
#%dir %{_libdir}/calibre/calibre_lzma
#%{_libdir}/calibre/calibre_lzma/*
%dir %{_libdir}/calibre/calibre/plugins
%{_libdir}/calibre/calibre/plugins/*.so
%dir %{_libdir}/calibre/calibre/spell
%{_libdir}/calibre/calibre/spell/*.py
%dir %{_libdir}/calibre/calibre/translations
%{_libdir}/calibre/calibre/translations/*.py
%dir %{_libdir}/calibre/calibre/utils
%{_libdir}/calibre/calibre/utils/*
%dir %{_libdir}/calibre/calibre/web
%{_libdir}/calibre/calibre/web/*
%dir %{_libdir}/calibre/css_selectors
%{_libdir}/calibre/css_selectors/*
#%dir %{_libdir}/calibre/duktape
#%{_libdir}/calibre/duktape/*
%dir %{_libdir}/calibre/odf
%{_libdir}/calibre/odf/*.py
%dir %{_libdir}/calibre/polyglot
%{_libdir}/calibre/polyglot/*
%dir %{_libdir}/calibre/qt
%{_libdir}/calibre/qt/*
%dir %{_libdir}/calibre/templite
%{_libdir}/calibre/templite/*.py
%dir %{_libdir}/calibre/tinycss/
%{_libdir}/calibre/tinycss/*.py
%dir %{_libdir}/calibre/tinycss/tests
%{_libdir}/calibre/tinycss/tests/*.py
%{_libdir}/calibre/sgmllib.py
%{_libdir}/calibre/*
%dir %{_datadir}/calibre
%{_datadir}/calibre/*
%{_datadir}/zsh/site-functions/_calibre
@ -213,9 +142,15 @@ install -d %{buildroot}%{_datadir}/zsh/site-functions
%{_datadir}/icons/hicolor/*/mimetypes/application-*.png
%{_datadir}/icons/hicolor/*/mimetypes/gnome-mime-*.png
%{_datadir}/icons/hicolor/*/mimetypes/text-lrs.png
%{python3_sitelib}/init_calibre.py
%{python310_sitearch}/init_calibre.py
%changelog
* Sat Jun 11 2022 Silvan Calarco <silvan.calarco@mambasoft.it> 5.43.0-2mamba
- fix shebangs for python 3.10; add more -py310 requirements
* Fri Jun 03 2022 Automatic Build System <autodist@mambasoft.it> 5.43.0-1mamba
- automatic version update by autodist
* Tue Oct 05 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 5.22.1-2mamba
- added patch against python-zeroconf 0.36.7