blob: aa199d3c92336ab3ccacc2465ae7b44a607c63a4 [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 = [
16 "libart",
17 "libart-compiler",
18 "libopenjdkjvm",
19 "libopenjdkjvmti",
20 "libadbconnection",
Jiyong Park72b85332018-12-28 17:20:55 +090021 "libjavacrypto",
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 = [
33 "dex2oatd",
34 "dexoptanalyzerd",
35 "profmand",
36]
Roland Levillaincb82d092018-11-02 18:50:15 +000037// - Debug variants (libraries).
Roland Levillain38a938e2018-09-21 10:55:51 +010038art_runtime_debug_native_shared_libs = [
39 "libartd",
40 "libartd-compiler",
Roland Levillain38a938e2018-09-21 10:55:51 +010041 "libopenjdkjvmd",
42 "libopenjdkjvmtid",
43 "libadbconnectiond",
44]
Roland Levillaincb82d092018-11-02 18:50:15 +000045libcore_debug_native_shared_libs = [
46 "libopenjdkd",
47]
Roland Levillain38a938e2018-09-21 10:55:51 +010048
Neil Fuller5ab4a562018-12-11 20:33:46 +000049// Data files associated with bionic / managed core library APIs.
50art_runtime_data_file_prebuilts = [
Neil Fullera886dab2018-12-06 15:12:52 +000051 "apex_tz_version",
52 "apex_tzdata",
53 "apex_tzlookup.xml",
Neil Fuller5ab4a562018-12-11 20:33:46 +000054 "apex_icu.dat",
Neil Fullera886dab2018-12-06 15:12:52 +000055]
56
Roland Levillain38a938e2018-09-21 10:55:51 +010057// Modules listed in LOCAL_REQUIRED_MODULES for module art-tools in art/Android.mk.
Alex Lightda948ce2018-12-06 17:05:41 +000058art_tools_common_binaries = [
Roland Levillain38a938e2018-09-21 10:55:51 +010059 "dexdiag",
60 "dexdump",
61 "dexlist",
Alex Lightda948ce2018-12-06 17:05:41 +000062]
63
Roland Levillaine9f0ccc2019-01-07 16:45:58 +000064// Device-only modules listed in LOCAL_REQUIRED_MODULES for module art-tools in art/Android.mk.
65art_tools_device_only_binaries = [
66 // oatdump cannot link with host linux_bionic due to not using clang lld;
67 // TODO: Make it work with clang lld.
Roland Levillain38a938e2018-09-21 10:55:51 +010068 "oatdump",
69]
70
71// Host-only modules listed in LOCAL_REQUIRED_MODULES for module art-tools in art/Android.mk.
Roland Levillaine9f0ccc2019-01-07 16:45:58 +000072art_tools_host_only_binaries = [
Roland Levillain38a938e2018-09-21 10:55:51 +010073 // FIXME: Does not work as-is, because `ahat` is defined in tools/ahat/Android.mk
74 // (same issue as for `libart_fake` above).
75 //"ahat",
76 "hprof-conv",
77 // ...
78]
79
Roland Levillaine9f0ccc2019-01-07 16:45:58 +000080art_tools_device_binaries = art_tools_common_binaries + art_tools_device_only_binaries
81art_tools_host_binaries = art_tools_common_binaries + art_tools_host_only_binaries
Alex Lightda948ce2018-12-06 17:05:41 +000082
Roland Levillaincb82d092018-11-02 18:50:15 +000083// (Some) Libcore native libraries.
84libcore_native_shared_libs = [
85 "libopenjdk",
86]
87
Roland Levillain38a938e2018-09-21 10:55:51 +010088apex_key {
89 name: "com.android.runtime.key",
Jiyong Park11a2df32018-11-22 16:25:08 +090090 public_key: "com.android.runtime.avbpubkey",
91 private_key: "com.android.runtime.pem",
Roland Levillain38a938e2018-09-21 10:55:51 +010092}
93
Roland Levillain3be7afe2018-12-04 19:35:03 +000094prebuilt_etc {
95 name: "com.android.runtime.ld.config.txt",
96 src: "ld.config.txt",
97 filename: "ld.config.txt",
98 installable: false,
99}
100
Roland Levillain53058802018-11-14 17:32:18 +0000101// TODO: Introduce `apex_defaults` to factor common parts of `apex`
102// module definitions below?
103
104// Release version of the Runtime APEX module (not containing debug
105// variants nor tools), included in user builds. Also used for
106// storage-constrained devices in userdebug and eng builds.
Roland Levillain38a938e2018-09-21 10:55:51 +0100107apex {
Roland Levillain53058802018-11-14 17:32:18 +0000108 name: "com.android.runtime.release",
109 compile_multilib: "both",
110 manifest: "manifest.json",
111 native_shared_libs: art_runtime_base_native_shared_libs
Roland Levillaincb82d092018-11-02 18:50:15 +0000112 + bionic_native_shared_libs
113 + libcore_native_shared_libs,
Roland Levillain53058802018-11-14 17:32:18 +0000114 multilib: {
115 both: {
116 // TODO: Add logic to create a `dalvikvm` symlink to `dalvikvm32` or `dalvikvm64`
117 // (see `symlink_preferred_arch` in art/dalvikvm/Android.bp).
Jiyong Parke2bc9fe2018-12-26 11:36:39 +0900118 binaries: art_runtime_base_binaries_both
119 + bionic_binaries_both,
Roland Levillain53058802018-11-14 17:32:18 +0000120 },
121 prefer32: {
122 binaries: art_runtime_base_binaries_prefer32,
123 },
124 first: {
125 binaries: [],
126 }
127 },
Neil Fuller5ab4a562018-12-11 20:33:46 +0000128 prebuilts: art_runtime_data_file_prebuilts
Neil Fullera886dab2018-12-06 15:12:52 +0000129 + ["com.android.runtime.ld.config.txt"],
Roland Levillain53058802018-11-14 17:32:18 +0000130 key: "com.android.runtime.key",
Roland Levillain53058802018-11-14 17:32:18 +0000131}
132
133// "Debug" version of the Runtime APEX module (containing both release and
134// debug variants, as well as additional tools), included in userdebug and
135// eng build.
136apex {
137 name: "com.android.runtime.debug",
Roland Levillain38a938e2018-09-21 10:55:51 +0100138 compile_multilib: "both",
139 manifest: "manifest.json",
Roland Levillain38a938e2018-09-21 10:55:51 +0100140 native_shared_libs: art_runtime_base_native_shared_libs
Jiyong Park3296fb12018-12-13 18:32:21 +0900141 + art_runtime_debug_native_shared_libs
Roland Levillaincb82d092018-11-02 18:50:15 +0000142 + bionic_native_shared_libs
143 + libcore_native_shared_libs
144 + libcore_debug_native_shared_libs,
Roland Levillain38a938e2018-09-21 10:55:51 +0100145 multilib: {
146 both: {
147 // TODO: Add logic to create a `dalvikvm` symlink to `dalvikvm32` or `dalvikvm64`
148 // (see `symlink_preferred_arch` in art/dalvikvm/Android.bp).
Jiyong Parke2bc9fe2018-12-26 11:36:39 +0900149 binaries: art_runtime_base_binaries_both
150 + bionic_binaries_both,
Roland Levillain38a938e2018-09-21 10:55:51 +0100151 },
152 prefer32: {
153 binaries: art_runtime_base_binaries_prefer32
Roland Levillain53058802018-11-14 17:32:18 +0000154 + art_runtime_debug_binaries_prefer32,
Roland Levillain38a938e2018-09-21 10:55:51 +0100155 },
156 first: {
Roland Levillaine9f0ccc2019-01-07 16:45:58 +0000157 binaries: art_tools_device_binaries,
Roland Levillain38a938e2018-09-21 10:55:51 +0100158 }
159 },
Neil Fuller5ab4a562018-12-11 20:33:46 +0000160 prebuilts: art_runtime_data_file_prebuilts
Neil Fullera886dab2018-12-06 15:12:52 +0000161 + ["com.android.runtime.ld.config.txt"],
Roland Levillain38a938e2018-09-21 10:55:51 +0100162 key: "com.android.runtime.key",
Roland Levillain38a938e2018-09-21 10:55:51 +0100163}
Alex Lightda948ce2018-12-06 17:05:41 +0000164
165// TODO: Do this better. art_apex will disable host builds when
166// HOST_PREFER_32_BIT is set. We cannot simply use com.android.runtime.debug
167// because binaries have different multilib classes and 'multilib: {}' isn't
168// supported by target: { ... }.
169// See b/120617876 for more information.
170art_apex {
171 name: "com.android.runtime.host",
172 compile_multilib: "both",
173 payload_type: "zip",
174 host_supported: true,
175 device_supported: false,
176 manifest: "manifest.json",
177 native_shared_libs: art_runtime_base_native_shared_libs
Roland Levillaincb82d092018-11-02 18:50:15 +0000178 + art_runtime_debug_native_shared_libs
179 + libcore_native_shared_libs
180 + libcore_debug_native_shared_libs,
Alex Lightda948ce2018-12-06 17:05:41 +0000181 multilib: {
182 both: {
183 // TODO: Add logic to create a `dalvikvm` symlink to `dalvikvm32` or `dalvikvm64`
184 // (see `symlink_preferred_arch` in art/dalvikvm/Android.bp).
185 binaries: art_runtime_base_binaries_both,
186 },
187 first: {
Roland Levillaine9f0ccc2019-01-07 16:45:58 +0000188 binaries: art_tools_host_binaries
Alex Lightda948ce2018-12-06 17:05:41 +0000189 + art_runtime_base_binaries_prefer32
190 + art_runtime_debug_binaries_prefer32,
191 }
192 },
193 key: "com.android.runtime.key",
Alex Lighte3521522018-12-06 22:51:18 -0800194 target: {
195 darwin: {
196 enabled: false,
197 },
198 },
Alex Lightda948ce2018-12-06 17:05:41 +0000199}