added a debugging helper
removed libjpeg