Both SilkJS and v8cgi support loading of dynamic libraries.  It is tricky to 
get working.

To the best of my knowledge:

The problem is you have v8 as a static library.  It needs to be a shared one 
and the shared library (testplugin) needs to be linked against libv8.so and 
every other library it calls.

See this for an example build script:
https://github.com/mschwartz/SilkJS-redis/blob/master/build.js



On Sep 27, 2012, at 10:07 PM, Moritz Willig <[email protected]> wrote:

> Hi CodeJunkie,
> i know NodeJS and have already build some Projects with it. But I want to 
> learn how to solve this problem this in general. As far as i see does NodeJS 
> also provide Plugins but they have to be linked statically into the program 
> (or have to be written in JS itself).
> Maybe I switch to NodeJS later but at the moment i would like to learn how to 
> do this on my own.
> 
> Am Donnerstag, 27. September 2012 23:21:18 UTC+2 schrieb CodeJunkie:
> http://nodejs.org/ 
> 
> On Thu, Sep 27, 2012 at 1:58 PM, Moritz Willig <[email protected]> wrote: 
> > Hello, 
> > I'm new to C++ and of course to the V8 engine, too. I would like to create 
> > an javascript service to send request to a server (something similar 
> > accessing an SQL Server). My main application code is executing without 
> > problems (i included V8 as a static library), but every time I try 
> > accessing 
> > an plugin in an shared library, it produces many errors like " symbol 
> > lookup 
> > error: ./libs/testplugin.so: undefined symbol: 
> > _ZN2v816FunctionTemplate16InstanceTemplateEv". I have really no idea how to 
> > solve this errors. I have already searched solutions for this, but no one 
> > worked for me. I assume that my program isn't able to find the matching v8 
> > symbols. I have already added -Wl,-export-dynamic to the linker options, 
> > but 
> > it still is not loading the library at runtime. 
> > 
> > I would be very grateful for any kind of advise or solution on this problem 
> > 
> > Regards, Moritz 
> > 
> > -- 
> > v8-users mailing list 
> > [email protected] 
> > http://groups.google.com/group/v8-users 
> 
> -- 
> v8-users mailing list
> [email protected]
> http://groups.google.com/group/v8-users

-- 
v8-users mailing list
[email protected]
http://groups.google.com/group/v8-users

Reply via email to