MarketSquare / MarketSquare/robotframework-SikuliLibrary

Having Issues with SikuliLibrary 2.0.3 and Tesseract on macOS Catalina

Open
#180 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
163
Forks
60
PR merge metrics
No merged PRs in 30d

Description

See https://github.com/RaiMan/SikuliX1/wiki/macOS-Linux:-Support-libraries-for-Tess4J-Tesseract-4-OCR

I did install tesseract via `brew install tessearct` but it still doesn't work with:

```bash
org.sikuli.script.SikuliXception: OCR: start: Tesseract library problems: Unable to load library 'tesseract':
dlopen(libtesseract.dylib, 9): image not found
dlopen(libtesseract.dylib, 9): image not found
Native library (darwin/libtesseract.dylib) not found in resource path (/Library/Python/3.8/site-packages/SikuliLibrary/lib/SikuliLibrary.jar)
```

I then put the `libtesseract.dylib` directly inside `SikuliLibrary.jar` via

```bash
cd /Library/Python/3.8/site-packages/SikuliLibrary/lib && mkdir darwin && jar uf SikuliLibrary.jar darwin && cp /usr/local/Cellar/tesseract/5.2.0/lib/libtesseract.5.dylib darwin/libtesseract.dylib && jar uf SikuliLibrary.jar darwin/libtesseract.dylib && jar tf SikuliLibrary.jar && rm -rf darwin
```

That also doesn't work and fails with

```
org.sikuli.script.SikuliXception: OCR: start: Tesseract library problems: Error looking up function 'TessBaseAPIRecognizeForChopTest': dlsym(0x7f813f572020, TessBaseAPIRecognizeForChopTest): symbol not found
```

`tessearct -v` results in

```
tesseract 5.2.0
leptonica-1.82.0
libgif 5.2.1 : libjpeg 8d (libjpeg-turbo 2.1.3) : libpng 1.6.38 : libtiff 4.4.0 : zlib 1.2.11 : libwebp 1.2.4 : libopenjp2 2.5.0
Found AVX512BW
Found AVX512F
Found AVX2
Found AVX
Found FMA
Found SSE4.1
Found libarchive 3.6.1 zlib/1.2.11 liblzma/5.2.5 bz2lib/1.0.6 liblz4/1.9.3 libzstd/1.5.2
Found libcurl/7.64.1 SecureTransport (LibreSSL/2.8.3) zlib/1.2.11 nghttp2/1.39.2
```

Any help appreciated.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the macOS support-libraries guidance linked in the issue and the SikuliLibrary.jar under /Library/Python/3.8/site-packages/SikuliLibrary/lib. Reproduce the reported OCR startup errors using the shown Homebrew and JAR commands, then verify that SikuliLibrary can initialize OCR and recognize text on macOS Catalina.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, macos
Domain
desktop-dev, testing
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.