Debian Codegraph @

README

raw
1
2 1- WHAT IS DJVU.
3 ================
4
5 DjVu (pronounced "déjà vu") a set of compression technologies, a file format,
6 and a software platform for the delivery over the Web of digital documents,
7 scanned documents, and high resolution images.
8
9 DjVu documents download and display extremely quickly, and look exactly the
10 same on all platforms. DjVu can be seen as superior alternative to PDF and
11 Postscript for digital documents, to TIFF (and PDF) for scanned documents, to
12 JPEG for photographs and pictures, and to GIF for large palettized
13 images. DjVu is the only Web format that is practical for distributing
14 high-resolution scanned documents in color. No other format comes close.
15
16 Typical DjVu file sizes are as follows:
17
18 - Bitonal scanned documents:
19 5 to 30KB per page at 300dpi,
20 3 to 10 times smaller than PDF or TIFF.
21
22 - Color scanned documents:
23 30 to 100KB per page at 300dpi,
24 5 to 10 times smaller than JPEG.
25
26 - Photos:
27 2 times smaller than JPEG,
28 about the same as JPEG-2000.
29
30 - Palettized images:
31 2 times smaller than GIF,
32 up to 10 times if there is text.
33
34 DjVu is used by hundreds of commercial, governmental, and non-commercial web
35 sites around the world to distribute scanned documents, digital documents, and
36 high-resolution photos.
37
38 Demos, and general information about DjVu can be found at
39 http://www.djvuzone.org, or at http://www.lizardtech.com.
40
41 DjVu was originally developed at AT&T Labs-Research. AT&T sold DjVu to
42 LizardTech Inc. in March 2000.
43
44
45
46 2- WHAT IS DJVULIBRE?
47 =====================
48
49 In an effort to promote DjVu as a Web standard, LizardTech's management was
50 enlightened enough to release the reference implementation of DjVu under the
51 GNU GPL in October 2000. DjVuLibre (pronounced like the French "déjà vu
52 libre"), is an enhanced version of that code maintained by the original
53 inventors of DjVu. It is compatible with LizardTech's DjVu software v3.5.
54
55 This package includes:
56
57 - An up-to-date version of the C++ DjVu Reference Library
58 - A full-fledged wavelet-based compressor for pictures.
59 - A simple compressor for bitonal (black and white) scanned pages.
60 - A compressor for palettized images (a la GIF).
61 - A full set of utilities to manipulate and assemble DjVu images and documents.
62 - A set of decoders to convert DjVu to a number of other formats.
63
64 The full-fledged DjVu file viewer and browser plugin DjView4
65 is available as a separate package.
66
67
68
69 3- BUILDING DJVULIBRE
70 =====================
71
72 3.1- PREREQUISITES
73 ------------------
74
75 DjVuLibre-3.5 relies on various components available from the web.
76 Most recent Linux distribution already come with these.
77 You can also download and compile them if you wish.
78 Be sure to read the system specific notes
79 at the end of this file.
80
81 COMPILER --
82 Development is done with the GCC g++ compiler, which is therefore
83 recommended for all platforms. The CLANG compiler has been tried and
84 seems to work, but its output has not been seriously tested.
85
86 LIBJPEG/LIBTIFF --
87 A small number of DjVu files internally use JPEG encoding instead
88 of IW44 wavelet encoding. These files are processed using either
89 version 6a or 6b of the IJG libjpeg library <http://www.ijg.org>.
90 Some utility programs are able to read TIFF files. These programs
91 rely on the LIBTIFF library <http://libtiff.org>.
92 You can also compile DjVuLibre with neither JPEG nor TIFF support.
93 You might never notice the difference.
94
95
96 3.2 - CONFIGURE
97 ---------------
98
99 Chances are that everything will work by simply running
100 commands "./configure", "make" and "make install".
101
102 Note that there will be no configure file if you obtain the djvulibre
103 source using git clone. Instead there is a script 'autogen.sh' that
104 uses automake to generate and call the actual configure script.
105 Since all autogen.sh arguments will be passed to configure,
106 you can simply treat autogen.sh as a replacement for configure.
107
108 Various options and environment variables affect the execution of the
109 configuration script. A complete list can be obtained by typing
110 "configure --help". Also see the INSTALL file for further details.
111 Here are the most important ones.
112
113 * Option "--prefix=PREFIXDIR"
114 This option specifies where the DjVuLibre software will be installed.
115 The default prefix is /usr/local.
116
117 * Option "--enable-desktopfiles[=(yes|no)]"
118 Installs icon and mime type files in the customary xdg directories.
119 The default is "yes".
120
121 * Option "--with-jpeg=JPEGDIR"
122 This option specifies a directory where the JPEG library has been
123 compiled. This directory contains both the include files and the
124 library. Without this option, the configuration script will search
125 the JPEG library in standard places.
126 When everything else fails, you can simply define the environment
127 variables JPEG_CFLAGS and JPEG_LIBS.
128
129 * Option "--with-tiff=TIFFDIR"
130 This option specifies a directory where the LIBTIFF library has been
131 compiled. This directory contains both the include files and the
132 library. Without this option, the configuration script will search
133 the LIBTIFF library in standard places.
134 When everything else fails, you can simply define the environment
135 variables TIFF_CFLAGS and TIFF_LIBS.
136
137 Always check the output of the configuration script for warnings and errors.
138 In particular, the configuration script might disable the compilation of
139 djview if it cannot locate the required libraries and utilities. The warning
140 messages are the only way to know.
141
142 3.3 - MAKE
143 ----------
144
145 You can then perform the compilation by typing
146
147 $ make
148
149 The compilation can last a few minutes. Again check the output for warnings
150 and errors. Finally a brief message lets you know that the compilation was
151 successful. You can then proceed with the installation.
152
153 3.4 - INSTALL
154 ------------
155
156 Typing:
157
158 $ make install
159
160 or if necessary:
161
162 $ sudo make install
163
164 should:
165
166 - install the executable programs into "${prefix}/bin/".
167 - possibly install the shared library into "${prefix}/lib/".
168 - install the man pages under "${prefix}/man or ${prefix}/share/man/".
169 - install various ancillary files under "${prefix}/share/djvu/".
170 - install "${prefix}/share/pkgconfig.pc".
171 - optionally install the icon and mime type information files
172
173 Where ${prefix} refers to the directory specified by the prefix option
174 of the configuration script, which defaults to "/usr/local", and the
175 paths above can be fine-tuned using appropriate arguments to
176 ./configure and make.
177
178
179 4 - BUILDING FOR MAC OS X
180 =========================
181
182 We recommend that you first install homebrew and use
183 command "brew install" to obtain the following packages:
184 $ brew install autoconf automake libtool pkg-config
185 $ brew install jpeg libtiff
186
187 Note that homebrew comes with a djvulibre package already.
188 The following instructions explain how to compile djvulibre
189 in a standalone manner. You may want to do that if you want
190 the latest version of djvulibre. Otherwise, chances are
191 that you should just install the djvulibre homebrew package.
192 $ brew install djvulibre
193
194 But most people should find sufficient
195 to just install the homebrew package.
196
197 Then you can run configure
198 $ ./configure --disable-desktopfiles
199
200 Then you can compile with
201 $ make
202
203 Running "make install" will install djvulibre in directory /usr/local.
204 This may not be a good idea as they will interfere with homebrew.
205 You may instead specify an alternate directory with DESTDIR=...
206 $ make install DESTDIR=/usr/local/djvulibre-install
207
208
209
210 5 - BUILDING FOR WINDOWS
211 ========================
212
213 5.1- Using Microsoft Visual C++ 2019
214 ------------------------------------
215
216 See the directory win32.
217 Populate the zlib, jpeg and tiff directories with
218 the open source code suggested in the README files.
219 Check win32/djvulibre/dirs.props to see
220 how to name the directories.
221 Then open win32/djvulibre/djvulibre.sln and compile.
222
223 Next step would then be to follow the instructions
224 in the djview package to create a djview project and
225 add it to this solution. Finally you can use the script
226 djvulibre-install.sh and djvulibre.nsi to prepare
227 the djvulibre+djview installer.
228
229
230 5.2- Using Mingw
231 ----------------
232
233 You must first install the mingw compiler and the msys environment.
234 See www.mingw.org for more information.
235 From the msys shell, run the usual commands
236 $ configure
237 $ make
238 Then collect the djvulibre dll from directory libdjvu/.libs
239 and the executables from directory tools/.libs
240 Please refer to the file INSTALL for information
241 about the arguments of the script 'configure'.
242
243
244 5.3- Using Cygwin
245 -----------------
246
247 Simply run the usual commands
248 $ configure
249 $ make
250 $ make install
251 Please refer to the file INSTALL for information
252 about the arguments of the script 'configure'.
253
254
255