From 9e726b842744a939d4196e8d78ebaf17c7300649 Mon Sep 17 00:00:00 2001 From: Ulya Trafimovich Date: Mon, 7 Sep 2020 14:07:28 +0100 Subject: Add information. The required "org.apache.http.legacy" is in the manifest for StatementService. It must be explicitly added to `uses_libs` because since https://r.android.com/1424793 Soong considers it optional (so it would add it to `optional_uses_libs` instead of `uses_libs`). Ideally, "org.apache.http.legacy" should be automatically treated as required if it is an explicit dependency and the targetSdkVersion >= 28 and minSdkVersion >= 28 (28 is the version in which "org.apache.http.legacy" was added to platform), but Soong does not have the information available to make that decision, so it defers to optional in order to be safe, and so `uses_libs` is needed to override that. "android.test.runner" is added to CtsShim because it's in the manifest, but not one of the dependencies, so Soong cannot add it auptmatically. Bug: 132357300 Test: lunch cf_x86_phone-userdebug && m Test: m out/soong/.intermediates/frameworks/base/packages/CtsShim/build/CtsShimPrivUpgrade/android_common/manifest_check/AndroidManifest.xml Test: m out/soong/.intermediates/frameworks/base/packages/CtsShim/build/CtsShimPrivUpgradeWrongSHA/android_common/manifest_check/AndroidManifest.xml Test: m out/soong/.intermediates/frameworks/base/packages/StatementService/StatementService/android_common/manifest_check/AndroidManifest.xml Change-Id: Id12741c9b3cd6dd7676bc4c6b9db08b815361e4e --- packages/CtsShim/build/Android.bp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'packages/CtsShim') diff --git a/packages/CtsShim/build/Android.bp b/packages/CtsShim/build/Android.bp index 43e386852713..14a3376380df 100644 --- a/packages/CtsShim/build/Android.bp +++ b/packages/CtsShim/build/Android.bp @@ -34,6 +34,8 @@ android_app { compile_multilib: "both", jni_libs: ["libshim_jni"], + + uses_libs: ["android.test.runner"], } genrule { @@ -108,6 +110,7 @@ android_app { compile_multilib: "both", jni_libs: ["libshim_jni"], + uses_libs: ["android.test.runner"], } //########################################################## -- cgit v1.2.3-59-g8ed1b