I'm trying to do the same with v8 5.9.211 on Windows and I have some 
problems.
I created a new Visual Studio 2015 project and added hello-world.cc as its 
source. I setup the include and lib directories in project configuration 
and it builds without any warnings/errors.
As suggested in the Getting Started with Embedding 
<https://github.com/v8/v8/wiki/Getting-Started-with-Embedding> , I copied 
icudtl.dat, natives_blob.bin and snapshot_blob.bin to the directory where 
the executable resides. Screen shot - https://postimg.org/image/78agwcv2wb/

At runtime, it crashes at V8::InitializeICUDefaultLocation(argv[0]); 
- https://github.com/v8/v8/blob/5.9.211/samples/hello-world.cc#L16 
Screenshot - https://postimg.org/image/4rmyjm700b/

Could you please help me?

Thanks,
--Gautham


On Sunday, 12 March 2017 14:25:51 UTC+5:30, Ben Noordhuis wrote:

> On Sun, Mar 12, 2017 at 4:03 AM, Jane Chen <jxch...@gmail.com 
> <javascript:>> wrote: 
> > Embedding v8 5.3. 
> > 
> > This causes v8 to crash: 
> > 
> > (88888888).toLocaleString(); 
> > 
> > 2017-03-07 08:24:07.362 Critical: # Fatal error in , line 0 
> > 2017-03-07 08:24:07.362 Critical: # Failed to create ICU number format, 
> are 
> > ICU data files missing? 
> > 2017-03-07 08:24:07.362 Critical: # 
> > 2017-03-07 08:24:07.362 Critical: 
> > 2017-03-07 08:24:07.362 Critical: ==== C stack trace 
> > =============================== 
> > 2017-03-07 08:24:07.362 Critical: 
> > 2017-03-07 08:24:07.362 Critical:  1: V8_Fatal 
> > 2017-03-07 08:24:07.362 Critical:  2: v8::internal::(anonymous 
> > namespace)::CreateICUNumberFormat(v8::internal::Isolate*, icu_56::Locale 
> > const&, v8::internal::Handle<v8::internal::JSObject>) 
> > 2017-03-07 08:24:07.362 Critical:  3: 
> > v8::internal::Runtime_CreateNumberFormat(int, v8::internal::Object**, 
> > v8::internal::Isolate*) 
> > 2017-03-07 08:24:07.362 Critical:  4: 0xcde49206147 
> > 2017-03-07 08:24:07.362 Critical:  5: 0xcde49270fcf 
> > 2017-03-07 08:24:07.362 Critical: Illegal instruction in thread 
> > 0x0000700016ed9000 addr 0x113aaf1d2 
> > 
> > 
> > My compiled v8_shell executes the same script fine. 
> > 
> > I've got icudtl.dat file under my LD_LIBRARY_PATH.  Is icudtl.dat the 
> data 
> > file?  Or is there some other data file I need to include?  If it is the 
> > data file, where is the right place for it to be locatable by my 
> executable? 
> > 
> > Thanks! 
>
> Hi, Jane.  Yes, icudtl.dat is the data file; icudtb.dat on big-endian 
> systems.  Do you call V8::InitializeICU() or 
> V8::InitializeICUDefaultLocation() before V8::Initialize()? 
>

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to