Commit Graph

5899 Commits

Author SHA1 Message Date
Stefan Weil
22ec41fb66 autoconf: Set PKG_CONFIG_PATH required for Homebrew (macOS)
If no PKG_CONFIG_PATH was provided by the user, it is now set
automatically on hosts which have the `brew` command.

MacOS with Homebrew needs PKG_CONFIG_PATH to find icu4c and libarchive.

Signed-off-by: Stefan Weil <stweil@notebook11.fritz.box>
2022-01-12 18:59:33 +01:00
Egor Pugin
853aa66962
Merge pull request #3716 from ffontaine/main
Check if platform supports feenableexcept
2022-01-11 22:05:08 +03:00
Gilles Talis
be15b46c60 Check if platform supports feenableexcept
feenableexcept is not supported by uclibc

Signed-off-by: Gilles Talis <gilles.talis@gmail.com>
[Retrieved (and updated to add cmake support and simplify configure.ac)
from
https://git.buildroot.net/buildroot/tree/package/tesseract-ocr/0001-Check-if-platform-supports-feenableexcept.patch]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
2022-01-11 15:23:56 +01:00
Stefan Weil
5d5cd77e3d Create new release 5.0.1
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-07 13:43:52 +01:00
Stefan Weil
e28154ab1e Update documentation for release 5.0.1
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-07 10:39:59 +01:00
Egor Pugin
ded6108756
Merge pull request #3712 from stweil/cmake
cmake: TIFF is only used for WIN32
2022-01-07 00:02:55 +03:00
Stefan Weil
5113ed1b71 cmake: TIFF is only used for WIN32
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-06 20:52:49 +01:00
Piotr Kubaj
790f3bd104 Fix build on non-x86 non-ARM with clang
Clang doesn't exit with error on powerpc64* after adding -mfpu=neon,
but merely ignores the argument and prints a warning, which incorrectly
makes it defined as ARM with NEON.
2022-01-06 17:16:09 +01:00
Egor Pugin
890cf3ec8f
Merge pull request #3705 from stweil/cmake
Fix build with cmake 3.10.2 (Ubuntu bionic)
2022-01-03 19:03:33 +03:00
Stefan Weil
04a66b91e6 Don't use <XXX>_LINK_LIBRARIES for cmake before version 3.12
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-03 16:34:10 +01:00
Stefan Weil
28f854186f cmake: reformat with cmake-format
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-03 16:34:10 +01:00
Stefan Weil
b8b2ab225f Simplify cmake check for Pango related modules
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-03 16:34:10 +01:00
Stefan Weil
f2af305600 Update required packages for CI
A full build requires libarchive and libcurl.

The brew formula for pango depends on cairo and icu4c,
so it is not necessary to install them explicitly.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-03 14:44:21 +01:00
Egor Pugin
a02c80c3ed
Merge pull request #3704 from stweil/cmake-fixes
Two fixes for cmake builds
2022-01-02 17:00:52 +03:00
Stefan Weil
68a2aea135 cmake: Add project include paths before others
This fixes cmake builds with old tesseract header files in /usr/local.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-02 14:58:08 +01:00
Stefan Weil
c3c734e5ab cmake: Fix check for CURL_LIBRARIES
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-02 14:58:08 +01:00
Stefan Weil
e1764e1bc8 Use cmake policy CMP0074 only with version 3.12 or newer
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-01 23:00:47 +01:00
Stefan Weil
a185c068d1 Update submodule googletest to release v1.11.0
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2022-01-01 18:50:24 +01:00
Stefan Weil
6727aae7e9 Remove unused include statement
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-30 19:44:00 +01:00
Stefan Weil
df227caa87 Add function ERRCODE::error with only 2 parameters
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-30 18:46:48 +01:00
Stefan Weil
84e6f44455 Fix some compiler warnings (implicit float to double conversion)
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-30 17:58:36 +01:00
Stefan Weil
25d25b5e09 Remove unused forward declaration
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-30 17:52:29 +01:00
Egor Pugin
512587a6e6
Merge pull request #3699 from stweil/bugfix
Remove duplicate parameter certainty_scale
2021-12-30 13:24:50 +03:00
Stefan Weil
e87969033b Remove duplicate parameter certainty_scale
It was also declared in class Dict and mostly used from that class.
Setting it via API or command line never changed that used value.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-30 10:36:37 +01:00
zdenop
86158d3978
Merge pull request #3697 from stweil/opt
Small optimizations and fixes for some compiler warnings
2021-12-29 20:13:38 +01:00
Stefan Weil
d754593a31 Catch nullptr in STATS::pile_count (fix isse #3694)
Add also a test case for this issue.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-29 17:26:32 +01:00
Stefan Weil
22e86fa75d Eliminate function NetworkIO::ZeroTimeStepGeneral
This allows more inline code (optimization).

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-29 17:17:57 +01:00
Stefan Weil
03e82271bb Fix clang compiler warnings in functions.h
The new code avoids some conversions between double and float,
so it should also have a small positive effect on the performance.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-27 15:39:46 +01:00
Stefan Weil
7277963e11 Update generator for lookup tables to use TFloat instead of double
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-27 10:31:42 +01:00
Stefan Weil
706d3bac62 Fix some clang compiler warnings
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-26 17:45:16 +01:00
Egor Pugin
bf7c134ba6
Merge pull request #3690 from stweil/SPDX
Clean header comments in public include files
2021-12-25 23:32:58 +03:00
Stefan Weil
3ab060ffbc Clean header comments in public include files
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-25 20:53:06 +01:00
Stefan Weil
5057483ec8 Add SPDX-License-Identifier to public include files
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-25 20:50:49 +01:00
Stefan Weil
7a218f1d6c Fix compiler warning [-Wsign-compare]
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-25 17:02:45 +01:00
Stefan Weil
34311179f5 Allow printing of bitfield with variadic templates
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-23 16:38:00 +01:00
Stefan Weil
edf5c91ab9 Fix compiler warnings caused by empty statements
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-23 16:35:47 +01:00
Stefan Weil
a8bdc78985 Replace tprintf comment in API header
tprintf is not part of the public API, so replace it by printf.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-23 15:53:11 +01:00
zdenop
07e319afa8
Cmake install (#3685)
* cmake: install configs
2021-12-22 21:48:52 +03:00
zdenop
f65fae82ac clean up condition to detect MSCV 2021-12-22 18:57:13 +01:00
Zdenko Podobný
771c1e9c9b fix lstm.cpp build with clang 2021-12-20 14:40:45 +01:00
Zdenko Podobný
03ae6d095d cmake: fix bcf7bbb6e2 2021-12-20 13:44:51 +01:00
Zdenko Podobný
bcf7bbb6e2 cmake: do not try to even configure training tools if pkg-config is not present. 2021-12-20 13:37:37 +01:00
Zdenko Podobný
8f02255294 cmake: reformat with cmake-format and check with cmake-lint 2021-12-20 13:18:01 +01:00
zdenop
b565cfee9b cmake: do not try to configure training tools without PkgConfig 2021-12-18 09:29:20 +01:00
zdenop
2ee90ffe08 cmake: remove unused code 2021-12-18 09:20:37 +01:00
Amit D
5fd8bfb5ec
CMake: Also check x86_64 and i686 2021-12-17 11:52:47 +02:00
zdenop
82f510fe1e cmake: fix fb74c7eac1 2021-12-16 17:59:33 +01:00
Egor Pugin
5652210c55
Merge pull request #3681 from stweil/curl
Support up to 8 redirections when running OCR on a URL
2021-12-16 18:58:45 +03:00
Stefan Weil
f728df0cfa Support up to 8 redirections when running OCR on a URL
Signed-off-by: Stefan Weil <sw@weilnetz.de>
2021-12-16 14:57:18 +01:00
Amit D
1e1a8f6949
Update README.md 2021-12-08 07:25:13 +02:00