Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8126057
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T07:01:38+00:00 2026-06-06T07:01:38+00:00

I’m working on a OCR Android App, but I’m having lots of problems with

  • 0

I’m working on a OCR Android App, but I’m having lots of problems with the Tesseract-ocr library. I’ve followed every step included in the README file in order to build the library, but I’m only getting the libjpeg.so compiled 🙁

Now, I’m gonna explain every step I’ve taken so it will help you know what i’m doing wrong

I run without problems:

cd <project-directory>
mkdir external; cd external
wget http://tesseract-ocr.googlecode.com/files/tesseract-3.00.tar.gz
tar -zxvf tesseract-3.00.tar.gz
rm -f tesseract-3.00.tar.gz
wget http://leptonica.googlecode.com/files/leptonlib-1.66.tar.gz
tar -zxvf leptonlib-1.66.tar.gz
rm -f leptonlib-1.66.tar.gz

When running:

git clone git://android.git.kernel.org/platform/external/jpeg.git libjpeg

I get:

Cloning into 'libjpeg'...
fatal: unable to connect to android.git.kernel.org:
android.git.kernel.org[0: 149.20.4.77]: errno=Connection timed out

To solve it, I use the mirror and run:

git clone git:https://github.com/android/platform_external_jpeg libjpeg

Ok, It seems to work. I get:

Cloning into 'libjpeg'...
remote: Counting objects: 324, done.
remote: Compressing objects: 100% (229/229), done.
remote: Total 324 (delta 142), reused 269 (delta 93)
Receiving objects: 100% (324/324), 756.37 KiB | 412 KiB/s, done.
Resolving deltas: 100% (142/142), done.

No problems while running:

cd libjpeg
git checkout e0eadaa39b72e33f032220246c771d7302ebeaf8
cd ..
export TESSERACT_PATH=${PWD}/tesseract-3.00
export LEPTONICA_PATH=${PWD}/leptonlib-1.66
export LIBJPEG_PATH=${PWD}/libjpeg
cd ..

but, after running ndk-build I get an error:

/cygdrive/c/Android_NDK/build/core/build-local.mk:40: build/core/init.mk: No such file or directory
/cygdrive/c/Android_NDK/build/core/build-local.mk:122: *** falta un `endif'.  Alto.

Where “ falta un `endif’. Alto.” means “missing ‘endif’. Stop.“

OK, here I use the Android.mk from tesseract project and introduce minor changes to adapt it to my project directory. [Here it is][4]

Now I run

ndk-build 

and I only get

libs/armeabi/libjpg.so

I think that’s because the Android.mk needs the next lines to be added to it:

include $(call all-subdir-makefiles) $(TESSERACT_PATH)/Android.mk
include $(call all-subdir-makefiles) $(LEPTONICA_PATH)/Android.mk

I do so, and, since there’s no Android.mk file at LEPTONICA_PATH and TESSERACT_PATH I take them from the tesseract-android-tools project – as I did before:

  • [tesseract’s Android.mk][5],
  • leptonica’s Android.mk]

Then I execute

C:\tesseract\jni>ndk-build
C:/Android_NDK/build/core/build-binary.mk:240: *** target pattern contains no `%'.  Stop.

And there I got stuck. I’ve tried to solved and so I tried some things (among them, some suggestions I found here at stackoverflow) but none of them solved the problem.

I gave you every detail so it will be easier for you to find the mistake I’m making.

(Ah! I’m on WinXP+Cygwin)

Thanks in advance

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T07:01:40+00:00Added an answer on June 6, 2026 at 7:01 am

    I actually had the same problem. I ended up making a lot of changes to both the make files and even some of the C code within the library but was only able to get limited functionality from it. I would recommend using this tess-two library instead. I was able to compile it without any problems. However, I ended up switching before Ubuntu doing this. Give it a shot. Hope this helps!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
We're building an app, our first using Rails 3, and we're having to build
I want to count how many characters a certain string has in PHP, but
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I need to clean up various Word 'smart' characters in user input, including but
Seemingly simple, but I cannot find anything relevant on the web. What is the
I want to construct a data frame in an Rcpp function, but when I
I am writing an app with both english and french support. The app requests

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.