Skip to content

macOS Development Environment

Mihai PLESA edited this page Nov 8, 2022 · 46 revisions

Prerequisites

You will need the prerequisites below to build Brave on macOS 10.15+.

macOS SDK 12.3 is needed as per https://source.chromium.org/chromium/chromium/src/+/main:build/config/mac/mac_sdk.gni;l=43. This is bundled with Xcode 13.3+ as per https://xcodereleases.com/

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):

  • Node.js active LTS version (v18+) - brew install node or can also use nvm. If node --version fails when installing node@18 through Homebrew or reports a different version, run brew link --force --overwrite node
  • npm - v8+ (or Yarn). npm is automatically installed if you install NodeJS through Homebrew. If you'd like to use yarn instead of npm you can use yarn import to create a yarn.lock file from our package-lock.json.
  • Python - 2.7 and 3+ - Note: On macOS 12.3 and higher Python 2.7 is no longer included by default and you will have to install it manually

Other tips

  • Make sure you have Spotlight fully off or privacy on for the build directory (or indexing will slow it down). System Preferences -> Spotlight -> Privacy
Clone this wiki locally