Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 32764 - zlib shared library exposes too many symbols
Summary: zlib shared library exposes too many symbols
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Martin Schlemmer (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-04 20:16 UTC by Danek Duvall
Modified: 2010-07-14 07:43 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Aforementioned patch (zlib.mapfile.patch,1.83 KB, patch)
2003-11-04 20:17 UTC, Danek Duvall
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Danek Duvall 2003-11-04 20:16:49 UTC
I sent the following bug report to the maintainers, too, but thought I'd file it here for good measure.

When building zlib as a shared library, it is possible on a number of
platforms to make symbols which are entirely internal to the library
invisible to anything linking to it.  Solaris uses what it calls a
mapfile, and GNU ld uses a version script, but they're exactly the same
thing (for these purposes, at any rate).

This came up because a recent build of zsh broke due to it defining a
function, zcalloc(), which was duplicated in zlib, even though it's not
part of the official zlib interface.

The attached patch works on Linux and Solaris, and "make test" passes.
The version of zlib shipped in Solaris uses the exact same mapfile, so
it should be well tested.

(For completeness, the Solaris version uses an LDSHARED set to

    -G -KPIC -h libz.so.1 -z defs -z text -z combreloc -M mapfile -L.  -lc

but that's somewhat beyond the scope of this bug report.)
Comment 1 Danek Duvall 2003-11-04 20:17:16 UTC
Created attachment 20277 [details, diff]
Aforementioned patch
Comment 2 Martin Schlemmer (RETIRED) gentoo-dev 2003-11-06 13:59:53 UTC
Did you receive any feedback from the zlib guys yet ?
Comment 3 Danek Duvall 2003-11-06 14:02:33 UTC
Nope.  I'll follow-up when I do, but I don't have any sense for how responsive
they are, so no guarantees on when that might be.  :)
Comment 4 Martin Schlemmer (RETIRED) gentoo-dev 2003-11-06 14:45:11 UTC
Ok, added in -r4.
Comment 5 Enrico 'nekrad' Weigelt 2010-07-14 07:43:14 UTC
Could you please check if this issue (and thus the patch still necessary) in recent zlib release ?