====== JPEG ====== //version: __6b__//\\ //source: [[http://www.ijg.org/]]// This is a part of my [[software:frameworks|UnixImageIO framework]]. An [[uniximageio|Xcode project]] is available to build the framework from sources. ----- libjpeg is a bit old and parts are out-of-date, and there is a bug, so it needs some patching. After expanding the tarball, you need to update some files. First, download this patch for [[/files/macosxport/patches/libtool135update.zip|libtool]], and unzip it into the source. This contains a couple Mac OS X patches to this version of libtool (updating the source to use the latest libtool is too much work). Also, download this [[/files/macosxport/patches/jpegpatch.zip|patch]] for the jpeg makefile and unzip it into the source folder (replace the makefile.cfg there). This corrects install issues. Now, in the source dir: $ cp -f /usr/share/libtool/config.* . $ patch makefile.cfg makefile.cfg.patch Then build for your OSX version: ===== Leopard ===== export MACOSX_DEPLOYMENT_TARGET=10.5 ./configure --enable-shared --disable-static CC=~/bin/ccub_3264 CFLAGS=-Os make sudo make install ===== Tiger ===== export MACOSX_DEPLOYMENT_TARGET=10.4 ./configure --enable-shared --disable-static CC=~/bin/ccub_t CFLAGS=-Os make sudo make install ===== Historical ===== //Old Panther notes.// Something you can do if you want - a patch for a certain type of malformed jpeg-in-tiff created by old Wang software, pretty obscure. You can skip this if you like. You need the libtiff source for this patch: in the libtiff source ''/contrib/ojpeg'', copy the contents of ''jdhuff_add.c'' and paste it at the end of the jpeg source ''jdhuff.c''. There is nothing to configure here, the rest will be taken care of in libtiff. $ ./configure --enable-shared --enable-static $ make $ sudo make install