You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm in the process of migrating from using version 3.05.01 to version 4.0.0 in an Android app and I'm seeing a SEGFAULT already when trying to create a new base api.
I'm building using the r18b Android NDK and this is my build settings:
The build runs fine, and the resultant .so file seems ok as well:
$ file extracted/tesseract-4.0.0-armv7-a-build/lib/libtesseract.so
extracted/tesseract-4.0.0-armv7-a-build/lib/libtesseract.so: ELF 32-bit LSB shared object, ARM, EABI5 version 1 (SYSV), dynamically linked, BuildID[sha1]=6a0dcecff780e71292e3952aaf3647753d450768, with debug_info, not stripped
I have a small Qt unit test, which doesn't do anything else than just trying to create a new instance of the base api. Source can be seen here: tst_tesseract_4_0_0.cpp.
It's pretty simple and just links in tesseract and leptonica, and bundles libtiff.
The segfault appears o be caused by the locale assertion introduced in 3292484, because the value of locale in my case is C.UTF-8.
The way this fails, produces no errors or warnings about the value of locale and I just stumbled upon this by, because I happened to have source maps set up in debugging.
I'm in the process of migrating from using version 3.05.01 to version 4.0.0 in an Android app and I'm seeing a SEGFAULT already when trying to create a new base api.
I'm building using the r18b Android NDK and this is my build settings:
Full setup can be seen in this dockerfile: tesseract-4.0.0.Dockerfile.
The build runs fine, and the resultant .so file seems ok as well:
I have a small Qt unit test, which doesn't do anything else than just trying to create a new instance of the base api. Source can be seen here: tst_tesseract_4_0_0.cpp.
It's pretty simple and just links in tesseract and leptonica, and bundles libtiff.
It is based off of the same test for v3.05.01 which runs just fine: tst_tesseract_3_05_01.cpp.
The segfault appears o be caused by the locale assertion introduced in 3292484, because the value of
locale
in my case isC.UTF-8
.The way this fails, produces no errors or warnings about the value of locale and I just stumbled upon this by, because I happened to have source maps set up in debugging.
Environment
Current Behavior:
SIGSEGV
when callingnew tesseract::TessBaseAPI()
.Expected Behavior:
No segfaults.
Suggested Fix:
Provide some sort of warning about the locale maybe.
CC @stweil
The text was updated successfully, but these errors were encountered: