#6 Update to new upstream release 5.21.0 and fix build with sip5
Merged 2 years ago by kevin. Opened 2 years ago by swt2c.
rpms/ swt2c/calibre sip5  into  rawhide

file modified
+1
@@ -310,3 +310,4 @@ 

  /calibre-4.19.0.tar.xz

  /calibre-4.22.0.tar.xz

  /calibre-4.23.0.tar.xz

+ /calibre-5.22.1.tar.xz

file modified
+3 -3
@@ -7,14 +7,14 @@ 

   Icon=calibre-viewer

  +NoDisplay=true

   MimeType=application/x-sony-bbeb;

-  Categories=Graphics;Viewer;

+  Categories=Office;Viewer;

   '''

  @@ -948,6 +949,7 @@ Comment=Viewer for E-books in all the ma

   TryExec=ebook-viewer

   Exec=ebook-viewer --detach %f

   Icon=calibre-viewer

  +NoDisplay=true

-  Categories=Graphics;Viewer;

+  Categories=Office;Viewer;

   '''

   

  @@ -961,6 +963,7 @@ Comment=Edit e-books in various formats
@@ -22,6 +22,6 @@ 

   Exec=ebook-edit --detach %f

   Icon=calibre-ebook-edit

  +NoDisplay=true

-  Categories=Office;

