My application in JAVA does'nt find 'libtesseract302.lib'

1,124 views
Skip to first unread message

José Luis Jiménez Márquez

unread,
Dec 19, 2013, 10:43:15 AM12/19/13
to tesser...@googlegroups.com
Hello everybody,

      I have a problem with library references of Tesseract. My application is built in JAVA and I used ECLIPSE IDE. When It call
the method doOCR, It throws exceptions:

Exception in thread "main" java.lang.UnsatisfiedLinkError: Unable to load library 'libtesseract302': No se puede encontrar el módulo especificado.

at com.sun.jna.NativeLibrary.loadLibrary(NativeLibrary.java:194)
at com.sun.jna.NativeLibrary.getInstance(NativeLibrary.java:283)
at com.sun.jna.Library$Handler.<init>(Library.java:142)
at com.sun.jna.Native.loadLibrary(Native.java:368)
at com.sun.jna.Native.loadLibrary(Native.java:353)
at net.sourceforge.tess4j.TessAPI.<clinit>(Unknown Source)
at net.sourceforge.tess4j.Tesseract.doOCR(Unknown Source)
at net.sourceforge.tess4j.Tesseract.doOCR(Unknown Source)
at net.sourceforge.tess4j.Tesseract.doOCR(Unknown Source)
at net.sourceforge.tess4j.Tesseract.doOCR(Unknown Source)
        ........


I don't Know change library path for Tesseract find it. I'm searching in the code but I didn´t find.

Thank you.

Quan Nguyen

unread,
Dec 20, 2013, 10:34:14 AM12/20/13
to tesser...@googlegroups.com
It's trying to search for libtesseract302.dll, not .lib.

Check out these posts:

http://sourceforge.net/p/tess4j/discussion/1202294/thread/cd54d983
http://stackoverflow.com/questions/10815978/including-tess4j-to-a-java-project-as-library-in-eclipse

And make sure you use 32-bit Java.
Reply all
Reply to author
Forward
0 new messages