XCode:
-
Note that you'll need XCode, not just the XCode Mac CLI tools, to build/compile Chromium/V8 on Mac.
-
Ensure that you see this:
$ xcode-select --print-path /Applications/Xcode.app/Contents/Developer
and this:
ls `xcode-select -p`/Platforms/MacOSX.platform/Developer/SDKs ... DriverKit, sdk dirs, sdk executables, etc ...
and of course:
g++ --help ... gives us a little manpage like: OVERVIEW: clang LLVM compiler linkerz loaderz oh my!
Contributing:
- Contributing
- See: https://chromium.googlesource.com/chromium/src/+/refs/heads/main/docs/commit_checklist.md
- See https://chromium.googlesource.com/chromium/src/+/master/docs/contributing.md
- Life of a Chromium developer
- Chromium 101 Tutorial, really nice
-
- See V8 issues and Chromium first bugs to fix
- Commit checklist
- Set up repo, build from source
- Building from source
- Check out source code
- Check out source code using depot_tools
- ensure depot_tools in beginning of PATH
- in an empty dir,
fetch v8
- Update dependencies:
gclient sync
git new-branch fix-bug-1234
-
Developer & Commit Workflows (from "Life of a Chromium Developer" by Google)
-
Start work:
git pull --rebase && client gsync
-
Code, compile with Ninja and GN
tools/dev/gm.py x64.release
-
Compile and test:
tools/dev/gm.py x64.release.check
... this takes quite awhile -
# In the src/ directory: $ gn gen out/Default # Set build arguments (such as debug vs release): $ gn args out/Default # Do a build of the ‘chrome’ target: $ autoninja -C out/Default chrome # ‘autoninja’ is preferred over ‘ninja’ # Builds to src/out/ directory, e.g. src/out/Default/chrome # For clean build, delete out/ directory (rarely needed)
-
Make new branch
git checkout -t -b my_new_feature origin/main
-
Iterate on patches:
-
git cl upload
-
git cl try
-
todo
git cl land
- how island
different thantry
-
-
Request review.
- Reviews are at: https://chromium-review.googlesource.com/q/status:open+-is:wip
- Request a review from your V8 workspace, not chromium
- Add your name to AUTHORS file
- For push access, you'll need a
.netrc
file with creds. See https://v8.dev/docs/source-code git cl upload
.
For fetching all branches, add the following into your remote configuration in .git/config:
fetch = +refs/branch-heads/*:refs/remotes/branch-heads/*
fetch = +refs/tags/*:refs/tags/*
Running V8 "locally:" Compile the shell sample and run it as a shell!
Per https://stackoverflow.com/questions/1802478/running-v8-javascript-engine-standalone