+  Categories=Office;WordProcessor

   '''

   

file modified
+24 -7
@@ -1,12 +1,10 @@ 

- %{?_sip_api:Requires: python3-pyqt5-sip-api(%{_sip_api_major}) >= %{_sip_api}}

- 

  %global __provides_exclude_from ^%{_libdir}/calibre/calibre/plugins/.*\.so$

  

  %global _python_bytecompile_extra 0

  

  Name:           calibre

- Version:        4.23.0

- Release:        7%{?dist}

+ Version:        5.22.1

+ Release:        1%{?dist}

  Summary:        E-book converter and library manager

  License:        GPLv3

  URL:            https://calibre-ebook.com/
@@ -70,10 +68,18 @@ 

  BuildRequires:  python3dist(html2text)

  BuildRequires:  python3dist(zeroconf)

  BuildRequires:  python3dist(markdown) >= 3.0

+ BuildRequires:  python3dist(sip) >= 5.5

+ BuildRequires:  python3dist(pyqt-builder)

+ BuildRequires:  python3dist(pychm)

+ BuildRequires:  python3dist(pycrypto)

+ BuildRequires:  python3dist(cchardet)

+ BuildRequires:  python3-speechd

  BuildRequires:  hunspell-devel

  BuildRequires:  qt5-qtwebengine-devel

  BuildRequires:  python-qt5-webengine

  BuildRequires:  hyphen-devel

+ BuildRequires:  qt5-qtimageformats

+ BuildRequires:  libstemmer-devel

  # using the bundled mathjax until Fedora updates to 3.0.0

  #BuildRequires:  mathjax

  # Those are only used for tests. Do not add to runtime deps.
@@ -95,6 +101,7 @@ 

  Requires:       qt5-qtwebengine

  Requires:       qt5-qtsvg

  Requires:       qt5-qtsensors

+ Requires:       qt5-qtimageformats

  Requires:       poppler-utils

  Requires:       liberation-sans-fonts

  Requires:       liberation-serif-fonts
@@ -121,7 +128,12 @@ 

  Requires:       python3dist(html5-parser) >= 0.4.8

  Requires:       python3dist(html2text)

  Requires:       python3dist(markdown) >= 3.0

+ Requires:       python3dist(pychm)

+ Requires:       python3dist(cchardet)

+ Requires:       python3dist(pyqt5-sip) >= 12.8, python3dist(pyqt5-sip) < 13

  Requires:       udisks2

+ Requires:       /usr/bin/jpegtran

+ Requires:       /usr/bin/JxrDecApp

  Recommends:     python3dist(zeroconf)

  

  %description
@@ -289,16 +301,18 @@ 

  # skip failing tests:

  # - unrar (missing dependencies)

  # - bonjour (problems in mock)

+ # - 7z (missing dependencies)

  # - qt (fails on 32-bit architectures only)

  CALIBRE_PY3_PORT=1 \

  %{__python3} setup.py test \

      --exclude-test-name unrar \

      --exclude-test-name bonjour \

+     --exclude-test-name 7z \

  %ifarch i686 armv7hl

      --exclude-test-name qt

  %endif

  

- appstream-util validate-relax --nonet %{buildroot}%{_datadir}/metainfo/calibre-gui.appdata.xml

+ appstream-util validate-relax --nonet %{buildroot}%{_datadir}/metainfo/calibre-gui.metainfo.xml

  

  %preun

  if [ -L %{_datadir}/calibre/mathjax ]; then
@@ -310,7 +324,7 @@ 

  

  %files

  %license LICENSE

- %doc Changelog.yaml COPYRIGHT README.md

+ %doc Changelog.txt COPYRIGHT README.md

  %{_bindir}/calibre

  %{_bindir}/calibre-complete

  %{_bindir}/calibre-customize
@@ -342,9 +356,12 @@ 

  %{python3_sitelib}/__pycache__/init_calibre.*.py*

  %{_datadir}/bash-completion/completions

  %{_datadir}/zsh/site-functions/_calibre

- %{_datadir}/metainfo/*.appdata.xml

+ %{_datadir}/metainfo/*.metainfo.xml

  

  %changelog

+ * Thu Jun 10 2021 Scott Talbert <swt@techie.net> - 5.22.1-1

+ - Update to new upstream release 5.22.1 and fix build with sip5

+ 

  * Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 4.23.0-7

  - Rebuilt for Python 3.10

  

file modified
+1 -1
@@ -1,1 +1,1 @@ 

- SHA512 (calibre-4.23.0.tar.xz) = 2a512f29ddc2fed7f6a229314a9f7fceac198c9422b3be19078685032f1d1cb3b9258ac2609c33d15da20683c1277ed09419ea1e9bbc70430cdc676f60395719

+ SHA512 (calibre-5.22.1.tar.xz) = a81b84b69194bf2935743c839368fd51eb4a0453d147a0ac9e52b026f72a648cd5c258a7e426f6c544c04d920b7746a4aa3c1d42b996b76d12ad28ab957b9ff4

Please DON'T MERGE but do provide comments/approval. This is part of a coordinated move to sip5 in F35+.

Looks good to me! Many thanks for working on this!

Cool. BTW, this gets Calibre building with SIP5 and Python 3.10. There are still some runtime issues with Python 3.10. (I sent the Python 3.10 building patch upstream.)

Yeah, thanks for doing this.

Hum. Tried the version from copr, but it tracebacks on start:

calibre, version 5.21.0
ERROR: Startup error: There was an error during calibre startup. Parts of calibre may not function. Click "Show details" to learn more.

Traceback (most recent call last):
  File "/usr/lib64/calibre/calibre/gui2/main.py", line 312, in initialize_db_stage2
    self.start_gui(db)
  File "/usr/lib64/calibre/calibre/gui2/main.py", line 256, in start_gui
    main.initialize(self.library_path, db, self.actions)
  File "/usr/lib64/calibre/calibre/gui2/ui.py", line 227, in initialize
    MainWindowMixin.init_main_window_mixin(self, db)
  File "/usr/lib64/calibre/calibre/gui2/layout.py", line 348, in init_main_window_mixin
    self.bars_manager = BarsManager(self.donate_action,
  File "/usr/lib64/calibre/calibre/gui2/bars.py", line 641, in __init__
    self.init_bars()
  File "/usr/lib64/calibre/calibre/gui2/bars.py", line 673, in init_bars
    bar.init_bar(actions)
  File "/usr/lib64/calibre/calibre/gui2/bars.py", line 202, in init_bar
    self.donate_button = create_donate_button(self.donate_action)
  File "/usr/lib64/calibre/calibre/gui2/bars.py", line 118, in create_donate_button
    ans = ThrobbingButton()
  File "/usr/lib64/calibre/calibre/gui2/throbber.py", line 35, in __init__
    self.animation.setDuration(60/72.*1000)
TypeError: setDuration(self, int): argument 1 has unexpected type 'float'

Yep, like I mentioned earlier, there are additional Python 3.10 issues.

Okay, I fixed that traceback above (another Python 3.10 issue). Now, calibre starts but then just exists without an sort of error. Do you see the same issue? Any idea how to debug further?

rebased onto 03120d0

2 years ago

rebased onto bc77077

2 years ago

Okay, try again now, fixed some more Python 3.10 issues. :-)

rebased onto ae0e73e

2 years ago

Much better. Seems to work in casual testing...

rebased onto 4d16a20

2 years ago

Updated to 5.22.1 which has all my Python 3.10 fixes incorporated.

Also, for the latest, python-apsw needs to be built in rawhide. The maintainer merged my fixes, but didn't do a build. It's needed for all the tests to pass.

Building in f35-build-side-43327

Pull-Request has been merged by kevin

2 years ago

ah, building that and will re-do this...