Android 소스의 Android 최신 출시 브랜치(android16-release)를 다운로드하고 빌드하기 전에 하드웨어가 필수 요구사항을 충족하는지 필수 소프트웨어가 적절히 설치되어 있는지 확인해야 합니다. 다음 용어도 알고 있어야 합니다.
Git
Git은 오픈소스로 배포된 무료 버전 제어 시스템입니다.
Android는 브랜칭, 커밋, diff, 수정사항과 같은 로컬 작업에 Git를 사용합니다. Git에 관한 자세한 내용은 Git 문서를 참고하세요.
Repo
Repo는 여러 Git 저장소에 걸쳐 복잡한 작업의 실행을 간소화하는 Git의 Python 래퍼입니다. Repo는 모든 버전 제어 작업에서 Git을 대체하지 않으며 복잡한 Git 작업을 쉽게 달성할 수 있도록 할 뿐입니다. Repo는 매니페스트 파일을 이용하여 Android 슈퍼 프로젝트에 Git 프로젝트를 집계합니다.
매니페스트 파일
매니페스트 파일은 Android 소스의 다양한 Git 프로젝트가 AOSP 소스 트리 내에 배치되는 위치를 지정하는 XML 파일입니다.
하드웨어 요구사항 충족
개발 워크스테이션은 다음 하드웨어 요구사항을 충족하거나 초과해야 합니다.
64비트 x86 시스템
코드를 체크아웃하고 빌드하려면 디스크 여유 공간이 400GB 이상 있어야 합니다(체크아웃하는 데 250GB, 빌드하는 데 150GB).
64GB 이상의 RAM. Google에서는 RAM이 64GB인 72코어 머신을 사용하여 Android를 빌드합니다. 이 하드웨어 구성을 사용하면 Android 전체 빌드에 약 40분이 소요되며 Android의 증분 빌드에는 몇 분밖에 걸리지 않습니다. 이와 대조적으로 RAM이 64GB인 6코어 머신을 사용하면 전체 빌드에 약 6시간이 걸립니다.
운영체제 요구사항 충족
개발 워크스테이션은 GNU C 라이브러리(glibc)가 2.17 이상인 64비트 Linux 배포판을 실행해야 합니다.
필수 패키지 설치
Android 11 이상을 빌드하려면 Ubuntu 18.04 이상을 사용해야 합니다. Ubuntu 18.04 이상을 위한 필수 패키지를 설치하려면 다음 명령어를 실행하세요.
설치된 패키지 중에서 이 명령어는 Git을 설치하며 Git은 AOSP 소스를 다운로드하는 데 사용됩니다.
필수 소프트웨어 설치
AOSP를 사용하려면 OpenJDK, Make, Python 3, Repo가 설치되어 있어야 합니다. Android의 최신 출시 브랜치는 사전 빌드된 버전의 OpenJDK, Make, Python 3가 함께 제공되므로 설치 단계가 추가로 필요하지 않습니다. 다음 섹션에서는 Repo 설치 방법을 설명합니다.
Repo 설치
Repo를 설치하려면 다음 단계를 따르세요.
현재 패키지 정보를 다운로드합니다.
sudoapt-getupdate
다음 명령어를 실행하여 Repo 런처를 설치합니다.
sudoapt-getinstallrepo
Repo 런처가 제공하는 Python 스크립트를 사용하여 체크아웃을 초기화하고 전체 Repo 도구를 다운로드합니다.
이 페이지에 나와 있는 콘텐츠와 코드 샘플에는 콘텐츠 라이선스에서 설명하는 라이선스가 적용됩니다. 자바 및 OpenJDK는 Oracle 및 Oracle 계열사의 상표 또는 등록 상표입니다.
최종 업데이트: 2025-07-27(UTC)
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["필요한 정보가 없음","missingTheInformationINeed","thumb-down"],["너무 복잡함/단계 수가 너무 많음","tooComplicatedTooManySteps","thumb-down"],["오래됨","outOfDate","thumb-down"],["번역 문제","translationIssue","thumb-down"],["샘플/코드 문제","samplesCodeIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-07-27(UTC)"],[],[],null,["# Set up for AOSP development (9.0 or later)\n\nBefore you download and build the Android latest release branch\n(android16-release) of the Android source, ensure\nthat your hardware meets the necessary requirements and that required software\nis properly installed. You should also be familiar with the following terms:\n\n*Git*\n: Git is a free and open source distributed version control system.\n Android uses Git for local operations such as branching, commits, diffs,\n and edits. For help learning Git, refer to the [Git documentation](https://git-scm.com/doc).\n\n*Repo*\n: Repo is a Python wrapper around Git that simplifies performing\n complex operations across multiple Git repositories. Repo doesn't replace Git\n for all version control operations, it only makes complex Git operations easier\n to accomplish. Repo uses manifest files to aggregate Git projects into the\n Android superproject.\n\n*Manifest file*\n: A manifest file is an XML file specifying where the various Git projects in\n the Android source are placed within an AOSP source tree.\n| **Note:** All commands in this documentation are preceded by a dollar sign ($) to differentiate them from output or entries within files. To copy a command to the clipboard, click the **Copy code sample** icon in the top right of each command box.\n| **Note:** If you want to build Android 2.3 - 8.0, refer to [Set up for AOSP development (2.3 - 8.0)](/docs/setup/start/older-versions).\n\nMeet hardware requirements\n--------------------------\n\nYour development workstation should meet or exceed these hardware\nrequirements:\n\n- A 64-bit x86 system.\n\n | **Note:** You can compile AOSP versions previous to 2.3.x on 32-bit systems.\n- At least 400 GB of free disk space to check out and build the code\n (250 GB to check out + 150 GB to build).\n\n | **Note:** If you're checking out a mirror, you need more space because the full Android Open Source Project (AOSP) mirrors contain all Git repositories that have ever been used.\n- A minimum of 64 GB of RAM. Google uses 72-core machines with 64 GB\n of RAM to build Android. With this hardware configuration, it takes\n approximately 40 minutes for a full build of Android and only a few minutes for incremental build of Android. By contrast, it takes approximately 6 hours for a\n full build with a 6-core machine with 64 GB of RAM.\n\nMeet operating system requirements\n----------------------------------\n\nYour development workstation must run any 64-bit Linux distribution with GNU C\nLibrary (glibc) 2.17 or later.\n| **Warning:** Android OS development on macOS isn't supported as of June 22, 2021 (Android 11). For information on configuring your development workstation for macOS, refer to [Set Up for AOSP development (2.3 - 8.0)](/docs/setup/start/older-versions).\n\nInstall required packages\n-------------------------\n\nTo build Android 11 or higher, you must use Ubuntu 18.04 or later. To install\nrequired packages for Ubuntu 18.04 or later, run the following command: \n\n sudo apt-get install git-core gnupg flex bison build-essential zip curl zlib1g-dev libc6-dev-i386 x11proto-core-dev libx11-dev lib32z1-dev libgl1-mesa-dev libxml2-utils xsltproc unzip fontconfig\n\nAmong the packages installed, this command installs Git, which is used to\ndownload the AOSP source.\n| **Note:** This command works for Ubuntu 18.04 or later. For package installation for earlier versions of Ubuntu, see [Setup for Android development (AOSP 2.3 - 8)](/docs/setup/start/older-versions).\n\nInstall required software\n-------------------------\n\nBefore you can work with AOSP, you must have installations of OpenJDK, Make,\nPython 3, and Repo. The latest release branch of Android comes with prebuilt\nversions of OpenJDK, Make, and Python 3, so additional installation steps aren't\nrequired. The following section explains how to install Repo.\n\n### Install Repo\n\nFollow these steps to install Repo:\n\n1. Download the current package information:\n\n sudo apt-get update\n\n2. Run the following command to install the Repo launcher:\n\n sudo apt-get install repo\n\n The Repo launcher provides a Python script that initializes a checkout\n and downloads the full Repo tool.\n\n If successful, skip to step 4.\n3. (optional) Manually install Repo using the following series of commands:\n\n export REPO=$(mktemp /tmp/repo.XXXXXXXXX)\n curl -o ${REPO} https://storage.googleapis.com/git-repo-downloads/repo\n gpg --recv-keys 8BB9AD793E8E6153AF0F9A4416530D5E920F5C65\n curl -s https://storage.googleapis.com/git-repo-downloads/repo.asc | gpg --verify - ${REPO} && install -m 755 ${REPO} ~/bin/repo\n\n The first three commands set up a temp file, download Repo to the file, and\n verify that the key provided matches the required key. If these commands are\n successful, the final command installs the Repo launcher.\n4. Verify the Repo launcher version:\n\n repo version\n\n The output should indicate a version of 2.4 or higher, for example:\n\n `repo launcher version 2.45`\n\nSet an alternative output directory\n-----------------------------------\n\nBy default, the output of each build is stored in the `out/` subdirectory of\nthe matching source tree. You can override this directory by exporting the\n`OUT_DIR` environment variable. For example, if you want to store your output\non a different drive, you can point `OUT_DIR` to that drive: \n\n export OUT_DIR=\u003cvar translate=\"no\"\u003emy_other_drive\u003c/var\u003e\n\nWhat's next?\n------------\n\n- To download the source code, continue to [Download the Android source](/docs/setup/download).\n- For help learning Git, see the [Git documentation](https://git-scm.com/doc).\n- For additional Repo documentation, see the [Repo README](https://gerrit.googlesource.com/git-repo/+/refs/heads/main/README.md).\n- For a list of all Repo commands, refer to the [Repo command reference](/docs/setup/reference/repo)."]]