IJG JPEG 6a for BeBox README (96/07/21) Ported by Jake Hamby (jehamby@lightside.com) -------------------------------------------- This is a port of the latest version of the Independent JPEG Group's free JPEG software, containing a shared library (libjpeg) and utilities to read/write JPEG images. libjpeg is currently used by my port of Ghostscript 4.01, but any program which needs to read/write JPEG images can take advantage of it. Installation: ------------- Simply run the enclosed setup.sh shell script. It will copy the libjpeg shared library to /system/lib, along with its .xMAP file (used for debugging programs which use libjpeg). Finally, it will verify that all of the utilities work, using the enclosed test images (the filenames which start with "test"). There should not be any messages between "Testing JPEG utilities" and "Done." If so, there is something wrong. Uninstallation: --------------- If you decide to uninstall libjpeg, you only need to delete the files "libjpeg.so" and "libjpeg.so.xMAP" from the /system/lib directory. Using the JPEG utilities: ------------------------- Here is a brief one-line summary of each JPEG utility. For more information, I have formatted the UNIX man pages for each utility, and placed them in the doc folder. Please read them with "less", as they have embedded backspaces that the text editors can't handle. You can also get a quick summary of the options each utility uses by running it with the "-h" flag. cjpeg: Compress PPM/PGM, GIF, Targa, and BMP files into JPEG images. djpeg: Decompress a JPEG into a PPM/PGM, GIF, Targa, or BMP. jpegtran: Translate a JPEG from one variant into another. rdjpgcom: Read any comments in a JPEG image. wrjpgcom: Write a comment block to a JPEG file. Compiling programs which use libjpeg: ------------------------------------- To compile programs which use libjpeg, you will need to copy all of the files in the "include" folder to the directory in which that program expects them (in the case of Ghostscript, the jpeg-6a subdirectory), or put them in a standard place (I use /boot/local/include) and include that directory in the Makefile (-I/boot/local/include). In the linking phase, if you are building a standard executable, use the "-ljpeg" flag to link with libjpeg. Troubleshooting: ---------------- If you receive a "cannot execute binary file" or "Error launching..." message when attempting to run a program which requires libjpeg, verify that libjpeg.so is present in /system/lib. If you have any other problems, please e-mail me: jehamby@lightside.com Building from source: --------------------- Building libjpeg from source code is very simple. Simply download the libjpeg source code from one of the following locations: ftp://ftp.uu.net/graphics/jpeg/jpegsrc.v6a.tar.gz http://absinthe.lightside.net/~jehamby/Be/src/jpegsrc.v6a.tar.gz Extract the archive, and copy the enclosed makefile into the jpeg-6a directory. Run "make all test" to compile and test the shared library. "make install" will install the library into /system/lib, the utilities in /boot/local/bin, man pages in /boot/local/man/man1, and header files into /boot/local/include. See the makefile for more information. For more information: --------------------- I've included the original JPEG README file, as well as all of the documentation from the original package in the doc folder. New versions of this, and other BeBox programs are available from my Web page: http://absinthe.lightside.net/~jehamby/Be/ Please send all comments and suggestions about the BeBox version of JPEG to: jehamby@lightside.com Enjoy!