xv is a great X11 program that displays images in a wide variety of formats including GIF, JPEG, PPM and PNG. It's great because it's simple, not too bloated and fast. See http://www.trilon.com/xv/.
This is a pre-compiled binary version patched to work on Mac OS X 10.3.9 (it may work on others). It links against:
% otool -L xv
xv:
/usr/X11R6/lib/libX11.6.dylib (compatibility version 6.2.0, current version 6.2.0)
/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 71.1.3)
I applied the patches for xv from the FreeBSD Ports Collection then used the libjpeg and libpng from the Fink Project. I declared the variable 'NeXT' so that xv would compile against Darwin's libraries. Finally it was compiled with the -O3 option using GCC 3.3.
If you manage to do anything interesting with this, find it works on other Mac OS X or Darwin versions please let me know. My address is alex at this domain name.
xv copyright 1994 John Bradley
FreeBSD Patches copyright the FreeBSD Project under the BSD Licence