-
Notifications
You must be signed in to change notification settings - Fork 2.3k
macOS Development Environment
You will need the prerequisites below to build Brave on macOS 10.15+.
Xcode 13.1 or higher is recommended and needed for official builds. Xcode 12.5 can be used in development for now with component builds.
You'll want an SDK setup like this:
ls -la /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
MacOSX.sdk -> /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk
MacOSX11.3.sdk -> /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk
MacOSX12.0.sdk
You can get the 12.0 SDK from https://ci.brave.com/userContent/ (VPN required)
There are additional details in the Chromium build system requirements at https://chromium.googlesource.com/chromium/src/+/lkgr/docs/mac_build_instructions.md#system-requirements (do not follow any of the instructions after system requirements):
- NodeJS LTS Version (
brew install node
) - can also usenvm
If
node --version
fails when installingnode@12
through Homebrew or reports a different version, runbrew link --force --overwrite node
- npm (or Yarn)
npm is automatically installed if you install NodeJS through Homebrew Note: If you'd like to use
yarn
instead ofnpm
you can useyarn import
to create ayarn.lock
file from ourpackage-lock.json
.
- Make sure you have Spotlight fully off or privacy on for the build directory (or indexing will slow it down). System Preferences -> Spotlight -> Privacy