summaryrefslogtreecommitdiff
path: root/roles/tesstrainer
diff options
context:
space:
mode:
Diffstat (limited to 'roles/tesstrainer')
-rw-r--r--roles/tesstrainer/tasks/tesseract.yml27
1 files changed, 22 insertions, 5 deletions
diff --git a/roles/tesstrainer/tasks/tesseract.yml b/roles/tesstrainer/tasks/tesseract.yml
index 0be3380..911759a 100644
--- a/roles/tesstrainer/tasks/tesseract.yml
+++ b/roles/tesstrainer/tasks/tesseract.yml
@@ -29,10 +29,21 @@
dest: /home/ec2-user/src/leptonica
version: addinstall
depth: 1
+ become: no
register: leptclone
- name: Build leptonica
- command: make -f makefile.static SHARED=yes install
+ command: make -f makefile.static {{ item }}
+ args:
+ chdir: /home/ec2-user/src/leptonica/src
+ with_items:
+ - SHARED=yes shared
+ - nodebug
+ become: no
+ when: leptclone.changed
+
+- name: Install leptonica
+ command: make -f makefile.static install
args:
chdir: /home/ec2-user/src/leptonica/src
when: leptclone.changed
@@ -43,12 +54,18 @@
dest: /home/ec2-user/src/tesseract
version: amibuild
depth: 1
+ become: no
register: tessclone
-- name: Build and install tesseract
- make: chdir=/home/ec2-user/src/tesseract/simplemake target=install
+- name: Build tesseract and training tools
+ command: make all training
+ args:
+ chdir: /home/ec2-user/src/tesseract/simplemake
+ become: no
when: tessclone.changed
-- name: Build and install tesseract training tools
- make: chdir=/home/ec2-user/src/tesseract/simplemake target=install-training
+- name: Install tesseract and training tools
+ command: make install install-training
+ args:
+ chdir: /home/ec2-user/src/tesseract/simplemake
when: tessclone.changed