dlareklami / tesseract-ocr

Automatically exported from code.google.com/p/tesseract-ocr
Other
0 stars 0 forks source link

Error: ./.libs/libtesseract.so: undefined reference to `pixGenerateCIData' #1151

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Running "make" to install tesseract-ocr-3.03 from source code checked-out 
from svn
2.
3.

What is the expected output? What do you see instead?
Getting error:

Making all in api
make[2]: Entering directory `/home/****/temp/tesseract-ocr-3.03/api'
/bin/bash ../libtool --tag=CXX   --mode=link g++  -std=c++11   -o tesseract 
tesseract-tesseractmain.o libtesseract.la   -lrt -llept -lpthread 
libtool: link: g++ -std=c++11 -o .libs/tesseract tesseract-tesseractmain.o  
./.libs/libtesseract.so -lrt -llept -lpthread
./.libs/libtesseract.so: undefined reference to `pixGenerateCIData'
collect2: error: ld returned 1 exit status
make[2]: *** [tesseract] Error 1

What version of the product are you using? On what operating system?

tesseract-ocr-3.03 source code (r1094) from:
svn checkout http://tesseract-ocr.googlecode.com/svn/trunk/ 
tesseract-ocr-read-only

leptonica-1.70:
Built and installed from source code: leptonica-1.70.tar.gz

Ubuntu 12.10

Please provide any additional information below.

Followed compiling instructions: 
https://code.google.com/p/tesseract-ocr/wiki/Compiling

up to:
./autogen.sh
./configure
make

When running "make", it errors out:

Making all in api
make[2]: Entering directory `/home/****/temp/tesseract-ocr-3.03/api'
/bin/bash ../libtool --tag=CXX   --mode=link g++  -std=c++11   -o tesseract 
tesseract-tesseractmain.o libtesseract.la   -lrt -llept -lpthread 
libtool: link: g++ -std=c++11 -o .libs/tesseract tesseract-tesseractmain.o  
./.libs/libtesseract.so -lrt -llept -lpthread
./.libs/libtesseract.so: undefined reference to `pixGenerateCIData'
collect2: error: ld returned 1 exit status
make[2]: *** [tesseract] Error 1

Original issue reported on code.google.com by mohsen.m...@gmail.com on 7 May 2014 at 6:25

GoogleCodeExporter commented 9 years ago
The message statutes that tesseract library can not find pixGenerateCIData 
function (provided by leptonica 1.70), so this is not tesseract issue, but 
leptonica installation issue.
IMO there could be 2 reasons for error:
1. you did not uninstall old leptonica library properly before installing 1.70 
version
2. you did not install leptonica 1.70 properly.

Original comment by zde...@gmail.com on 7 May 2014 at 7:29

GoogleCodeExporter commented 9 years ago

Original comment by zde...@gmail.com on 7 May 2014 at 8:50

GoogleCodeExporter commented 9 years ago
Any chance you can toss us a bone on how to find information on removing old 
libraries or properly installing leptonica 1.70?  I have the same problem, but 
am following instructions to no avail.  Thanks.

Original comment by freddyth...@gmail.com on 20 Aug 2014 at 3:49

GoogleCodeExporter commented 9 years ago
I found that the earlier version of leptonica was installed (by default?) in 
/usr/include/leptonica and /usr/lib/leptonica and 1.71 (I didn't try 1.70) was 
installed in /usr/local/include/leptonica and /usr/local/lib/leptonica.  

Easiest solution - 

# rm -rf /usr/include/leptonica /usr/lib/leptonica

as the /usr/local/*/leptonica were being searched AFTER the /usr/*/leptonica 
versions.

Original comment by karl.nyb...@gmail.com on 5 Sep 2014 at 2:27

GoogleCodeExporter commented 9 years ago
Ihave the same problem. leptonica is installed correctly - at least "make 
check" fpr leptonica 1.71 says that all tests were passed.
Nevertheless, the directories in question seem not to exist.

I do have /usr/local/include/leptonica, but I do have only liblept*-files in 
/usr/local/lib - no subdirectory "Leptonica"

Original comment by n.nicki...@gmx.de on 5 Sep 2014 at 5:38

GoogleCodeExporter commented 9 years ago
I had the same issue, I rebuilt leptonica and change the prefix dir to /usr

#./configure --prefix /usr

That then installed the liblept in /usr/lib and I was able to carry on 
compiling tesseract-ocr.

Original comment by kur...@gmail.com on 11 Sep 2014 at 8:45