diff options
| -rw-r--r-- | build/apex/Android.bp | 11 | ||||
| -rwxr-xr-x | build/apex/runtests.sh | 19 |
2 files changed, 27 insertions, 3 deletions
diff --git a/build/apex/Android.bp b/build/apex/Android.bp index aa199d3c92..9bf65512b3 100644 --- a/build/apex/Android.bp +++ b/build/apex/Android.bp @@ -85,6 +85,15 @@ libcore_native_shared_libs = [ "libopenjdk", ] +// Java libraries +libcore_target_java_libs = [ + "core-oj", + "core-libart", + "okhttp", + "bouncycastle", + "apache-xml", +] + apex_key { name: "com.android.runtime.key", public_key: "com.android.runtime.avbpubkey", @@ -108,6 +117,7 @@ apex { name: "com.android.runtime.release", compile_multilib: "both", manifest: "manifest.json", + java_libs: libcore_target_java_libs, native_shared_libs: art_runtime_base_native_shared_libs + bionic_native_shared_libs + libcore_native_shared_libs, @@ -137,6 +147,7 @@ apex { name: "com.android.runtime.debug", compile_multilib: "both", manifest: "manifest.json", + java_libs: libcore_target_java_libs, native_shared_libs: art_runtime_base_native_shared_libs + art_runtime_debug_native_shared_libs + bionic_native_shared_libs diff --git a/build/apex/runtests.sh b/build/apex/runtests.sh index 4c0e772ccd..83c42bcf9a 100755 --- a/build/apex/runtests.sh +++ b/build/apex/runtests.sh @@ -144,6 +144,10 @@ function check_library { || fail_check "Cannot find library '$1' in mounted image" } +function check_java_library { + [[ -x "$mount_point/javalib/$1" ]] || fail_check "Cannot find java library '$1' in mounted image" +} + # Check contents of APEX payload located in `$mount_point`. function check_release_contents { # Check that the mounted image contains an APEX manifest. @@ -189,6 +193,15 @@ function check_release_contents { # ... # # ? + + # TODO: Enable for host + if [ $1 != "com.android.runtime.host" ]; then + check_java_library core-oj.jar + check_java_library core-libart.jar + check_java_library okhttp.jar + check_java_library bouncycastle.jar + check_java_library apache-xml.jar + fi } # Check debug contents of APEX payload located in `$mount_point`. @@ -286,7 +299,7 @@ maybe_list_apex_contents "$mount_point" # Run tests on APEX package. say "Checking APEX package $apex_module" -check_release_contents +check_release_contents "$apex_module" # Clean up. trap - EXIT @@ -319,7 +332,7 @@ maybe_list_apex_contents "$mount_point" # Run tests on APEX package. say "Checking APEX package $apex_module" -check_release_contents +check_release_contents "$apex_module" check_debug_contents # Check for files pulled in from debug target-only oatdump. check_binary oatdump @@ -390,7 +403,7 @@ maybe_list_apex_contents "$mount_point" # Run tests on APEX package. say "Checking APEX package $apex_module" -check_release_contents +check_release_contents "$apex_module" check_debug_contents # Clean up. |