zsh-workers
 help / color / mirror / code / Atom feed
* flex symbols being exported
@ 2009-02-19 21:40 Diego E. 'Flameeyes' Pettenò
  2009-02-20 10:22 ` Peter Stephenson
  0 siblings, 1 reply; 2+ messages in thread
From: Diego E. 'Flameeyes' Pettenò @ 2009-02-19 21:40 UTC (permalink / raw)
  To: zsh-workers

[-- Attachment #1: Type: text/plain, Size: 1002 bytes --]

Hello,

I'm a Gentoo Linux developer, and since last year I'm working on rooting
away problems with linking collision between software. In particular,
right now I'm working toward reducing issues with exported flex/yacc
symbols for parsers [1].

Zsh seems to be exporting quite a bit of symbols; while most of the
interface is used by the plugins, there seems to be also the parser's
symbols being exported:

yamato ~ # nm -D /bin/zsh | grep yy
08088310 T yylex
080e05f0 B yytext

I guess this comes from flex, at any rate the yylex symbol is widely
defined (50 times on my tinderbox results) and it should probably not be
avoided.

You should either hide the symbols (either via proper ELF visibility or
through linker scripts) or rename them asking for a prefixed version of
them.

HTH,

[1]
http://blog.flameeyes.eu/2008/02/09/flex-and-linking-conflicts-or-a-possible-reason-why-php-and-recode-are-so-crashy

-- 
Diego "Flameeyes" Pettenò
http://blog.flameeyes.eu/


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: flex symbols being exported
  2009-02-19 21:40 flex symbols being exported Diego E. 'Flameeyes' Pettenò
@ 2009-02-20 10:22 ` Peter Stephenson
  0 siblings, 0 replies; 2+ messages in thread
From: Peter Stephenson @ 2009-02-20 10:22 UTC (permalink / raw)
  To: Diego E. 'Flameeyes' Pettenò; +Cc: zsh-workers

On Thu, 19 Feb 2009 22:40:02 +0100
"Diego E. 'Flameeyes'" Pettenò <flameeyes@gmail.com> wrote:
> Zsh seems to be exporting quite a bit of symbols; while most of the
> interface is used by the plugins, there seems to be also the parser's
> symbols being exported:
> 
> yamato ~ # nm -D /bin/zsh | grep yy
> 08088310 T yylex
> 080e05f0 B yytext

These are actually internal symbols---there's no particular intention to
export them, but as the shell gets linked against its own dependent libraries
they're visible by default on many systems.

I'll commit a patch to remain them to zshlex and zshlextext.

-- 
Peter Stephenson <pws@csr.com>                  Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK                          Tel: +44 (0)1223 692070


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-02-20 10:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-19 21:40 flex symbols being exported Diego E. 'Flameeyes' Pettenò
2009-02-20 10:22 ` Peter Stephenson

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).