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

Problem of loading shared library when using xpcom

4 views
Skip to first unread message

Keren Dong

unread,
Oct 13, 2006, 3:26:05 AM10/13/06
to dev-tec...@lists.mozilla.org
I need to call a function which is provided by a .so library, but
when running with firefox, it crashed and report:

/libexec/ld-slf.so.1: /usr/X11r6/lib/firefox/components/libtest.so:
Undefined symbol "_Z10getprivkeyPiPPh"

getprivkey() is the function that I need to call.
How to solve this?

Benjamin Smedberg

unread,
Oct 13, 2006, 9:01:46 AM10/13/06
to

What library is getprivkey() supplied by? Are you linking against that
library? Is that function actually exported by the library you think it is?

--BDS

Keren Dong

unread,
Oct 13, 2006, 9:48:58 AM10/13/06
to dev-tec...@lists.mozilla.org
Yes, I'm sure of it.
I have wrote a individual program to test it and it can work fine,
but this is a lib that is written by pure c, is this the problem?

> _______________________________________________
> dev-tech-xpcom mailing list
> dev-tec...@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-xpcom

--
Best regards,
Keren Dong

Institue of Software, Chinese Academy of Sciences
MSN/Gtalk: drago...@gmail.com
AIM: dragonballs1983


Benjamin Smedberg

unread,
Oct 13, 2006, 10:06:05 AM10/13/06
to
Keren Dong wrote:
> Yes, I'm sure of it.
> I have wrote a individual program to test it and it can work fine, but
> this is a lib that is written by pure c, is this the problem?

So this is a library you are providing? Where do you have the library
installed? This sounds like an error in linkage that you will need to solve.
Tools that may help you find the problem include ldd and nm.

--BDS

0 new messages