blob: 10bb42189e72168f03cf7b0c706dfd61597ec03a [file] [log] [blame]
Roland Levillain38a938e2018-09-21 10:55:51 +01001// Android Runtime APEX module.
2
3// Modules listed in LOCAL_REQUIRED_MODULES for module art-runtime in art/Android.mk.
4// - Base requirements (binaries for which both 32- and 64-bit versions are built, if relevant).
5art_runtime_base_binaries_both = [
6 "dalvikvm",
7]
8// - Base requirements (binaries for which a 32-bit version is preferred).
9art_runtime_base_binaries_prefer32 = [
10 "dex2oat",
11 "dexoptanalyzer",
12 "profman",
13]
14// - Base requirements (libraries).
15art_runtime_base_native_shared_libs = [
Martin Stjernholm23b27042019-01-11 10:36:35 +000016 "libadbconnection",
Roland Levillain38a938e2018-09-21 10:55:51 +010017 "libart",
18 "libart-compiler",
Martin Stjernholm23b27042019-01-11 10:36:35 +000019 "libdexfile_external",
Roland Levillain38a938e2018-09-21 10:55:51 +010020 "libopenjdkjvm",
21 "libopenjdkjvmti",
Roland Levillain38a938e2018-09-21 10:55:51 +010022]
Jiyong Park3296fb12018-12-13 18:32:21 +090023bionic_native_shared_libs = [
24 "libc",
25 "libm",
26 "libdl",
27]
Jiyong Parke2bc9fe2018-12-26 11:36:39 +090028bionic_binaries_both = [
29 "linker",
30]
Roland Levillain38a938e2018-09-21 10:55:51 +010031// - Debug variants (binaries for which a 32-bit version is preferred).
Roland Levillain38a938e2018-09-21 10:55:51 +010032art_runtime_debug_binaries_prefer32 = [
Roland Levillain38a938e2018-09-21 10:55:51 +010033 "dexoptanalyzerd",
34 "profmand",
35]
Alex Light572a0962019-01-18 14:48:37 -080036art_runtime_debug_binaries_prefer32_device = [
37 "dex2oatd",
38]
39art_runtime_debug_binaries_both_host = [
40 "dex2oatd",
41]
42
Roland Levillaincb82d092018-11-02 18:50:15 +000043// - Debug variants (libraries).
Roland Levillain38a938e2018-09-21 10:55:51 +010044art_runtime_debug_native_shared_libs = [
Martin Stjernholm23b27042019-01-11 10:36:35 +000045 "libadbconnectiond",
Roland Levillain38a938e2018-09-21 10:55:51 +010046 "libartd",
47 "libartd-compiler",
Roland Levillain38a938e2018-09-21 10:55:51 +010048 "libopenjdkjvmd",
49 "libopenjdkjvmtid",
Roland Levillain38a938e2018-09-21 10:55:51 +010050]
Roland Levillaincb82d092018-11-02 18:50:15 +000051libcore_debug_native_shared_libs = [
52 "libopenjdkd",
53]
Roland Levillain38a938e2018-09-21 10:55:51 +010054
Neil Fuller5ab4a562018-12-11 20:33:46 +000055// Data files associated with bionic / managed core library APIs.
56art_runtime_data_file_prebuilts = [
Neil Fullera886dab2018-12-06 15:12:52 +000057 "apex_tz_version",
58 "apex_tzdata",
59 "apex_tzlookup.xml",
Neil Fuller5ab4a562018-12-11 20:33:46 +000060 "apex_icu.dat",
Neil Fullera886dab2018-12-06 15:12:52 +000061]
62
Roland Levillain38a938e2018-09-21 10:55:51 +010063// Modules listed in LOCAL_REQUIRED_MODULES for module art-tools in art/Android.mk.
Alex Lightda948ce2018-12-06 17:05:41 +000064art_tools_common_binaries = [
Roland Levillain38a938e2018-09-21 10:55:51 +010065 "dexdiag",
66 "dexdump",
67 "dexlist",
Alex Lightda948ce2018-12-06 17:05:41 +000068]
69
Roland Levillaine9f0ccc2019-01-07 16:45:58 +000070// Device-only modules listed in LOCAL_REQUIRED_MODULES for module art-tools in art/Android.mk.
71art_tools_device_only_binaries = [
72 // oatdump cannot link with host linux_bionic due to not using clang lld;
73 // TODO: Make it work with clang lld.
Roland Levillain38a938e2018-09-21 10:55:51 +010074 "oatdump",
75]
76
77// Host-only modules listed in LOCAL_REQUIRED_MODULES for module art-tools in art/Android.mk.
Roland Levillaine9f0ccc2019-01-07 16:45:58 +000078art_tools_host_only_binaries = [
Roland Levillain38a938e2018-09-21 10:55:51 +010079 // FIXME: Does not work as-is, because `ahat` is defined in tools/ahat/Android.mk
80 // (same issue as for `libart_fake` above).
81 //"ahat",
82 "hprof-conv",
83 // ...
84]
85
Roland Levillaine9f0ccc2019-01-07 16:45:58 +000086art_tools_device_binaries = art_tools_common_binaries + art_tools_device_only_binaries
87art_tools_host_binaries = art_tools_common_binaries + art_tools_host_only_binaries
Alex Lightda948ce2018-12-06 17:05:41 +000088
Pete Bentley51ffdbe2019-01-11 15:25:40 +000089// Libcore native libraries.
Roland Levillaincb82d092018-11-02 18:50:15 +000090libcore_native_shared_libs = [
Pete Bentley51ffdbe2019-01-11 15:25:40 +000091 "libjavacore",
Roland Levillaincb82d092018-11-02 18:50:15 +000092 "libopenjdk",
Pete Bentley51ffdbe2019-01-11 15:25:40 +000093 "libexpat",
94 "libz",
95 "libziparchive"
Roland Levillaincb82d092018-11-02 18:50:15 +000096]
97
Nicolas Geoffraycc64d082019-01-25 09:43:18 +000098// Java libraries
99libcore_target_java_libs = [
100 "core-oj",
101 "core-libart",
102 "okhttp",
103 "bouncycastle",
104 "apache-xml",
105]
106
Alex Lightf7f31522019-02-01 11:14:41 -0800107// Temporary library includes for b/123591866 as all libraries are moved into the main art-apex.
108art_runtime_libraries_zipapex = [
109 "libnativebridge",
110 "libnativeloader",
111 "libnativehelper",
112 "libcutils",
113]
114
Roland Levillain38a938e2018-09-21 10:55:51 +0100115apex_key {
116 name: "com.android.runtime.key",
Jiyong Park11a2df32018-11-22 16:25:08 +0900117 public_key: "com.android.runtime.avbpubkey",
118 private_key: "com.android.runtime.pem",
Roland Levillain38a938e2018-09-21 10:55:51 +0100119}
120
Roland Levillain3be7afe2018-12-04 19:35:03 +0000121prebuilt_etc {
122 name: "com.android.runtime.ld.config.txt",
123 src: "ld.config.txt",
124 filename: "ld.config.txt",
125 installable: false,
126}
127
Roland Levillain53058802018-11-14 17:32:18 +0000128// TODO: Introduce `apex_defaults` to factor common parts of `apex`
129// module definitions below?
130
131// Release version of the Runtime APEX module (not containing debug
132// variants nor tools), included in user builds. Also used for
133// storage-constrained devices in userdebug and eng builds.
Roland Levillain38a938e2018-09-21 10:55:51 +0100134apex {
Roland Levillain53058802018-11-14 17:32:18 +0000135 name: "com.android.runtime.release",
136 compile_multilib: "both",
137 manifest: "manifest.json",
Nicolas Geoffraycc64d082019-01-25 09:43:18 +0000138 java_libs: libcore_target_java_libs,
Roland Levillain53058802018-11-14 17:32:18 +0000139 native_shared_libs: art_runtime_base_native_shared_libs
Roland Levillaincb82d092018-11-02 18:50:15 +0000140 + bionic_native_shared_libs
141 + libcore_native_shared_libs,
Roland Levillain53058802018-11-14 17:32:18 +0000142 multilib: {
143 both: {
144 // TODO: Add logic to create a `dalvikvm` symlink to `dalvikvm32` or `dalvikvm64`
145 // (see `symlink_preferred_arch` in art/dalvikvm/Android.bp).
Jiyong Parke2bc9fe2018-12-26 11:36:39 +0900146 binaries: art_runtime_base_binaries_both
147 + bionic_binaries_both,
Roland Levillain53058802018-11-14 17:32:18 +0000148 },
149 prefer32: {
150 binaries: art_runtime_base_binaries_prefer32,
151 },
152 first: {
153 binaries: [],
154 }
155 },
Neil Fuller5ab4a562018-12-11 20:33:46 +0000156 prebuilts: art_runtime_data_file_prebuilts
Neil Fullera886dab2018-12-06 15:12:52 +0000157 + ["com.android.runtime.ld.config.txt"],
Roland Levillain53058802018-11-14 17:32:18 +0000158 key: "com.android.runtime.key",
Roland Levillain53058802018-11-14 17:32:18 +0000159}
160
161// "Debug" version of the Runtime APEX module (containing both release and
162// debug variants, as well as additional tools), included in userdebug and
163// eng build.
164apex {
165 name: "com.android.runtime.debug",
Roland Levillain38a938e2018-09-21 10:55:51 +0100166 compile_multilib: "both",
167 manifest: "manifest.json",
Nicolas Geoffraycc64d082019-01-25 09:43:18 +0000168 java_libs: libcore_target_java_libs,
Roland Levillain38a938e2018-09-21 10:55:51 +0100169 native_shared_libs: art_runtime_base_native_shared_libs
Jiyong Park3296fb12018-12-13 18:32:21 +0900170 + art_runtime_debug_native_shared_libs
Roland Levillaincb82d092018-11-02 18:50:15 +0000171 + bionic_native_shared_libs
172 + libcore_native_shared_libs
173 + libcore_debug_native_shared_libs,
Roland Levillain38a938e2018-09-21 10:55:51 +0100174 multilib: {
175 both: {
176 // TODO: Add logic to create a `dalvikvm` symlink to `dalvikvm32` or `dalvikvm64`
177 // (see `symlink_preferred_arch` in art/dalvikvm/Android.bp).
Jiyong Parke2bc9fe2018-12-26 11:36:39 +0900178 binaries: art_runtime_base_binaries_both
179 + bionic_binaries_both,
Roland Levillain38a938e2018-09-21 10:55:51 +0100180 },
181 prefer32: {
182 binaries: art_runtime_base_binaries_prefer32
Alex Light572a0962019-01-18 14:48:37 -0800183 + art_runtime_debug_binaries_prefer32
184 + art_runtime_debug_binaries_prefer32_device,
Roland Levillain38a938e2018-09-21 10:55:51 +0100185 },
186 first: {
Roland Levillaine9f0ccc2019-01-07 16:45:58 +0000187 binaries: art_tools_device_binaries,
Roland Levillain38a938e2018-09-21 10:55:51 +0100188 }
189 },
Neil Fuller5ab4a562018-12-11 20:33:46 +0000190 prebuilts: art_runtime_data_file_prebuilts
Neil Fullera886dab2018-12-06 15:12:52 +0000191 + ["com.android.runtime.ld.config.txt"],
Roland Levillain38a938e2018-09-21 10:55:51 +0100192 key: "com.android.runtime.key",
Roland Levillain38a938e2018-09-21 10:55:51 +0100193}
Alex Lightda948ce2018-12-06 17:05:41 +0000194
195// TODO: Do this better. art_apex will disable host builds when
196// HOST_PREFER_32_BIT is set. We cannot simply use com.android.runtime.debug
197// because binaries have different multilib classes and 'multilib: {}' isn't
198// supported by target: { ... }.
199// See b/120617876 for more information.
200art_apex {
201 name: "com.android.runtime.host",
202 compile_multilib: "both",
Alex Lightf7f31522019-02-01 11:14:41 -0800203 installable: false,
Alex Lightda948ce2018-12-06 17:05:41 +0000204 payload_type: "zip",
205 host_supported: true,
206 device_supported: false,
207 manifest: "manifest.json",
Alex Lighta6ea6022019-01-29 11:02:03 -0800208 java_libs: libcore_target_java_libs,
Alex Light55a9bad2019-01-29 18:34:09 -0800209 ignore_system_library_special_case: true,
Alex Lightda948ce2018-12-06 17:05:41 +0000210 native_shared_libs: art_runtime_base_native_shared_libs
Roland Levillaincb82d092018-11-02 18:50:15 +0000211 + art_runtime_debug_native_shared_libs
212 + libcore_native_shared_libs
Alex Lightf7f31522019-02-01 11:14:41 -0800213 + libcore_debug_native_shared_libs
214 + art_runtime_libraries_zipapex,
Alex Lightda948ce2018-12-06 17:05:41 +0000215 multilib: {
216 both: {
217 // TODO: Add logic to create a `dalvikvm` symlink to `dalvikvm32` or `dalvikvm64`
218 // (see `symlink_preferred_arch` in art/dalvikvm/Android.bp).
Alex Light572a0962019-01-18 14:48:37 -0800219 binaries: art_runtime_base_binaries_both
220 + art_runtime_debug_binaries_both_host,
Alex Lightda948ce2018-12-06 17:05:41 +0000221 },
222 first: {
Roland Levillaine9f0ccc2019-01-07 16:45:58 +0000223 binaries: art_tools_host_binaries
Alex Lightda948ce2018-12-06 17:05:41 +0000224 + art_runtime_base_binaries_prefer32
225 + art_runtime_debug_binaries_prefer32,
226 }
227 },
228 key: "com.android.runtime.key",
Alex Lighte3521522018-12-06 22:51:18 -0800229 target: {
230 darwin: {
231 enabled: false,
232 },
Alex Light55a9bad2019-01-29 18:34:09 -0800233 linux_bionic: {
234 enabled: true,
235 multilib: {
236 both: {
237 native_shared_libs: bionic_native_shared_libs,
238 binaries: bionic_binaries_both,
239 }
240 }
241 },
Alex Lighte3521522018-12-06 22:51:18 -0800242 },
Alex Lightda948ce2018-12-06 17:05:41 +0000243}