forked from pool/python-tesserocr
Accepting request 1072758 from devel:languages:python
- Update to 2.6.0 * _pix_to_image now works with binary images gh#sirfz/tesserocr#274 * SetImage with alpha channels support gh#sirfz/tesserocr#280 * Leptonica 1.83.0 support gh#sirfz/tesserocr#306 * Pointsize should be returned even if fontname doesn't exist gh#sirfz/tesserocr#308 * Added Python 3.10, 3.11 setup classifiers - Drop 1441bec703cf68161acce5e85907ddd71c47fdc3.patch OBS-URL: https://build.opensuse.org/request/show/1072758 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tesserocr?expand=0&rev=15
This commit is contained in:
@@ -1,31 +0,0 @@
|
|||||||
From 1441bec703cf68161acce5e85907ddd71c47fdc3 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Stefan Weil <sw@weilnetz.de>
|
|
||||||
Date: Mon, 18 Jul 2022 08:09:15 +0200
|
|
||||||
Subject: [PATCH] Add support for upcoming Leptonica 1.83.0
|
|
||||||
|
|
||||||
Signed-off-by: Stefan Weil <sw@weilnetz.de>
|
|
||||||
---
|
|
||||||
tesseract5.pxd | 10 ++++++++++
|
|
||||||
1 file changed, 10 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/tesseract5.pxd b/tesseract5.pxd
|
|
||||||
index 21ad667..aa7e52d 100644
|
|
||||||
--- a/tesseract5.pxd
|
|
||||||
+++ b/tesseract5.pxd
|
|
||||||
@@ -54,6 +54,16 @@ cdef extern from "leptonica/allheaders.h" nogil:
|
|
||||||
L_SEVERITY_ERROR = 5 # Print error and higher messages
|
|
||||||
L_SEVERITY_NONE = 6 # Highest severity: print no messages
|
|
||||||
|
|
||||||
+cdef extern from *:
|
|
||||||
+ """
|
|
||||||
+ #if (LIBLEPT_MAJOR_VERSION > 1) || (LIBLEPT_MINOR_VERSION > 82)
|
|
||||||
+ // The public API of Leptonica 1.83.0 hides details of some data
|
|
||||||
+ // structures which are used by tesserocr (see Pix, Box, ... above).
|
|
||||||
+ // Get those details by including a private header file.
|
|
||||||
+ #include <leptonica/pix_internal.h>
|
|
||||||
+ #endif
|
|
||||||
+ """
|
|
||||||
+
|
|
||||||
cdef extern from "tesseract/publictypes.h" namespace "tesseract" nogil:
|
|
||||||
cdef enum PolyBlockType:
|
|
||||||
PT_UNKNOWN # Type is not yet known. Keep as the first element.
|
|
@@ -1,3 +1,18 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Mar 17 22:09:28 UTC 2023 - Mia Herkt <mia@0x0.st>
|
||||||
|
|
||||||
|
- Update to 2.6.0
|
||||||
|
* _pix_to_image now works with binary images
|
||||||
|
gh#sirfz/tesserocr#274
|
||||||
|
* SetImage with alpha channels support
|
||||||
|
gh#sirfz/tesserocr#280
|
||||||
|
* Leptonica 1.83.0 support
|
||||||
|
gh#sirfz/tesserocr#306
|
||||||
|
* Pointsize should be returned even if fontname doesn't exist
|
||||||
|
gh#sirfz/tesserocr#308
|
||||||
|
* Added Python 3.10, 3.11 setup classifiers
|
||||||
|
- Drop 1441bec703cf68161acce5e85907ddd71c47fdc3.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon Feb 27 10:22:49 UTC 2023 - Daniel Garcia <daniel.garcia@suse.com>
|
Mon Feb 27 10:22:49 UTC 2023 - Daniel Garcia <daniel.garcia@suse.com>
|
||||||
|
|
||||||
|
@@ -17,14 +17,13 @@
|
|||||||
|
|
||||||
|
|
||||||
Name: python-tesserocr
|
Name: python-tesserocr
|
||||||
Version: 2.5.2
|
Version: 2.6.0
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: A Python wrapper around tesseract-ocr
|
Summary: A Python wrapper around tesseract-ocr
|
||||||
License: MIT
|
License: MIT
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
URL: https://github.com/sirfz/tesserocr
|
URL: https://github.com/sirfz/tesserocr
|
||||||
Source: https://files.pythonhosted.org/packages/source/t/tesserocr/tesserocr-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/t/tesserocr/tesserocr-%{version}.tar.gz
|
||||||
Patch1: 1441bec703cf68161acce5e85907ddd71c47fdc3.patch
|
|
||||||
BuildRequires: %{python_module Cython}
|
BuildRequires: %{python_module Cython}
|
||||||
BuildRequires: %{python_module Pillow}
|
BuildRequires: %{python_module Pillow}
|
||||||
BuildRequires: %{python_module devel}
|
BuildRequires: %{python_module devel}
|
||||||
@@ -52,7 +51,6 @@ GIL while processing an image in tesseract.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n tesserocr-%{version}
|
%setup -q -n tesserocr-%{version}
|
||||||
%patch1 -p1
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%python_build
|
%python_build
|
||||||
|
@@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:9371dd3f6fe3238039c73bfe15bcaf21389f7e75f62bd530a30110149f39b2ae
|
|
||||||
size 57406
|
|
3
tesserocr-2.6.0.tar.gz
Normal file
3
tesserocr-2.6.0.tar.gz
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:77430d272b53dacd3bdd4af5d563fdc24ae51b86fdbc9cf2e8146f29c7abc9a4
|
||||||
|
size 58637
|
Reference in New Issue
Block a user