Best way to unwrap a v8::Handle from CefV8Value?

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

Re: Best way to unwrap a v8::Handle from CefV8Value?

Postby hengchu » Tue Jul 08, 2014 5:02 pm

hengchu wrote:
magreenblatt wrote:
hengchu wrote:I might not be building v8 as an so correctly? Since my project is actually on a mac, so the output is a dylib. All I did was change add 'component' : 'shared_library' to the variables section in v8/tools/gyp/v8.gyp as suggested by the issue.

Are you linking/loading that same v8 dylib into your application instead of using some other dynamic or statically linked version of v8?


I realized I was linking the same v8 static lib all this time... instead of a shared one. Rebuilding now and hopefully that would work.

Just curious, why does it have to be a shared library instead of a static one?


Also it seems that libcef does contain some v8 symbol already? I don't really understand why it does that since we need to link with the v8 lib anyway?
hengchu
Techie
 
Posts: 12
Joined: Tue Jul 01, 2014 6:27 pm

Re: Best way to unwrap a v8::Handle from CefV8Value?

Postby magreenblatt » Tue Jul 08, 2014 5:04 pm

Different instances of v8 will have separate/different internal state. You need to use the same instance to share the same state.
magreenblatt
Site Admin
 
Posts: 12408
Joined: Fri May 29, 2009 6:57 pm

Re: Best way to unwrap a v8::Handle from CefV8Value?

Postby hengchu » Wed Jul 09, 2014 3:11 pm

magreenblatt wrote:Different instances of v8 will have separate/different internal state. You need to use the same instance to share the same state.


Finally got it to work today :) Thank you so much!!

PS: I'd be happy to show people how to do it if anyone else wants to do a similar thing (using cef but still has tight integration with v8).
hengchu
Techie
 
Posts: 12
Joined: Tue Jul 01, 2014 6:27 pm

Previous

Return to Support Forum

Who is online

Users browsing this forum: Google [Bot] and 66 guests