- Notifications
You must be signed in to change notification settings - Fork 2.5k
Windows Development Environment
You should follow the steps from Chromium's Checking out and Building Chromium for Windows guide stopping before the Get the code
step
Before you begin, make sure your system satisfies the system requirements.
Exclusions should be added for working directories in any active antivirus software (Defender Antivirus is enabled by default).
Install Visual Studio Community 2022 Update 17.8.3, following the instructions in the "Visual Studio" section of the Chromium Windows build instructions. Later versions will probably work, too. The Windows 11 SDK mentioned in Chromium's documentation also works on Windows 10.
For Visual Studio and Windows SDK versions also see https://github.com/google/omaha/blob/main/doc/DeveloperSetupGuide.md#currently-the-supported-toolchain-is-visual-studio-2019-update-161110-and-windows-sdk-100220000.
If you need to clone brave-core
or another repo on Windows, install Git (version 2.41 or higher) from https://git-scm.com/downloads. Do not use the version of Git included in depot_tools
, since it's incompatible with Brave's patching system.
After installing Git, configure it according to the "Get the Code" section of the Chromium Windows build instructions, paying specific attention to the git config --global
commands.
Install Node.js v20 from https://nodejs.org/. In general, the Brave development environment expects and supports only the LTS version of Node.js.
Install Python v3 from https://www.python.org/downloads/windows/. When building, the system uses the depot_tools
version of Python. Some legacy scripts require Python 2.7.
Python is included in depot_tools
. At the moment, there are known issues calling out to Python if your system has the version from depot_tools
PATH'ed.
Now you are ready to follow the next step of the build instructions in the wiki.
Developers who work at Brave can find more information on remote build execution here
Please refer to this document for information about configuring your .env
for building Brave.
It's always best to run Brave from a standard cmd.exe
shell or via Windows Explorer. There are instances where debug builds of Brave attempt to log to stderr, which will fail and potentially result in unexpected crashes in non-standard shells (e.g., Cygwin, Git for Windows, etc.)
The upstream documentation for Checking out and Building Chromium on Windows has a lot of useful information on configuring Windows, resolving common problems, speeding up builds, etc.
We recommend cloning the brave-browser
Git repository to the top level of your C:\
drive because:
- Some developers have encountered problems with paths exceeding 256 chars when cloning the repository to a subdirectory.
- Some developers have encountered problems with paths that contain spaces (e.g., the path to your home directory, if your username contains spaces, etc.) and some of Chromium's build tools.