Building V8 from source
In order to be able to build V8 from scratch on Windows/Linux/macOS for x64, please follow the following steps.
Getting the V8 source code #
Follow the instructions in our guide on checking out the V8 source code.
Installing build dependencies #
For macOS: install Xcode and accept its license agreement. (If you’ve installed the command-line tools separately, remove them first.)
Make sure that you are in the V8 source directory. If you followed every step in the previous section, you’re already at the right location.
Download all the build dependencies:
This step is only needed on Linux. Install additional build dependencies:
Building V8 #
Make sure that you are in the V8 source directory on the
Pull in the latest changes and install any new build dependencies:
git pull && gclient sync
Compile the source:
Or, to compile the source and immediately run the tests:
For more information on the
gm.pyhelper script and the commands it triggers, see Building with GN.