We should avoid using the bundled libjpeg and libpng sources in favour of those provided by the system so that we can reduce memory use and benefit from security updates made to these code bases independently of the WebKit code base.
Created attachment 15090 Sorry for the large patch! :-) This moves the libjpeg sources into a libjpeg subdir of image-decoders/jpeg directory and updates the GDK port makefiles. This way, JPEGImageDecoder.cpp can use a different libjpeg implementation simply by adding it to the include/lib dirs.
Do we really need to keep libjpeg in the WebKit SVN?
Personally, I'm fine with removing it, I just did it this way as I'm not familiar with how to fix the GDK port build system once WebKit's libjpeg is removed, and I wasn't sure if anyone working on the GDK port would have time to deal with this in the near future.
Created attachment 15134 [details] [GDK] Link to external libjpeg This patch updates the Gdk build files to link to the libjpeg shared library. The bundled libjpeg sources should be removed from the SVN repository when committing this change. So, after the changes, WebCore/platform/image-decoders/jpeg/ should contain only two files: JPEGImageDecoder.cpp JPEGImageDecoder.h
Created attachment 15135 [details] [GDK] Link to external libjpeg and libpng This patch updates the Gdk build files to link to the libjpeg and libpng shared libraries. The bundled libjpeg and libpng sources should be removed from the SVN repository when committing this change. So, after the changes, WebCore/platform/image-decoders/jpeg/ should contain only two files: JPEGImageDecoder.cpp JPEGImageDecoder.h And WebCore/platform/image-decoders/png/ should contain only two files: PNGImageDecoder.cpp PNGImageDecoder.h
When this gets done, it should clear-up http://bugs.webkit.org/show_bug.cgi?id=12058 also. Right?
yes, libpng will be completely removed from WebKit sources. Of course, it's up to each port to make sure they're using an updated libpng without known vulnerabilities. Also, should I produce a new patch removing libjpeg and libpng from sources? That plus Alp's latest patch will completely take care of the issue.
Comment on attachment 15090 We've decided to remove, not move the sources, so this patch is obsolete.
Landed in r23763.