- 报错没有 leptonica/allheaders.h
- 报错 ld: library not found for -ltesseract
brew install tesseract CPPFLAGS=-I/opt/homebrew/include LIBRARY_PATH=/opt/homebrew/lib pip3 install tesserocr
解释:安装tesserocr依赖的环境tesseract,并且设置变量将include和lib path暴露给pip3。

brew install tesseract CPPFLAGS=-I/opt/homebrew/include LIBRARY_PATH=/opt/homebrew/lib pip3 install tesserocr
解释:安装tesserocr依赖的环境tesseract,并且设置变量将include和lib path暴露给pip3。