Skip to content

Custom GCC and cross compilers

mistydemeo edited this page Jan 25, 2012 · 6 revisions

Homebrew depends on having a relatively recent version of Xcode. This means 3.1.4 on Leopard and 3.2.x on Snow Leopard. Xcode comes with specific versions of GCC and autotools, as well as LLVM-GCC and Clang.

Installing a custom version of GCC or autotools into the $PATH has the potential to break lots of compiles. So we stick to the Apple-provided compilers. There is an LLVM formula, but Homebrew (no longer) uses LLVM by default for compiles.

For cross-compilers based on GCC, these brews will typically be "keg-only", and not linked into the path by default.

Rather than merging in brews for either of these cases at this time, we're listing them on this page. If you come up with a formula for a new version of GCC or cross-compiler suite, please link it in here.

  • Homebrew-alt provides a binary gcc-4.2 formula for use with Xcode 4.2+. It can be installed with: brew install https://raw.github.com/adamv/homebrew-alt/master/duplicates/apple-gcc42.rb
  • GCC 4.5.1
  • Homebrew-alt also provides an up to date GCC duplicate. Homebrew can install directly from a URL: brew install https://github.com/adamv/homebrew-alt/raw/master/duplicates/gcc.rb
  • MSP430 development
Clone this wiki locally