File: fix_tesseract_

package info (click to toggle)
fuzzyocr 3.6.0-12
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 684 kB
  • sloc: perl: 3,150; sh: 45; makefile: 42
file content (35 lines) | stat: -rw-r--r-- 1,245 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
Author: Arjan Opmeer <arjan.opmeer@gmail.com>
Forwarded: no
Bug-Debian: http://bugs.debian.org/481383
Last-Update: 2008-05-15
Description: Fix for tesseract 2.03

--- fuzzyocr-3+svn135.orig/FuzzyOcr/Preprocessor.pm	2008-09-28 11:12:08.000000000 +0200
+++ fuzzyocr-3+svn135/FuzzyOcr/Preprocessor.pm	2008-09-28 11:18:12.000000000 +0200
@@ -32,6 +32,10 @@
     my $tmpdir = FuzzyOcr::Config::get_tmpdir();
     my $label = $self->{label};
     my $output = "$tmpdir/prep.$label.out";
+
+    if ($label eq "maketiff") {
+        $output = "$tmpdir/prep.$label.tif";
+    }
     my $stderr = ">$tmpdir/prep.$label.err";
 
     my $stdin = undef;
--- fuzzyocr-3+svn135.orig/FuzzyOcr/Scanset.pm	2008-09-28 11:15:30.000000000 +0200
+++ fuzzyocr-3+svn135/FuzzyOcr/Scanset.pm	2008-09-28 11:19:07.000000000 +0200
@@ -80,7 +80,12 @@
                 return ($retcode,@result);
             }
             # Input of next processor is output of last
-            $input = "$tmpdir/prep.$plabel.out";
+            # Output name of maketiff is special!
+            if ($plabel eq "maketiff") {
+                $input = "$tmpdir/prep.$plabel.tif";
+            } else {
+                $input = "$tmpdir/prep.$plabel.out";
+            }
         }
     }