How to build V8 without “external startup data”?

前提是你 提交于 2019-12-06 13:46:04
Boinst

When using the GYP build process (as you seem to be), pass the argument -Dv8_use_snapshot=false when invoking gyp. That turns off building snapshot data, and you won't need "natives_blob.bin" and "snapshot_blob.bin". My command-line looks like this (for V8 5.3, n.b. the GYP scripts have moved recently):

python.exe gypfiles\gyp_v8 -Dtarget_arch=x64 -Dcomponent=shared_library -Dv8_enable_i18n_support=false -Dv8_use_snapshot=false -G msvs_version=2013

edit: Since this was posted, V8 now takes ~20-30s to start up without snapshot files. This is up from 2-3s before. It is a known behavior and is not considered to be a bug by the V8 developers, per the v8-users mailing list.

static:

make snapshot=off x64.debug

dynamic:

make snapshot=off library=shared x64.debug

I don't know how to do it for visual studio.

It's important to remember that the build process is constantly being changed by google and that it is optimized for google employees and often horrendously esoteric for anyone outside of google.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!