The command / Applications / Xcode.app / Contents / Developer / Toolchains / XcodeDefault.xctoolchain / usr / bin / lex failed with exit code 1

I am trying to include a file in my resource package, the files contain the following:

LeadPunc="({[`'
TrailPunc=}:;-]!?`,.)"'
NumLeadPunc=#({[@$
NumTrailPunc=}):;].,%
Operators=*+-/.:,()[]
Digits=0123456789
Alphas=abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
*extra line*

Files are called:

eng.cube.lm

The error I am getting is:

IExpenseReporter/tessdata/eng.cube.lm:6: premature EOF
Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lex failed with exit code 1

This file corresponds to the latest version of tesseract (OCR). Does anyone know what causes this error and how to fix it?

+4
source share
3 answers

Xcode "thinks" this is a lex file and try to process it by calling lex. However, lex finds both an unbalanced quote and, therefore, a premature end to the file.

You should try to explicitly call the specified tool.

+1

, " " tessdata .

:

. tessdata . Tesseract , , , tessdata , . , :

enter image description here

, tessdata , , .

, .

+10

I had this problem, and I found that copying the "tessdata" folder from the zip language to the project directory, and not in Xcode, fixes the problem.

0
source

All Articles