安装的tesserocr(python)看不到leptonica

时间:2016-08-07 14:45:05

标签: linux python-3.x shared-libraries leptonica

我在$ HOME / local安装了leptonica和tesseract,并且tesseract工作正常,然后tesserocr python包用:

CPPFLAGS="-I/home/user/local/include /home/user/local/lib" pip install tesserocr

当我想调用它时,我得到了这个:

$ python3 extract.py 
Traceback (most recent call last):
  File "extract.py", line 4, in <module>
    from tesserocr import PyTessBaseAPI, RIL, PyLTRResultIterator, iterate_level
ImportError: liblept.so.5: cannot open shared object file: No such file or directory

请帮助

1 个答案:

答案 0 :(得分:0)

正如我对原帖的评论所述,正确的安装命令应为:

CPPFLAGS="-I/home/user/local/include -L/home/user/local/lib" pip install tesserocr