tesseract/.travis.yml

46 lines
1.3 KiB
YAML
Raw Normal View History

# Travis CI configuration for Tesseract
2021-03-08 02:31:02 +08:00
sudo: false
2015-09-07 01:54:05 +08:00
notifications:
email: false
2021-03-08 02:31:02 +08:00
language: cpp
2021-03-08 02:31:02 +08:00
os: linux
dist: focal
arch:
- amd64
- arm64
- ppc64le
- s390x
compiler:
- gcc
- clang
env:
- LEPT_VER=1.80.0
cache:
directories:
- leptonica-$LEPT_VER
2015-09-07 01:54:05 +08:00
2021-03-08 02:31:02 +08:00
before_install:
- sudo apt-get install libpango1.0-dev libicu-dev libtiff5-dev -y
- rm -rf leptonica-$LEPT_VER/usr
install:
- if test ! -d leptonica-$LEPT_VER/src; then curl -Ls https://github.com/DanBloomberg/leptonica/archive/$LEPT_VER.tar.gz | tar -xz; fi
- if test ! -d leptonica-$LEPT_VER/usr; then cmake -Hleptonica-$LEPT_VER -Bleptonica-$LEPT_VER/build -DCMAKE_INSTALL_PREFIX=leptonica-$LEPT_VER/usr; fi
- if test ! -e leptonica-$LEPT_VER/usr/lib/libleptonica.so; then make -C leptonica-$LEPT_VER/build install; fi
2021-03-08 02:31:02 +08:00
script:
- mkdir build
- cd build
- cmake .. -DLeptonica_DIR=leptonica-$LEPT_VER/build -DSW_BUILD=OFF
- make
- sudo make install
2021-03-08 08:02:25 +08:00
#after_script: # let those commands trigger build errors
2021-03-08 02:31:02 +08:00
- tesseract -v
- text2image -v
- lstmtraining -v
- ls /home/travis/build/tesseract-ocr/tesseract/test/testing/*.tif
- wget https://github.com/egorpugin/tessdata/raw/master/tessdata/eng.traineddata
- tesseract /home/travis/build/tesseract-ocr/tesseract/test/testing/phototest.tif - -l eng --tessdata-dir ./