Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

firefox 29 libxul.so has less symbols in its dynamic symbol table.

22 views
Skip to first unread message

Tom Hindle

unread,
Apr 15, 2014, 2:16:50 PM4/15/14
to dev-em...@lists.mozilla.org
Hi,

With firefox 25: (Using Ubuntu 12.04)

Symbols like JS_ContextIterator appear in libxul.so dynamic symbol table.

@:/usr/lib/firefox$ objdump -T ./libxul.so | grep JS_ContextI
01a0e7d0 g DF .text 00000038 xul25.0
_Z18JS_ContextIteratorP9JSRuntimePP9JSContext

However I've noticed with firefox 29 this is no longer the case.

The symbol still show in a non stripped libxul.so

@:obj-i686-pc-linux-gnu/dist/bin$ nm libxul.so | grep JS_ContextI
01ebea70 t _Z18JS_ContextIteratorP9JSRuntimePP9JSContext

I believe that the lower case 't' (rather than 'T') informs that the
symbol isn't visible. (Like a 'C' static function).

I notice that JS_ContextIterator still has a JS_PUBLIC_API macro as part
of its signature. But I'm guessing that
"__attribute__((visibility("default")))" isn't having the desired
effect. I've checked and confirmed that when compiling jsapi.cpp both
HAVE_VISIBILITY_ATTRIBUTE and EXPORT_JS_API are defined.

This change means I can no longer use functions like JS_ContextIterator
from programs dlopenning or linking libxul.so.

On windows I can still use these symbols from xul.dll.

Have these symbols been intentionally hidden on Linux, by some mechanism
I'm not aware of?
Can anyone point me to the cause of these changes?

Thanks
Tom



Benjamin Smedberg

unread,
Apr 15, 2014, 2:22:30 PM4/15/14
to Tom Hindle, dev-em...@lists.mozilla.org
On 4/15/2014 2:16 PM, Tom Hindle wrote:
>
> This change means I can no longer use functions like
> JS_ContextIterator from programs dlopenning or linking libxul.so.
>
> On windows I can still use these symbols from xul.dll.
>
> Have these symbols been intentionally hidden on Linux, by some
> mechanism I'm not aware of?

Yes, and we intend to hide them on Windows as well, once we solve linker
memory issues.

See bug 920731.

--BDS

0 new messages