gnu: calibre: Update to 5.36.0.

* gnu/packages/ebook.scm (calibre): Update to 5.36.0.
Remove no longer needed zeroconf patch.
[inputs]: Remove python-dbus, python-dukpy, python-pycryptodome. Add python-jeepney, libstemmer.
* gnu/packages/patches/calibre-fix-zeroconf.patch: Delete patch.
* gnu/local.mk: Remove reference to patch.

Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
This commit is contained in:
Brendan Tildesley 2022-02-19 00:08:05 +01:00 committed by Nicolas Goaziou
parent 7a06710717
commit 21fe2ad405
No known key found for this signature in database
GPG key ID: DA00B4F048E92F2D
3 changed files with 6 additions and 46 deletions

View file

@ -921,7 +921,6 @@ dist_patch_DATA = \
%D%/packages/patches/cabal-install-ghc8.10.patch \
%D%/packages/patches/cairo-CVE-2018-19876.patch \
%D%/packages/patches/cairo-CVE-2020-35492.patch \
%D%/packages/patches/calibre-fix-zeroconf.patch \
%D%/packages/patches/calibre-no-updates-dialog.patch \
%D%/packages/patches/calibre-remove-test-sqlite.patch \
%D%/packages/patches/calibre-remove-test-unrar.patch \

View file

@ -57,6 +57,7 @@ (define-module (gnu packages ebook)
#:use-module (gnu packages icu4c)
#:use-module (gnu packages image)
#:use-module (gnu packages javascript)
#:use-module (gnu packages language)
#:use-module (gnu packages libusb)
#:use-module (gnu packages libreoffice)
#:use-module (gnu packages music)
@ -121,7 +122,7 @@ (define-public python-pychm
(define-public calibre
(package
(name "calibre")
(version "5.21.0")
(version "5.36.0")
(source
(origin
(method url-fetch)
@ -130,7 +131,7 @@ (define-public calibre
version ".tar.xz"))
(sha256
(base32
"0mq2w8blq6ykaml812axakwkqcw85qcpfwijdikn7kvbrhnnp2s5"))
"1c036qmn7lxq0899c2xzzs6whz7z0557frnfqisbvfxa13b2sadk"))
(modules '((guix build utils)))
(snippet
'(begin
@ -146,8 +147,7 @@ (define-public calibre
(delete-file "resources/calibre-portable.bat")
(delete-file "resources/calibre-portable.sh")
#t))
(patches (search-patches "calibre-fix-zeroconf.patch"
"calibre-no-updates-dialog.patch"
(patches (search-patches "calibre-no-updates-dialog.patch"
"calibre-remove-test-sqlite.patch" ; TODO: fix test.
"calibre-remove-test-unrar.patch"))))
(build-system python-build-system)
@ -168,6 +168,7 @@ (define-public calibre
("libpng" ,libpng)
("libjpeg" ,libjpeg-turbo)
("libjxr" ,libjxr)
("libstemmer" ,libstemmer)
("libusb" ,libusb)
("openssl" ,openssl)
("optipng" ,optipng)
@ -179,13 +180,12 @@ (define-public calibre
("python-css-parser" ,python-css-parser)
("python-cssselect" ,python-cssselect)
("python-dateutil" ,python-dateutil)
("python-dbus" ,python-dbus)
("python-dnspython" ,python-dnspython-1.16)
("python-dukpy" ,python-dukpy)
("python-feedparser" ,python-feedparser)
("python-html2text" ,python-html2text)
("python-html5-parser" ,python-html5-parser)
("python-html5lib" ,python-html5lib)
("python-jeepney" ,python-jeepney)
("python-lxml" ,python-lxml)
("python-markdown" ,python-markdown)
("python-mechanize" ,python-mechanize)
@ -197,7 +197,6 @@ (define-public calibre
("python-psutil" ,python-psutil)
("python-py7zr" ,python-py7zr)
("python-pychm" ,python-pychm)
("python-pycryptodome" ,python-pycryptodome)
("python-pygments" ,python-pygments)
("python-pyqt-without-qtwebkit" ,python-pyqt-without-qtwebkit)
("python-pyqtwebengine" ,python-pyqtwebengine)

View file

@ -1,38 +0,0 @@
Fix a build failure when upgrading zeroconf from 0.28.8 to 0.38.1:
https://issues.guix.gnu.org/53247
Patch copied from Gentoo:
https://bugs.gentoo.org/800233#c5
diff --color -Naru a/src/calibre/devices/smart_device_app/driver.py b/src/calibre/devices/smart_device_app/driver.py
--- a/src/calibre/devices/smart_device_app/driver.py 2021-08-08 08:32:03.104016444 +0200
+++ b/src/calibre/devices/smart_device_app/driver.py 2021-08-08 08:33:30.699018403 +0200
@@ -2040,13 +2040,6 @@
# Function to monkeypatch zeroconf to remove the 15 character name length restriction.
# Copied from https://github.com/jstasiak/python-zeroconf version 0.28.1
-
-from zeroconf import (BadTypeInNameException, _HAS_A_TO_Z,
- _HAS_ONLY_A_TO_Z_NUM_HYPHEN_UNDERSCORE,
- _HAS_ASCII_CONTROL_CHARS,
- _HAS_ONLY_A_TO_Z_NUM_HYPHEN)
-
-
def service_type_name(type_: str, *, allow_underscores: bool = False) -> str:
"""
Validate a fully qualified service name, instance or subtype. [rfc6763]
@@ -2087,6 +2080,12 @@
:param type_: Type, SubType or service name to validate
:return: fully qualified service name (eg: _http._tcp.local.)
"""
+
+ from zeroconf import (BadTypeInNameException, _HAS_A_TO_Z,
+ _HAS_ONLY_A_TO_Z_NUM_HYPHEN_UNDERSCORE,
+ _HAS_ASCII_CONTROL_CHARS,
+ _HAS_ONLY_A_TO_Z_NUM_HYPHEN)
+
if not (type_.endswith('._tcp.local.') or type_.endswith('._udp.local.')):
raise BadTypeInNameException("Type '%s' must end with '._tcp.local.' or '._udp.local.'" % type_)