Before you download and build the Android source, ensure your system meets the following requirements then see Establishing a Build Environment for installation instructions by operating system.

Hardware requirements

Your development workstation should meet or exceed these hardware requirements:

  • A 64-bit environment is required for Android 2.3.x (Gingerbread) and higher versions, including the master branch. You can compile older versions on 32-bit systems.
  • At least 250GB of free disk space to checkout the code and an extra 150GB to build it. If you conduct multiple builds, you will need even more space.
  • If you are running Linux in a virtual machine, you need at least 16GB of RAM/swap.

Software requirements

The Android Open Source Project (AOSP) master branch is traditionally developed and tested on Ubuntu Long Term Support (LTS) releases, but other distributions may be used. See the list below for recommended versions.

Your workstation must have the software listed below. See Establishing a Build Environment for additional required packages and the commands to install them.

OS and JDK

If you are developing against the AOSP master branch, use one of these operating systems: Ubuntu 14.04 (Trusty) or Mac OS v10.10 (Yosemite) or later with Xcode 4.5.2 and Command Line Tools.

For the Java Development Kit (JDK), note the master branch of Android in AOSP comes with a prebuilt version of OpenJDK; so no additional installation is required. Older versions require a separate install.

See Packages for older versions.

Key packages

Device binaries

Download previews, factory images, drivers, over-the-air (OTA) updates, and other blobs below. For details, see Obtaining proprietary binaries.

Build toolchain

Android 8.0 and higher support only Clang/LLVM for building the Android platform. Join the android-llvm group to pose questions and get help. Report NDK/compiler issues at the NDK GitHub.

For the Native Development Kit (NDK) and legacy kernels, GCC 4.9 included in the AOSP master branch (under prebuilts/) may also be used.

Packages for older versions

This section details operating systems and JDK packages for older versions of Android.

Operating systems

Android is typically built with a GNU/Linux or Mac OS operating system. It is also possible to build Android in a virtual machine on unsupported systems such as Windows.

We recommend building on GNU/Linux instead of another operating system. The Android build system normally uses ART, running on the build machine, to pre-compile system dex files. Since ART is able to run only on Linux, the build system skips this pre-compilation step on non-Linux operating systems, resulting in an Android build with reduced performance.

  • Android 6.0 (Marshmallow) - AOSP master: Ubuntu 14.04 (Trusty)
  • Android 2.3.x (Gingerbread) - Android 5.x (Lollipop): Ubuntu 12.04 (Precise)
  • Android 1.5 (Cupcake) - Android 2.2.x (Froyo): Ubuntu 10.04 (Lucid)
Mac OS (Intel/x86)
  • Android 6.0 (Marshmallow) - AOSP master: Mac OS v10.10 (Yosemite) or higher with Xcode 4.5.2 and Command Line Tools
  • Android 5.x (Lollipop): Mac OS v10.8 (Mountain Lion) with Xcode 4.5.2 and Command Line Tools
  • Android 4.1.x-4.3.x (Jelly Bean) - Android 4.4.x (KitKat): Mac OS v10.6 (Snow Leopard) or Mac OS X v10.7 (Lion) and Xcode 4.2 (Apple's Developer Tools)
  • Android 1.5 (Cupcake) - Android 4.0.x (Ice Cream Sandwich): Mac OS v10.5 (Leopard) or Mac OS X v10.6 (Snow Leopard) and the Mac OS X v10.5 SDK


See Installing the JDK for the prebuilt path and installation instructions for older versions.


To avoid build errors, Android 4.0.x (Ice Cream Sandwich) and earlier must revert from make 3.82.