플랫폼 아키텍처
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
Android는 다양한 기기와 폼 팩터에 사용할 수 있도록 제작된 Linux 기반의 오픈소스 소프트웨어 스택입니다. 그림 1은 Android 플랫폼의 주요 구성요소를 보여줍니다.
그림 1. Android 소프트웨어 스택
Linux 커널
Android 플랫폼의 기초는 Linux 커널입니다. 예를 들어, Android 런타임(ART)는 스레딩 및 하위 수준의 메모리 관리와 같은 기본 기능에 Linux 커널을 사용합니다.
Linux 커널을 사용하면 Android에서 주요 보안 기능을 활용할 수 있으며 기기 제조업체에서 잘 알려진 커널용 하드웨어 드라이버를 개발할 수 있습니다.
하드웨어 추상화 계층(HAL)
하드웨어 추상화 계층(HAL)은 상위 수준의 Java API 프레임워크에 기기 하드웨어 기능을 노출하는 표준 인터페이스를 제공합니다. HAL은 여러 라이브러리 모듈로 구성되며, 각 모듈은 카메라 또는 블루투스 모듈과 같은 특정 유형의 하드웨어 구성요소를 위한 인터페이스를 구현합니다.
프레임워크 API가 기기 하드웨어에 액세스하기 위해 호출을 수행하면 Android 시스템이 해당 하드웨어 구성요소에 대한 라이브러리 모듈을 로드합니다.
Android 런타임
Android 버전 5.0(API 수준 21) 이상을 실행하는 기기의 경우, 각 앱이 자체 프로세스 내에서 자체 he Android 런타임(ART) 인스턴스로 실행됩니다. ART는 DEX(Dalvik Executable) 형식 파일을 실행하여 저용량 메모리 기기에서 여러 가상 머신을 실행하도록 작성되었습니다. DEX(Dalvik Executable 형식) 파일은 Android용으로 특별히 설계된 바이트 코드 형식으로, 최소 메모리 공간에 맞게 최적화되어 있습니다. d8
와 같은 빌드 도구는 자바 소스를 Android 플랫폼에서 실행할 수 있는 DEX 바이트 코드로 컴파일합니다.
ART의 주요 기능 중 몇 가지를 살펴보자면 다음과 같습니다.
- AOT(Ahead-Of-Time) 및 JIT(Just-In-Time) 컴파일
- 최적화된 가비지 컬렉션(GC)
- Android 9 (API 수준 28) 이상에서는 앱 패키지의 DEX 파일을 더 간결한 기계어 코드로 변환합니다.
- 전용 샘플링 프로파일러, 상세 진단 예외 및 오류 보고, watchpoint를 설정하여 특정 필드를 모니터링할 수 있는 기능을 비롯한 향상된 디버깅 지원 기능
Android 버전 5.0(API 수준 21) 이전 버전에서는 Dalvik이 Android 런타임이었습니다.
앱이 ART에서 잘 실행되면 Dalvik에서도 제대로 작동할 수 있지만 그 반대의 경우 제대로 작동하지 않을 수 있습니다.
Android에는 Java API 프레임워크가 사용하는 몇 가지 자바 8 언어 기능을 포함하여 대부분의 자바 프로그래밍 언어 기능을 제공하는 일련의 핵심 런타임 라이브러리도 포함되어 있습니다.
네이티브 C/C++ 라이브러리
ART 및 HAL과 같은 많은 핵심 Android 시스템 구성요소 및 서비스는 C 및 C++로 작성된 네이티브 라이브러리가 필요한 네이티브 코드에서 빌드됩니다. Android 플랫폼은 Java 프레임워크 API를 제공하여 이러한 일부 네이티브 라이브러리의 기능을 앱에 노출합니다. 예를 들어, Android 프레임워크의 Java OpenGL API를 통해 OpenGL ES에 액세스하여 앱에서 2D 및 3D 그래픽을 그리고 조작할 수 있는 지원 기능을 추가할 수 있습니다.
C 또는 C++ 코드가 필요한 앱을 개발하는 경우에는 Android NDK를 사용하여 네이티브 코드에서 직접 이러한 몇몇 네이티브 플랫폼 라이브러리에 액세스할 수 있습니다.
Java API 프레임워크
Android OS의 전체 기능 세트는 자바 언어로 작성된 API를 통해 액세스할 수 있습니다. 이러한 API는 핵심 모듈식 시스템 구성요소 및 서비스 재사용을 단순화하여 Android 앱을 제작하는 데 필요한 기본 요소를 구성하며, 이러한 기본 요소에는 다음이 포함됩니다.
- 기능이 풍부하고 확장 가능한 뷰 시스템 - 목록, 그리드, 텍스트 상자, 버튼 및 삽입 가능한 웹브라우저를 포함하여 앱의 UI를 빌드하는 데 사용할 수 있음
- 리소스 관리자 - 현지화된 문자열, 그래픽 및 레이아웃 파일과 같은 코드가 아닌 리소스에 대한 액세스 제공
- 알림 관리자: 모든 앱이 상태 표시줄에 맞춤 알림을 표시할 수 있도록 지원
- 활동 관리자: 앱의 수명 주기를 관리하고 공통 탐색 백 스택을 제공합니다.
-
콘텐츠 제공자: 앱이 연락처 앱과 같은 다른 앱의 데이터에 액세스하거나 자체 데이터를 공유할 수 있도록 합니다.
개발자는 Android 시스템 앱이 사용하는 것과 동일한 프레임워크 API에 대한 전체 액세스 권한을 가집니다.
시스템 앱
Android는 이메일, SMS 메시징, 캘린더, 인터넷 검색, 연락처 등의 주요 앱 세트와 함께 제공됩니다. 플랫폼에 기본적으로 포함된 앱에는 사용자가 설치하도록 선택하는 앱과 구별되는 특별한 상태가 없습니다. 따라서 타사 앱이 사용자의 기본 웹브라우저, SMS 메신저 또는 기본 키보드가 될 수 있습니다. 시스템의 설정 앱과 같은 일부 예외가 적용됩니다.
시스템 앱은 사용자를 위한 앱으로도 작동하고 개발자가 자체 앱에서 액세스할 수 있는 주요 기능을 제공하기 위해 작동합니다. 예를 들어 앱에서 SMS 메시지를 전달하도록 하려면 이 기능을 직접 빌드하지 않아도 됩니다. 대신 이미 설치된 SMS 앱을 호출하여 지정한 수신자에게 메시지를 전송할 수 있습니다.
이 페이지에 나와 있는 콘텐츠와 코드 샘플에는 콘텐츠 라이선스에서 설명하는 라이선스가 적용됩니다. 자바 및 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,["# Platform architecture\n\nAndroid is an open source, Linux-based software stack created for a wide\narray of devices and form factors. Figure 1 shows the major\ncomponents of the Android platform.\n\n\n**Figure 1.** The Android software stack.\n\nLinux kernel\n------------\n\n\nThe foundation of the Android platform is the Linux kernel. For example,\n[the Android Runtime (ART)](#art) relies on the Linux kernel for\nunderlying functionalities such as threading and low-level memory management.\n\n\nUsing a Linux kernel lets Android take advantage of [key\nsecurity features](https://source.android.com/security/overview/kernel-security.html) and lets device manufacturers develop hardware\ndrivers for a well-known kernel.\n\nHardware abstraction layer (HAL)\n--------------------------------\n\n\nThe [hardware abstraction layer (HAL)](https://source.android.com/devices/architecture/hal) provides standard interfaces that expose\ndevice hardware capabilities to the higher-level [Java API framework](#api-framework). The HAL consists of multiple library\nmodules, each of which implements an interface for a specific type of hardware\ncomponent, such as the [camera](https://source.android.com/devices/camera/index.html) or [Bluetooth](https://source.android.com/devices/bluetooth.html) module.\nWhen a framework API makes a call to access device hardware, the Android\nsystem loads the library module for that hardware component.\n\nAndroid runtime\n---------------\n\n\nFor devices running Android version 5.0 (API level 21) or higher, each app\nruns in its own process and with its own instance of the [Android Runtime\n(ART)](https://source.android.com/devices/tech/dalvik/index.html). ART is written to run multiple virtual machines on low-memory\ndevices by executing Dalvik Executable\nformat (DEX) files, a bytecode format designed specifically for\nAndroid that's optimized for a minimal memory footprint. Build tools, such\nas [`d8`](/studio/command-line/d8), compile\nJava sources into DEX bytecode, which can run on the Android platform.\n\n\nSome of the major features of ART include the following:\n\n- Ahead-of-time (AOT) and just-in-time (JIT) compilation\n- Optimized garbage collection (GC)\n- On Android 9 (API level 28) and higher, [conversion](/about/versions/pie/android-9.0#art-aot-dex) of an app package's DEX files to more compact machine code\n- Better debugging support, including a dedicated sampling profiler, detailed diagnostic exceptions and crash reporting, and the ability to set watchpoints to monitor specific fields\n\n\nPrior to Android version 5.0 (API level 21), Dalvik was the Android runtime.\nIf your app runs well on ART, then it can work on Dalvik as well, but\n[the reverse might not be\ntrue](/guide/practices/verifying-apps-art).\n\n\nAndroid also includes a set of core runtime libraries that provide most of\nthe functionality of the Java programming language, including some [Java 8 language features](/guide/platform/j8-jack), that the Java\nAPI framework uses.\n\nNative C/C++ libraries\n----------------------\n\n\nMany core Android system components and services, such as ART and HAL, are\nbuilt from native code that requires native libraries written in C and C++.\nThe Android platform provides Java framework APIs to expose the functionality\nof some of these native libraries to apps. For example, you can access\n[OpenGL ES](/develop/ui/views/graphics/opengl/about-opengl) through the\nAndroid framework's [Java OpenGL API](/reference/android/opengl/package-summary) to add\nsupport for drawing and manipulating 2D and 3D graphics in your app.\n\n\nIf you are developing an app that requires C or C++ code, you can use the\n[Android NDK](/ndk) to access some of these [native platform libraries](/ndk/guides/stable_apis) directly from\nyour native code.\n\nJava API framework\n------------------\n\n\nThe entire feature-set of the Android OS is available to you through APIs\nwritten in the Java language. These APIs form the building blocks you need to\ncreate Android apps by simplifying the reuse of core, modular system\ncomponents and services, which include the following:\n\n- A rich and extensible [view\n system](/guide/topics/ui/overview) you can use to build an app's UI, including lists, grids, text boxes, buttons, and even an embeddable web browser\n- A [resource manager](/guide/topics/resources/overview), providing access to non-code resources such as localized strings, graphics, and layout files\n- A [notification\n manager](/guide/topics/ui/notifiers/notifications) that enables all apps to display custom alerts in the status bar\n- An [activity manager](/guide/components/activities/intro-activities) that manages the lifecycle of apps and provides a common [navigation back stack](/guide/components/tasks-and-back-stack)\n- [Content\n providers](/guide/topics/providers/content-providers) that enable apps to access data from other apps, such as the Contacts app, or to share their own data\n\n\nDevelopers have full access to the same [framework APIs](/reference/packages) that Android system apps use.\n\nSystem apps\n-----------\n\n\nAndroid comes with a set of core apps for email, SMS messaging, calendars,\ninternet browsing, contacts, and more. Apps included with the platform have\nno special status among the apps the user chooses to install. So, a\nthird-party app can become the user's default web browser, SMS messenger, or\neven the default keyboard. Some exceptions apply, such as the system's\nSettings app.\n\n\nThe system apps function both as apps for users and to provide key\ncapabilities that developers can access from their own app. For example, if\nyou want your app to deliver SMS messages, you don't need to build that\nfunctionality yourself. You can instead invoke whichever SMS app is already\ninstalled to deliver a message to the recipient you specify."]]