summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiyong Park2018-05-24 00:11:00 -0500
committerJiyong Park2018-05-24 00:11:11 -0500
commita0e75045e6817a51e4e6b05880d871525a4d52fe (patch)
tree5d65ece1bd5bcba61ff8617baa096c1e3a70b5ad
parent98c1b1ccf67113957f1e4d8678cf8b5a1fe747e1 (diff)
downloadplatform-system-core-a0e75045e6817a51e4e6b05880d871525a4d52fe.tar.gz
platform-system-core-a0e75045e6817a51e4e6b05880d871525a4d52fe.tar.xz
platform-system-core-a0e75045e6817a51e4e6b05880d871525a4d52fe.zip
Build adbd for recovery
adbd (and its dependencies) are marked as recovery_available:true so that recovery version of the binary is built separately from the one for system partition. This allows us to stop copying the system version to the recovery partition and also opens up the way to enable shared libraries in the recovery partition. Then we can also build adbd as a dynamic executable. Bug: 79146551 Test: m -j adbd.recovery Change-Id: Ib95614c7435f9d0afc02a0c7d5ae1a94e439e32a
-rw-r--r--adb/Android.bp2
-rw-r--r--base/Android.bp1
-rw-r--r--debuggerd/Android.bp4
-rw-r--r--demangle/Android.bp1
-rw-r--r--diagnose_usb/Android.bp1
-rw-r--r--fs_mgr/Android.bp2
-rw-r--r--libasyncio/Android.bp1
-rw-r--r--libbacktrace/Android.bp7
-rw-r--r--libcrypto_utils/Android.bp1
-rw-r--r--libkeyutils/Android.bp1
-rw-r--r--libprocinfo/Android.bp1
-rw-r--r--libsparse/Android.bp1
-rw-r--r--libunwindstack/Android.bp9
-rw-r--r--logwrapper/Android.bp1
-rw-r--r--qemu_pipe/Android.bp1
15 files changed, 32 insertions, 2 deletions
diff --git a/adb/Android.bp b/adb/Android.bp
index 1f41e4f3f..ee1bdaa29 100644
--- a/adb/Android.bp
+++ b/adb/Android.bp
@@ -276,6 +276,7 @@ cc_binary_host {
276cc_library_static { 276cc_library_static {
277 name: "libadbd", 277 name: "libadbd",
278 defaults: ["adb_defaults"], 278 defaults: ["adb_defaults"],
279 recovery_available: true,
279 280
280 // libminadbd wants both, for some reason. 281 // libminadbd wants both, for some reason.
281 compile_multilib: "both", 282 compile_multilib: "both",
@@ -302,6 +303,7 @@ cc_binary {
302 303
303 // adbd must be static, as it is copied into the recovery image. 304 // adbd must be static, as it is copied into the recovery image.
304 static_executable: true, 305 static_executable: true,
306 recovery_available: true,
305 307
306 srcs: [ 308 srcs: [
307 "daemon/main.cpp", 309 "daemon/main.cpp",
diff --git a/base/Android.bp b/base/Android.bp
index 47b29c6a6..71bf1540c 100644
--- a/base/Android.bp
+++ b/base/Android.bp
@@ -95,6 +95,7 @@ cc_library {
95 name: "libbase", 95 name: "libbase",
96 defaults: ["libbase_defaults"], 96 defaults: ["libbase_defaults"],
97 vendor_available: true, 97 vendor_available: true,
98 recovery_available: true,
98 host_supported: true, 99 host_supported: true,
99 vndk: { 100 vndk: {
100 enabled: true, 101 enabled: true,
diff --git a/debuggerd/Android.bp b/debuggerd/Android.bp
index 7c28b2814..0b1366209 100644
--- a/debuggerd/Android.bp
+++ b/debuggerd/Android.bp
@@ -17,6 +17,7 @@ cc_defaults {
17cc_library_headers { 17cc_library_headers {
18 name: "libdebuggerd_common_headers", 18 name: "libdebuggerd_common_headers",
19 export_include_dirs: ["common/include"], 19 export_include_dirs: ["common/include"],
20 recovery_available: true,
20} 21}
21 22
22cc_library_shared { 23cc_library_shared {
@@ -67,6 +68,7 @@ cc_library_static {
67cc_library_static { 68cc_library_static {
68 name: "libdebuggerd_handler_core", 69 name: "libdebuggerd_handler_core",
69 defaults: ["debuggerd_defaults"], 70 defaults: ["debuggerd_defaults"],
71 recovery_available: true,
70 srcs: ["handler/debuggerd_handler.cpp"], 72 srcs: ["handler/debuggerd_handler.cpp"],
71 73
72 header_libs: [ 74 header_libs: [
@@ -88,6 +90,7 @@ cc_library_static {
88cc_library_static { 90cc_library_static {
89 name: "libdebuggerd_handler", 91 name: "libdebuggerd_handler",
90 defaults: ["debuggerd_defaults"], 92 defaults: ["debuggerd_defaults"],
93 recovery_available: true,
91 srcs: ["handler/debuggerd_fallback_nop.cpp"], 94 srcs: ["handler/debuggerd_fallback_nop.cpp"],
92 95
93 whole_static_libs: [ 96 whole_static_libs: [
@@ -143,6 +146,7 @@ cc_library {
143cc_library_static { 146cc_library_static {
144 name: "libdebuggerd", 147 name: "libdebuggerd",
145 defaults: ["debuggerd_defaults"], 148 defaults: ["debuggerd_defaults"],
149 recovery_available: true,
146 150
147 srcs: [ 151 srcs: [
148 "libdebuggerd/backtrace.cpp", 152 "libdebuggerd/backtrace.cpp",
diff --git a/demangle/Android.bp b/demangle/Android.bp
index cf6abfde0..fd79cf88f 100644
--- a/demangle/Android.bp
+++ b/demangle/Android.bp
@@ -36,6 +36,7 @@ cc_library {
36 name: "libdemangle", 36 name: "libdemangle",
37 defaults: ["libdemangle_defaults"], 37 defaults: ["libdemangle_defaults"],
38 vendor_available: true, 38 vendor_available: true,
39 recovery_available: true,
39 40
40 srcs: [ 41 srcs: [
41 "Demangler.cpp", 42 "Demangler.cpp",
diff --git a/diagnose_usb/Android.bp b/diagnose_usb/Android.bp
index a7ecf3737..6bee28c10 100644
--- a/diagnose_usb/Android.bp
+++ b/diagnose_usb/Android.bp
@@ -2,6 +2,7 @@ cc_library_static {
2 name: "libdiagnose_usb", 2 name: "libdiagnose_usb",
3 cflags: ["-Wall", "-Wextra", "-Werror"], 3 cflags: ["-Wall", "-Wextra", "-Werror"],
4 host_supported: true, 4 host_supported: true,
5 recovery_available: true,
5 target: { 6 target: {
6 windows: { 7 windows: {
7 enabled: true, 8 enabled: true,
diff --git a/fs_mgr/Android.bp b/fs_mgr/Android.bp
index 05dba1524..bc3b04b02 100644
--- a/fs_mgr/Android.bp
+++ b/fs_mgr/Android.bp
@@ -33,6 +33,7 @@ cc_defaults {
33cc_library_static { 33cc_library_static {
34 name: "libfs_mgr", 34 name: "libfs_mgr",
35 defaults: ["fs_mgr_defaults"], 35 defaults: ["fs_mgr_defaults"],
36 recovery_available: true,
36 export_include_dirs: ["include"], 37 export_include_dirs: ["include"],
37 include_dirs: ["system/vold"], 38 include_dirs: ["system/vold"],
38 srcs: [ 39 srcs: [
@@ -79,6 +80,7 @@ cc_library_static {
79cc_library_static { 80cc_library_static {
80 name: "libfstab", 81 name: "libfstab",
81 vendor_available: true, 82 vendor_available: true,
83 recovery_available: true,
82 defaults: ["fs_mgr_defaults"], 84 defaults: ["fs_mgr_defaults"],
83 srcs: [ 85 srcs: [
84 "fs_mgr_fstab.cpp", 86 "fs_mgr_fstab.cpp",
diff --git a/libasyncio/Android.bp b/libasyncio/Android.bp
index 8a2afea3d..4ab439d57 100644
--- a/libasyncio/Android.bp
+++ b/libasyncio/Android.bp
@@ -27,6 +27,7 @@ cc_library {
27 name: "libasyncio", 27 name: "libasyncio",
28 defaults: ["libasyncio_defaults"], 28 defaults: ["libasyncio_defaults"],
29 vendor_available: true, 29 vendor_available: true,
30 recovery_available: true,
30 host_supported: true, 31 host_supported: true,
31 srcs: [ 32 srcs: [
32 "AsyncIO.cpp", 33 "AsyncIO.cpp",
diff --git a/libbacktrace/Android.bp b/libbacktrace/Android.bp
index 0f93dd071..b4bf35fba 100644
--- a/libbacktrace/Android.bp
+++ b/libbacktrace/Android.bp
@@ -58,6 +58,7 @@ cc_library_headers {
58cc_library { 58cc_library {
59 name: "libbacktrace", 59 name: "libbacktrace",
60 vendor_available: false, 60 vendor_available: false,
61 recovery_available: true,
61 vndk: { 62 vndk: {
62 enabled: true, 63 enabled: true,
63 support_system_process: true, 64 support_system_process: true,
@@ -102,8 +103,6 @@ cc_library {
102 include_dirs: [ 103 include_dirs: [
103 "art/runtime", 104 "art/runtime",
104 ], 105 ],
105
106 header_libs: ["jni_headers"],
107 }, 106 },
108 android: { 107 android: {
109 static_libs: ["libasync_safe"], 108 static_libs: ["libasync_safe"],
@@ -112,6 +111,10 @@ cc_library {
112 cflags: ["-DNO_LIBDEXFILE_SUPPORT"], 111 cflags: ["-DNO_LIBDEXFILE_SUPPORT"],
113 exclude_shared_libs: ["libdexfile"], 112 exclude_shared_libs: ["libdexfile"],
114 }, 113 },
114 recovery: {
115 cflags: ["-DNO_LIBDEXFILE_SUPPORT"],
116 exclude_shared_libs: ["libdexfile"],
117 },
115 }, 118 },
116 whole_static_libs: ["libdemangle"], 119 whole_static_libs: ["libdemangle"],
117} 120}
diff --git a/libcrypto_utils/Android.bp b/libcrypto_utils/Android.bp
index 47de12ab0..e47560f79 100644
--- a/libcrypto_utils/Android.bp
+++ b/libcrypto_utils/Android.bp
@@ -17,6 +17,7 @@
17cc_library { 17cc_library {
18 name: "libcrypto_utils", 18 name: "libcrypto_utils",
19 vendor_available: true, 19 vendor_available: true,
20 recovery_available: true,
20 vndk: { 21 vndk: {
21 enabled: true, 22 enabled: true,
22 }, 23 },
diff --git a/libkeyutils/Android.bp b/libkeyutils/Android.bp
index f3593ff5d..b388e9555 100644
--- a/libkeyutils/Android.bp
+++ b/libkeyutils/Android.bp
@@ -2,6 +2,7 @@ cc_library {
2 name: "libkeyutils", 2 name: "libkeyutils",
3 cflags: ["-Werror"], 3 cflags: ["-Werror"],
4 defaults: ["linux_bionic_supported"], 4 defaults: ["linux_bionic_supported"],
5 recovery_available: true,
5 export_include_dirs: ["include/"], 6 export_include_dirs: ["include/"],
6 local_include_dirs: ["include/"], 7 local_include_dirs: ["include/"],
7 srcs: ["keyutils.cpp"], 8 srcs: ["keyutils.cpp"],
diff --git a/libprocinfo/Android.bp b/libprocinfo/Android.bp
index d776b3d8e..15f03d080 100644
--- a/libprocinfo/Android.bp
+++ b/libprocinfo/Android.bp
@@ -27,6 +27,7 @@ cc_library {
27 name: "libprocinfo", 27 name: "libprocinfo",
28 defaults: ["libprocinfo_defaults"], 28 defaults: ["libprocinfo_defaults"],
29 vendor_available: true, 29 vendor_available: true,
30 recovery_available: true,
30 vndk: { 31 vndk: {
31 enabled: true, 32 enabled: true,
32 }, 33 },
diff --git a/libsparse/Android.bp b/libsparse/Android.bp
index b8946563c..c7c089f49 100644
--- a/libsparse/Android.bp
+++ b/libsparse/Android.bp
@@ -3,6 +3,7 @@
3cc_library { 3cc_library {
4 name: "libsparse", 4 name: "libsparse",
5 host_supported: true, 5 host_supported: true,
6 recovery_available: true,
6 unique_host_soname: true, 7 unique_host_soname: true,
7 srcs: [ 8 srcs: [
8 "backed_block.c", 9 "backed_block.c",
diff --git a/libunwindstack/Android.bp b/libunwindstack/Android.bp
index a6bf73073..6bcbbb8b2 100644
--- a/libunwindstack/Android.bp
+++ b/libunwindstack/Android.bp
@@ -38,6 +38,7 @@ cc_defaults {
38cc_library { 38cc_library {
39 name: "libunwindstack", 39 name: "libunwindstack",
40 vendor_available: true, 40 vendor_available: true,
41 recovery_available: true,
41 vndk: { 42 vndk: {
42 enabled: true, 43 enabled: true,
43 support_system_process: true, 44 support_system_process: true,
@@ -93,6 +94,14 @@ cc_library {
93 ], 94 ],
94 exclude_shared_libs: ["libdexfile"], 95 exclude_shared_libs: ["libdexfile"],
95 }, 96 },
97 recovery: {
98 cflags: ["-DNO_LIBDEXFILE_SUPPORT"],
99 exclude_srcs: [
100 "DexFile.cpp",
101 "DexFiles.cpp",
102 ],
103 exclude_shared_libs: ["libdexfile"],
104 },
96 }, 105 },
97 106
98 arch: { 107 arch: {
diff --git a/logwrapper/Android.bp b/logwrapper/Android.bp
index d4ba4f47f..c37864613 100644
--- a/logwrapper/Android.bp
+++ b/logwrapper/Android.bp
@@ -12,6 +12,7 @@ cc_defaults {
12cc_library { 12cc_library {
13 name: "liblogwrap", 13 name: "liblogwrap",
14 defaults: ["logwrapper_defaults"], 14 defaults: ["logwrapper_defaults"],
15 recovery_available: true,
15 srcs: ["logwrap.c"], 16 srcs: ["logwrap.c"],
16 shared_libs: [ 17 shared_libs: [
17 "libcutils", 18 "libcutils",
diff --git a/qemu_pipe/Android.bp b/qemu_pipe/Android.bp
index 93c347beb..c6bda4a28 100644
--- a/qemu_pipe/Android.bp
+++ b/qemu_pipe/Android.bp
@@ -3,6 +3,7 @@
3cc_library_static { 3cc_library_static {
4 name: "libqemu_pipe", 4 name: "libqemu_pipe",
5 vendor_available: true, 5 vendor_available: true,
6 recovery_available: true,
6 sanitize: { 7 sanitize: {
7 misc_undefined: ["integer"], 8 misc_undefined: ["integer"],
8 }, 9 },