-
Notifications
You must be signed in to change notification settings - Fork 2
/
INSTALL
89 lines (57 loc) · 2.38 KB
/
INSTALL
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
INSTALLING gOCR
INSTALLING BINARIES
-------------------
Be sure that you have all the libraries needed. To install a binary package,
do the following:
1. Unpack the archive if you have not done so already:
tar -xzf gocr[version].tar.gz
on older tar versions, the above line might not work. If so, try the following:
gzip -cd gocr[version].tgz | tar -xf -
This creates the directory ./gocr[version] containing the source from
the main archive.
2. Change to gocr directory and run make (use GNU Make).
cd gocr[version]; make install
That's it.
INSTALLING FROM SOURCE
----------------------
Requirements
------------
You'll need a compiler; we recommend gcc, but the code should compile in any
good one. gcc is available at http://gcc.gnu.org. I had some problems with gcc
2.95.1 (it consumed a LOT of memory while compiling ocr0.c). 2.95.2 seems to
be better.
gOCR provides some simple functions to read/write pnm archives. Though not
needed, we strongly suggest, however, that you install the NetPBM package. Its
official URL is: http://download.sourceforge.net/netpbm/.
Installing this package will add support to many different image formats.
If you have a NetPBM version older than August 2000, we suggest that you
download a more recent one, to take advantage of the new PAM functions.
Depending on your distribution you may use
yum install netpbm-devel # red-hat like
or
apt-get install libnetpbm10-dev # debian like
to get the necessary netpbm sources.
To create some of the examples provided, you'll need transfig.
This is completely optional.
Procedure
---------
1. Unpack the archive if you have not done so already:
tar -xzf gocr[version].tar.gz
on older tar versions, the above line might not work. If so, try the following:
gzip -cd gocr[version].tgz | tar -xf -
This creates the directory ./gocr[version] containing the source from
the main archive.
2. Change to gocr directory and run configure.
cd gocr[version]; ./configure
For a list of options, try ./configure --help.
If something goes wrong, try to run autoconf.
3. Run make (GNU Make). This can take a while.
make
4. gOCR comes with some examples, which are generated from xfig-files.
If you have transfig installed, you can make them:
make examples
5. Install the binaries. You may need to do this as root.
make install
6. Run gocr, or the frontend you chose.
gocr -h Shows help
gocr.tcl Runs Tcl GUI