v8 build from source

注意python要2.7 否則在gm.py那一步會失敗

Linux

安裝build環境
https://commondatastorage.googleapis.com/chrome-infra-docs/flat/depot_tools/docs/html/depot_tools_tutorial.html

git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git

export PATH=$PATH:~/depot_tools

mkdir v8
cd v8
fetch v8

注意 在~/v8 下會有.gclient,所以工作目錄不要在home

solutions = [
{
“url”: “https://chromium.googlesource.com/v8/v8.git”,
“managed”: False,
“name”: “v8”,
“deps_file”: “DEPS”,
“custom_deps”: {},
},
]

gclient sync

cd v8
./build/install-build-deps.sh

下面這步是helper script,產生build files, compile, 甚至是test 整合在一步

./tools/dev/gm.py x64.release

This entry was posted in nodejs. Bookmark the permalink.

Leave a Reply