ccouzens / tesseract-sys

Rust FFI bindings to tesseract
MIT License
26 stars 18 forks source link

use fix for macos #7

Closed vim-zz closed 3 years ago

vim-zz commented 3 years ago

Solves some issues for Mac users, see https://github.com/ccouzens/tesseract-sys/issues/4

Run it with: PATH="/opt/homebrew/opt/llvm/bin/:$PATH" cargo build

tasted on Mac OS M1 not tested on Linux or Windows

ccouzens commented 3 years ago

Thank you @vim-zz :)

I should have time to merge and publish the new version this time tomorrow.

I'm getting build failures on github actions https://github.com/ccouzens/tesseract-sys/runs/2797707037?check_suite_focus=true

I should be able to deal with them tomorrow, but if you've got time before then that would be good :)

ccouzens commented 3 years ago

PATH="/opt/homebrew/opt/llvm/bin/:$PATH" cargo build

This is much nicer than

PATH="/usr/local/opt/llvm/bin:$PATH" BINDGEN_EXTRA_CLANG_ARGS='-I"/usr/local/Cellar/tesseract/4.1.1/include" -I"/usr/local/Cellar/leptonica/1.80.0/include"' cargo test

Thank you

vim-zz commented 3 years ago

@ccouzens I fixed and pushed to my fork, it should now build on linux.

I have changed line 48 to fn find_tesseract_system_lib() -> Option<Vec<String>> {

ccouzens commented 3 years ago

All merged and released- nice work :)