运行Tess4j的示例代码已在“http://tess4j.sourceforge.net/codesample.html”中给出,但是它是在intellij的Mac OS中执行的,!strcmp(locale, "C"):Error:Assert failed:in file baseapi.cpp, line 209
出现了以下错误消息:
A fatal error has been detected by the Java Runtime Environment:
SIGILL (0x4) at pc=0x000000012183ca4f, pid=44026, tid=0x0000000000001903
JRE version: Java(TM) SE Runtime Environment (8.0_144-b01) (build 1.8.0_144-b01)
Java VM: Java HotSpot(TM) 64-Bit Server VM (25.144-b01 mixed mode bsd-amd64 compressed oops)
Problematic frame:
C [libtesseract.dylib+0x156a4f] ERRCODE::error(char const*, TessErrorLogCode, char const*, ...) const+0x183
根据我对以上帖子的阅读,导出LC_ALL = C似乎是一个问题,但不确定在给出的示例代码中,应该添加/修改哪些确切的代码才能使该示例运行?
最佳答案
在终端中输入export LC_ALL=C
后,在同一终端窗口中打开IDE。在其他终端上运行IDE/代码将不起作用。
关于java - !strcmp(语言环境, “C”):Error:Assert failed:in file baseapi.cpp, line 209,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/53591055/