From 8b3a37960de7ddfad7541971d34d669330fcd113 Mon Sep 17 00:00:00 2001 From: FriedrichFroebel Date: Fri, 13 Dec 2024 17:07:16 +0100 Subject: [PATCH] replace unmaintained python-djvulibre with djvulibre-python --- .github/workflows/ci.yml | 40 +--------------------------------------- doc/README | 14 +++----------- doc/changelog | 7 +++++++ setup.py | 2 +- 4 files changed, 12 insertions(+), 51 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0c73df7c..95bf26b4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,23 +9,7 @@ jobs: main: strategy: matrix: - include: - - python: '3.9' - djvulibre: legacy - - python: '3.10' - djvulibre: legacy - - python: '3.11' - djvulibre: legacy - - python: '3.9' - djvulibre: latest - - python: '3.10' - djvulibre: latest - - python: '3.11' - djvulibre: latest - - python: '3.12' - djvulibre: latest - - python: '3.13' - djvulibre: latest + python: ['3.9', '3.10', '3.11', '3.12', '3.13'] runs-on: ubuntu-latest name: Python ${{ matrix.python }} with djvulibre ${{ matrix.djvulibre }} steps: @@ -61,28 +45,6 @@ jobs: - name: install wheel run: python -m pip install --upgrade wheel - # Cython 3.0 broke the old code. - - name: install djvulibre legacy - run: | - python -m pip install "cython<3" - mkdir -p deps/ - python -m pip download --dest deps --no-binary python-djvulibre --no-deps python-djvulibre - cd deps - mkdir -p python-djvulibre/ - tar -xvzf python-djvulibre-* --strip-components=1 -C python-djvulibre - cd python-djvulibre - python setup.py install - if: ${{ matrix.djvulibre == 'legacy' }} - - name: install djuvlibre master - run: | - url="https://github.com/FriedrichFroebel/python-djvulibre/archive/python3.tar.gz" - mkdir -p deps/ - wget "$url" -O deps/python-djvulibre.tar.gz - cd deps - tar -xvzf python-djvulibre.tar.gz - cd python-djvulibre-python3/ - python -m pip install . - if: ${{ matrix.djvulibre != 'legacy' }} - name: install package run: python -m pip install .[dev,docs] diff --git a/doc/README b/doc/README index acfd126b..662228bd 100644 --- a/doc/README +++ b/doc/README @@ -48,13 +48,9 @@ The following software is required to run ocrodjvu: + GOCR_ ≥ 0.40 + Tesseract_ ≥ 2.00 -* DjVuLibre_ ≥ 3.5.21 (≥ 3.5.26 for latest python-djvulibre) +* DjVuLibre_ ≥ 3.5.26 -* python-djvulibre_ ≥ 0.4 - - + Please note that installing this package currently is a bit more complicated since Cython 3 has been relased on 2023-07-17. - + While `Issue #11`_ is unresolved, PyPI releases require some workarounds (installing the package from the source archive with the deprecated ``python setup.py install`` beforehand). - + Alternative: Install the latest package version from `Git `_. +* djvulibre-python_ ≥ 0.9 * lxml_ ≥ 2.0 @@ -85,11 +81,7 @@ The following software is required to rebuild the manual pages from source: https://github.com/tesseract-ocr/tesseract .. _DjVuLibre: http://djvu.sourceforge.net/ -.. _python-djvulibre: - https://jwilk.net/software/python-djvulibre -.. _Issue #11: - https://github.com/FriedrichFroebel/python-djvulibre/issues/11 -.. _python-djvulibre-git: +.. _djvulibre-python: https://github.com/FriedrichFroebel/python-djvulibre .. _lxml: https://lxml.de/ diff --git a/doc/changelog b/doc/changelog index f19a895c..f1d69297 100644 --- a/doc/changelog +++ b/doc/changelog @@ -1,3 +1,10 @@ +ocrodjvu (0.14) unstable; urgency=low + + [ FriedrichFroebel ] + * Replace unmaintained python-djvulibre with djvulibre-python fork. + + -- FriedrichFroebel <> Fri, 13 Dec 2024 15:25:00 +0100 + ocrodjvu (0.13.2) unstable; urgency=low [ FriedrichFroebel ] diff --git a/setup.py b/setup.py index 3bc8b304..add27e91 100644 --- a/setup.py +++ b/setup.py @@ -42,7 +42,7 @@ def get_version(): include_package_data=True, python_requires=">=3.6, <4", install_requires=[ - 'python-djvulibre>=0.4', + 'djvulibre-python>=0.9', 'lxml>=2.0', ], extras_require={