Community Packages

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#31213 - [tesseract] segfault

Attached to Project: Community Packages
Opened by Tim Sears (timsears) - Monday, 20 August 2012, 15:35 GMT
Last edited by Sergej Pupykin (sergej) - Tuesday, 18 September 2012, 20:23 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Sergej Pupykin (sergej)
Architecture i686
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
After pacman -Syu, tesseract exits with segmentation fault.
Recompile/reinstall from ABS results in the same behavior. Suspect one of its upstream dependencies needs to be recompiled.

This task depends upon

Closed by  Sergej Pupykin (sergej)
Tuesday, 18 September 2012, 20:23 GMT
Reason for closing:  Fixed
Additional comments about closing:  optdepends added to tesseract
Comment by Tim Sears (timsears) - Monday, 27 August 2012, 19:48 GMT
Downgraded leptonica-1.69-4 and tesseract-3.01-3 via...
sudo pacman -U /var/cache/pacman/pkg/leptonica-1.68-3-i686.pkg.tar.xz
sudo pacman -U /var/cache/pacman/pkg/tesseract-3.01-1-i686.pkg.tar.xz

This stopped the segfault when invoking tesseract. Regard as workaround.

Perhaps off-topic, but I have an ubuntu 12.04 box with leptonica 1.69-2 and tesseract-3.02.01-2 and that combination works fine.



Comment by Sergej Pupykin (sergej) - Monday, 27 August 2012, 20:26 GMT
Which command line do you use to reproduce segfault?
Comment by Tim Sears (timsears) - Monday, 27 August 2012, 20:47 GMT
You can run the following using the attached file for "testocr.tiff"
tesseract testocr.tiff testocr -psm 7
Runs correctly on my reverted system.

Comment by Sergej Pupykin (sergej) - Tuesday, 28 August 2012, 10:31 GMT
Works for me

$ sudo pacman -S tesseract tesseract-data-eng

$ tesseract qwe.tiff testocr -psm 7
Tesseract Open Source OCR Engine v3.01 with Leptonica
Page 0

$ cat testocr.txt
HE|Nz KETCHUP 4002
Comment by Sergej Pupykin (sergej) - Tuesday, 28 August 2012, 10:31 GMT
but I use x86_64
Comment by Tim Sears (timsears) - Tuesday, 28 August 2012, 14:40 GMT
I am using i686. Can't switch due to other deps.
Comment by Sergej Pupykin (sergej) - Tuesday, 18 September 2012, 15:52 GMT
Can it be reproduced now? I checked it in i686 chroot and it works too.
Comment by Tim Sears (timsears) - Tuesday, 18 September 2012, 17:20 GMT
I found the problem. At some point the the directory /usr/share/tessdata got cleaned out.
There is a requirement for at least one file .trainedata to be there.

Otherwise you get...
timsears@archlinux32:~$ tesseract /mnt/hgfs/timsears/Dropbox/labels/data/test.tiff test -l eng -psm 7
Error opening data file /usr/share/tessdata/eng.traineddata
Tesseract Open Source OCR Engine v3.01 with Leptonica
Page 0
Segmentation fault

This provides a clue, but only if you give the flag.

Entering this fixes the problem...
sudo pacman -S tesseract-data-eng

Suggest this somehow be encoded in the dependencies for the package tesseract. I have been using this package and the source version for a year and still got tripped up.

Loading...