Set apex_available property
The marked library(ies) were available to the APEXes via the
hand-written whitelist in build/soong/apex/apex.go. Trying to remove the
whitelist by adding apex_available property to the Android.bp of the
libraries.
Bug: 150999716
Test: m
Merged-In: Ie9a693be10c6c6571c8aa5357500f5d931400593
(cherry picked from commit 0f152391c0458d3d1cce04a11bc92e7234955d6f)
Change-Id: Ie9a693be10c6c6571c8aa5357500f5d931400593
diff --git a/cmdline/Android.bp b/cmdline/Android.bp
index b46e987..3eac0ed 100644
--- a/cmdline/Android.bp
+++ b/cmdline/Android.bp
@@ -19,6 +19,11 @@
name: "art_cmdlineparser_headers",
host_supported: true,
export_include_dirs: ["."],
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
art_cc_test {
diff --git a/dex2oat/Android.bp b/dex2oat/Android.bp
index 0e82704..25ec0a8 100644
--- a/dex2oat/Android.bp
+++ b/dex2oat/Android.bp
@@ -168,6 +168,12 @@
],
host_supported: true,
export_include_dirs: ["include"],
+
+ apex_available: [
+ "//apex_available:platform",
+ "com.android.art.release",
+ "com.android.art.debug",
+ ],
}
cc_defaults {
diff --git a/disassembler/Android.bp b/disassembler/Android.bp
index a59b3c7..064aaea 100644
--- a/disassembler/Android.bp
+++ b/disassembler/Android.bp
@@ -68,6 +68,11 @@
// For disassembler_arm*.
"libvixld",
],
+
+ apex_available: [
+ "com.android.art.release",
+ "com.android.art.debug",
+ ],
}
cc_library_headers {
@@ -76,4 +81,9 @@
export_include_dirs: [
".",
],
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
diff --git a/dt_fd_forward/export/Android.bp b/dt_fd_forward/export/Android.bp
index c0c16fc..4039196 100644
--- a/dt_fd_forward/export/Android.bp
+++ b/dt_fd_forward/export/Android.bp
@@ -19,4 +19,9 @@
export_include_dirs: ["."],
host_supported: true,
device_supported: true,
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
diff --git a/libartbase/Android.bp b/libartbase/Android.bp
index 8e33752..a9d5db2 100644
--- a/libartbase/Android.bp
+++ b/libartbase/Android.bp
@@ -288,4 +288,9 @@
export_include_dirs: ["."],
shared_libs: ["libbase"],
export_shared_lib_headers: ["libbase"],
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
diff --git a/libdexfile/Android.bp b/libdexfile/Android.bp
index 4f29689..fcfbef3 100644
--- a/libdexfile/Android.bp
+++ b/libdexfile/Android.bp
@@ -263,6 +263,12 @@
enabled: true,
},
},
+
+ apex_available: [
+ "//apex_available:platform",
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
// Make dex_instruction_list.h available for tools/jvmti-agents/titrace
@@ -271,6 +277,11 @@
visibility: ["//art:__subpackages__"],
host_supported: true,
export_include_dirs: ["."],
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
cc_defaults {
@@ -368,6 +379,12 @@
shared_libs: ["liblog"],
header_libs: ["libdexfile_external_headers"],
export_header_lib_headers: ["libdexfile_external_headers"],
+
+ apex_available: [
+ "//apex_available:platform",
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
// The same source file is used in two tests here, so unlike other ART gtests it
diff --git a/libnativebridge/Android.bp b/libnativebridge/Android.bp
index ae04612..e05771a 100644
--- a/libnativebridge/Android.bp
+++ b/libnativebridge/Android.bp
@@ -19,6 +19,12 @@
host_supported: true,
export_include_dirs: ["include"],
+
+ apex_available: [
+ "//apex_available:platform",
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
cc_library {
diff --git a/libnativeloader/Android.bp b/libnativeloader/Android.bp
index 4024d48..645cf64 100644
--- a/libnativeloader/Android.bp
+++ b/libnativeloader/Android.bp
@@ -71,6 +71,11 @@
cc_library_headers {
name: "libnativeloader-headers",
+ apex_available: [
+ "//apex_available:platform",
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
visibility: [
"//art:__subpackages__",
// TODO(b/133140750): Clean this up.
diff --git a/openjdkjvmti/Android.bp b/openjdkjvmti/Android.bp
index a32e738..dca0481 100644
--- a/openjdkjvmti/Android.bp
+++ b/openjdkjvmti/Android.bp
@@ -21,6 +21,12 @@
export_header_lib_headers: ["jni_headers"],
export_include_dirs: ["include"],
sdk_version: "current",
+
+ apex_available: [
+ "//apex_available:platform",
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
cc_defaults {
diff --git a/runtime/Android.bp b/runtime/Android.bp
index db2579b..318f930 100644
--- a/runtime/Android.bp
+++ b/runtime/Android.bp
@@ -702,6 +702,11 @@
host_supported: true,
export_include_dirs: ["."],
sdk_version: "current",
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
genrule {
diff --git a/tools/cpp-define-generator/Android.bp b/tools/cpp-define-generator/Android.bp
index c0b236c..b889a3d 100644
--- a/tools/cpp-define-generator/Android.bp
+++ b/tools/cpp-define-generator/Android.bp
@@ -52,12 +52,22 @@
enabled: false,
},
},
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
cc_library_headers {
name: "cpp-define-generator-definitions",
host_supported: true,
export_include_dirs: ["."],
+
+ apex_available: [
+ "com.android.art.debug",
+ "com.android.art.release",
+ ],
}
python_binary_host {