nm -D --defined-only /usr/bin/gs | grep png This is enough to show the amount of libpng functions present. Note that they are present both in /usr/bin/gs and in /usr/lib/libgs.so.
And cartman from Pardus just let me note that there's internal jpeg too. They do use system libraries for those. Also ships with a copy of jasper, but a modified one to that, so it's not possible to use the system copy of that just yet.
jpeg and libpng are gone in app-text/ghostscript-gpl-8.61-r2. zlib remains for now since I was not able to successfully compile ghostscript without the internal one yet.
Which versions of zlib and libpng is bundled?
(In reply to comment #3) > Which versions of zlib and libpng is bundled? > zlib seems to be 1.2.3 and libpng 1.2.22.
Both seems safe security wise ATM.
On a first glance it seems to be a lot worse. ghostscript-gpl comes with a lot of internal libraries such as expat, jasper, jbig2dec, icclib which should be linked dependencies, instead using the internal lib crap. Most disturbing form the maintenance quality pov is that jasper actually was listed as dependency in former ebuilds, but simply removed.
jasper is now also gone thanks to a patch borrowed from Fedora, let's see how it works out. I also rm -rf expat now for the sake of completeness, however I'm unsure if it was used anyway. So the three remaining ones are jbig2dec, icclib and zlib for now.
zlib should be gone now, too in versions >=app-text/ghostscript-gpl-8.63. At least they get rm -rf'd, not exactly sure how to interpret the nm output though.
media-libs/jbig2dec is now in Portage, it would be nice if ghostscript-gpl was patched to use it.
As of 9.00, ghostscript-gpl uses also bundled freetype (due to misunderstanding of configure script) and lcms 1.18. First one would probably be fixed by 'rm -rf "${S}/freetype"', if not for use of ft_glyphslot_free_bitmap, which is freetype internal, doesn't seem to be an option for fixing the other one, though.
I need to correct myself. I've placed the blame on internal freetype functions incorrectly. The real problem lied in configure.ac. I've contacted upstream and was told that head no longer uses that function anyway and the configure.ac problem will be fixed too (the fix is actually trivial). As for lcms, they're using a patched version and in the (hopefully) near future plan to move to 2.x.
With ghostscript 9.01, situation has cleared a bit, but ebuild needs an adjustment - now simply adding 'rm -rf "${S}/freetype"' in src_prepare is enough to use system freetype. Situation of lcms seems unchanged though.
Freetype and lcms removed with >=app-text/ghostscript-gpl-9.02, let's see if it causes any problems.
As of 9.04, ghostscript-gpl builds successfully with system copy of jbig2dec, if the internal copy is removed.
(In reply to comment #14) > As of 9.04, ghostscript-gpl builds successfully with system copy of jbig2dec, > if the internal copy is removed. Indeed. Unbundled in 9.04-r6; some keywords had to be dropped temporarily until arches test and keyword media-libs/jbig2dec.
(In reply to comment #15) > (In reply to comment #14) > > As of 9.04, ghostscript-gpl builds successfully with system copy of jbig2dec, > > if the internal copy is removed. > > Indeed. Unbundled in 9.04-r6; some keywords had to be dropped temporarily > until arches test and keyword media-libs/jbig2dec. All keywords restored now in 9.05
status update: media-libs/icclib is in the tree now, but so far I have not managed yet to build gs against it.
Bundled OpenJPEG is back for ghostscript-gpl-9.09 as per bug #459216 and the upstream answer http://bugs.ghostscript.com/show_bug.cgi?id=694449. Bundled CUPS libs are removed as of ghostscript-gpl-9.09.
Recent ghostscript versions (>=9.07) don't ship with an icclib anymore, it has been replaced by lcms{,2}. Upstream commit: http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=d8ca80d1cb480702c109414c46e381981c94ddcb As OpenJPEG now seems to be the last remaining bundled lib and we can't unbundle it (see comment 18) I'm going to close this bug which kind of evolved to a "tracker" bug anyways. So if any new bundled libraries are spotted, please open a new and separate bug for each. Thanks to everyone involved!