Commit graph

264 commits

Author SHA1 Message Date
Jaewoong Jung
75b78df026 Merge "Add apex_set module." am: 805f2492e8 am: 23b4707ddc
Change-Id: I47e7a67ea8b2af27860531e67dd66c854b6bca70
2020-05-15 23:43:41 +00:00
Jaewoong Jung
fa00c06187 Add apex_set module.
apex_set takes an .apks file that contains a set of prebuilt apexes with
different configurations. It uses extract_apks to select and install the
best matching one for the current target.

Bug: 153456259
Test: apex_test.go
Test: com.android.media.apks
Change-Id: I1da8bbcf1611b7c580a0cb225856cbd7029cc0a7
2020-05-15 11:02:01 -07:00
Jaewoong Jung
eb899879a1 Merge changes from topic "prebuilt_apk_set" am: a3e8885658 am: c067b0280c
Change-Id: Id7848044c6a0bbf18c005fc04e037b8ae4345903
2020-05-15 12:54:15 +00:00
Sasha Smundak
a7856c0077 Implement android_app_set module
Bug: 152319766
Test: manual and builtin
Change-Id: Id0877476f9ae23311d92c0b59a9c568140ab4119
2020-05-14 19:01:11 -07:00
Colin Cross
13f9a2ec06 Merge "Don't use SDK variant for vendor JNI libraries" am: cb1d161666 am: d75524f322
Change-Id: I5684f17281e31e8d6ffc9d0c7541d55c1bbd0bba
2020-05-15 00:17:18 +00:00
Treehugger Robot
dcd0fc4be7 Merge "Add signing certificate lineage support to soong" 2020-05-14 23:11:24 +00:00
Colin Cross
cb1d161666 Merge "Don't use SDK variant for vendor JNI libraries" 2020-05-14 22:59:47 +00:00
Treehugger Robot
b24201202c Merge "Reland "enforce sdk_version for JNI libs for updatable APKs"" am: bb008e6213 am: eb07296b5b
Change-Id: Ibc0335f3cdf08c13ea9dd26472db50b91c63135c
2020-05-13 23:50:51 +00:00
Liz Kammer
e2b27f473f Add signing certificate lineage support to soong
(This is a cherry pick.)

Test: app_test
Bug: 153366049
Merged-In: I65a92d6c40057dcc01950991fb7be485de1c9080
Change-Id: I65a92d6c40057dcc01950991fb7be485de1c9080
2020-05-13 14:30:53 -07:00
Colin Cross
c2d24050c5 Don't use SDK variant for vendor JNI libraries
Vendor JNI libraries already have stable APIs enforced by the VNDK,
they shouldn't use SDK variants.

Bug: 156225490
Test: TestJNISDK
Change-Id: I21ba67e8e9fb05016caf5888129adc1a939545c2
2020-05-13 11:10:38 -07:00
Jooyung Han
bbc3fb780b Reland "enforce sdk_version for JNI libs for updatable APKs"
JNI libs for "updatable" APKs or APKs in "updatable" APEXes should set
sdk_version which is equal to or less than APK's min_sdk_version.

In fact, we'd better check if min_sdk_version of JNI libs matches(or is
earlier than) min_sdk_version of the APK. But for now the build system
can't handle sdk_version/min_sdk_version correctly for JNI libs. That's
why sdk_version of JNI libs is enforced to match with min_sdk_version
of APK in this change.

(original commit: 98c4750f39)

Bug: 145796956
Test: m
Change-Id: I08543ccee7dfda0559a1fca108ceb5c28f84943f
2020-05-14 00:19:45 +09:00
Colin Cross
b85063c64a Merge "Revert "enforce sdk_version for JNI libs for updatable APKs"" am: 2bdf0da9e7 am: 6e55eb8f69
Change-Id: I88b97cb5794aa17ebf11903847e0f57f8517f6ad
2020-05-13 01:55:38 +00:00
Colin Cross
2bdf0da9e7 Merge "Revert "enforce sdk_version for JNI libs for updatable APKs"" 2020-05-13 01:26:25 +00:00
Jooyung Han
cc928d9059 Revert "enforce sdk_version for JNI libs for updatable APKs"
This reverts commit 98c4750f39.

Reason for revert: broken builds

Change-Id: Icd3a9e226ff8ff288b682757cded9f43069ebc5e
2020-05-13 01:22:56 +00:00
Treehugger Robot
58461c4a42 Merge "enforce sdk_version for JNI libs for updatable APKs" am: 1852b586bf am: 548c377bee
Change-Id: Icb9cd88d908d28eebd89d25429b64fc30faf60bb
2020-05-13 01:22:49 +00:00
Treehugger Robot
1852b586bf Merge "enforce sdk_version for JNI libs for updatable APKs" 2020-05-13 00:57:34 +00:00
satayev
5849e9512d Merge "Introduce app -deps-info." am: ecea813997 am: 72d9fc732d
Change-Id: Ic0dc82dc5293155d4fe628c0ab03ec9a78e94f1c
2020-05-11 19:30:34 +00:00
satayev
ecea813997 Merge "Introduce app -deps-info." 2020-05-11 16:51:30 +00:00
Artur Satayev
1111b84822 Introduce app -deps-info.
Similar to APEX-deps-info, app deps info produces two lists with
transitive dependencies.

Bug: 149622332
Test: m NetworkStack-deps-info
Change-Id: Ic6d94df3b7b4be5afe328a0abe768beee1a58362
Exempt-From-Owner-Approval: previous patch approved.
2020-05-11 16:51:06 +00:00
Treehugger Robot
24442e09af Merge "Add error checking and tests for jni_uses_sdk_apis and jni_uses_platform_apis" am: 9c3a1291e2 am: 51751012af
Change-Id: I125ad075bad971eb7a4e7fc269d2756c4cb20b19
2020-05-09 02:46:00 +00:00
Colin Cross
3c007704c7 Add error checking and tests for jni_uses_sdk_apis and jni_uses_platform_apis
Check that jni_uses_sdk_apis and jni_uses_platform_apis are consistent
with sdk_version, and add tests that they select the right variant.

Bug: 154665579
Test: app_test.go
Change-Id: I544a4f881ba16dacd7e74cd480c095091b3cf667
2020-05-08 16:55:14 -07:00
Liz Kammer
b339011848 Merge "Add signing certificate lineage support to soong" into rvc-dev am: 5c5c4d9332
Change-Id: I8d93c7ad3fb076fa7f8b3a3d71e668b9c0a41305
2020-05-08 20:30:38 +00:00
Liz Kammer
5c5c4d9332 Merge "Add signing certificate lineage support to soong" into rvc-dev 2020-05-08 20:26:39 +00:00
Liz Kammer
70dd74dde7 Add signing certificate lineage support to soong
Test: app_test
Bug: 153366049

Change-Id: I65a92d6c40057dcc01950991fb7be485de1c9080
2020-05-08 09:50:42 -07:00
Treehugger Robot
fda00d6f1c Merge "Skip dexpreopting android_test_import modules" am: cf23ab4cd8 am: a7f446af4a
Change-Id: I991362bb18254731726b1c6d533ae3ace7b6190c
2020-05-07 22:02:32 +00:00
Colin Cross
f30c453df1 Skip dexpreopting android_test_import modules
android_test_import modules should be labelled as tests so they are
not dexpreopted.

Bug: 155778135
Test: m CtsCorruptApkTests_Compressed_Q
Change-Id: I7baa5405d03df03920b01616b030ba77f882a77e
Merged-In: I7baa5405d03df03920b01616b030ba77f882a77e
2020-05-07 12:40:27 -07:00
Colin Cross
c80828d567 Skip dexpreopting android_test_import modules
android_test_import modules should be labelled as tests so they are
not dexpreopted.

Bug: 155778135
Test: m CtsCorruptApkTests_Compressed_Q
Change-Id: I7baa5405d03df03920b01616b030ba77f882a77e
2020-05-07 12:06:14 -07:00
Ivan Lozano
7c3358dd60 Merge "Add gcov coverage support to Rust modules." am: 6c4e5c05c3 am: acdf2ac701
Change-Id: Id236afb83e583a93020803302a61dbf46904c295
2020-05-07 18:41:29 +00:00
Colin Cross
7500f46b95 Merge "Add jni_uses_sdk_apis" 2020-05-07 18:09:47 +00:00
Colin Cross
7204cf0e6a Add jni_uses_sdk_apis
NetworkStackTests is using platform APIs for its Java code, but needs
to use portable JNI libraries.  Add a jni_uses_sdk_apis so that it
can select the SDK variants of JNI libraries even though it doesn't
set sdk_version.

(clean cherry-pick from internal branch)
Bug: 154665579
Test: atest NetworkStackTests
Merged-In: I841fb761ec1c1ab8596aac44e01eb7eb91428006
Change-Id: I841fb761ec1c1ab8596aac44e01eb7eb91428006
2020-05-07 18:09:06 +00:00
Ivan Lozano
6c4e5c05c3 Merge "Add gcov coverage support to Rust modules." 2020-05-07 17:56:43 +00:00
Colin Cross
02250e9b4e Merge "Add jni_uses_sdk_apis" into rvc-dev am: 2572225993
Change-Id: I389ecb02c7e7041ff49623f37a9153b7134c7840
2020-05-07 16:42:53 +00:00
Colin Cross
2572225993 Merge "Add jni_uses_sdk_apis" into rvc-dev 2020-05-07 16:21:51 +00:00
Colin Cross
76583a443e Add jni_uses_sdk_apis
NetworkStackTests is using platform APIs for its Java code, but needs
to use portable JNI libraries.  Add a jni_uses_sdk_apis so that it
can select the SDK variants of JNI libraries even though it doesn't
set sdk_version.

Bug: 154665579
Test: atest NetworkStackTests
Change-Id: I841fb761ec1c1ab8596aac44e01eb7eb91428006
2020-05-06 17:56:46 -07:00
Jaewoong Jung
a689ffe207 Make android_app_import multi targets arch module.
This makes it consistent with android_app. Also, most android_app_import
modules with JNI libs target a single arch.

(This is a cherry-pick change.)

Test: TreeHugger
Bug: 154281342
Change-Id: I5bbb2d2b733bbd6b868898285683ba5ff45be10b
Merged-In: I5bbb2d2b733bbd6b868898285683ba5ff45be10b
2020-05-06 15:19:42 -07:00
Jooyung Han
98c4750f39 enforce sdk_version for JNI libs for updatable APKs
JNI libs for "updatable" APKs or APKs in "updatable" APEXes should set
sdk_version which is equal to or less than APK's min_sdk_version.

In fact, we'd better check if min_sdk_version of JNI libs matches(or is
earlier than) min_sdk_version of the APK. But for now the build system
can't handle sdk_version/min_sdk_version correctly for JNI libs. That's
why sdk_version of JNI libs is enforced to match with min_sdk_version
of APK in this change.

Bug: 145796956
Test: m
Change-Id: Iee7e09dd25bd139d84d50f6a77836b4068c78ea9
2020-05-06 13:54:34 +09:00
Ivan Lozano
a0cd8f9acb Add gcov coverage support to Rust modules.
This adds gcov coverage support for Rust device library and binary
modules (including test modules). Support is provided to pass Rust
static library gcno files to CC modules and visa versa.

Additional changes:
 * Begin mutator added for Rust modules.
 * SuffixInList added to android package.
 * CoverageEnabled added to Coverage interface.
 * CoverageFiles added to LinkableLibrary interface.
 * Fix in coverage mutator for non-CC modules which marked the wrong
   variant as the coverage variant.
 * Added coverage libraries to the cc.GatherRequiredDepsForTest.

Bug: 146448203
Test: NATIVE_COVERAGE=true COVERAGE_PATHS='*' m -j <rust_module>
Change-Id: If20728bdde42a1dd544a35a40f0d981b80a5835f
2020-05-05 10:30:15 -04:00
Jaewoong Jung
c896a76a5d Merge "Make android_app_import multi targets arch module." am: baf8c3a804 am: 068e22ebb9
Change-Id: I82330a9900ac3426e536866f1cbdb3601b07ed69
2020-05-05 01:48:43 +00:00
Colin Cross
2a5fb91370 Merge changes from topic "sdk_version_variant" into rvc-dev
* changes:
  Add sdk mutator for native modules
  Require apps built against the SDK to use JNI built against the NDK
2020-05-02 01:41:18 +00:00
Jaewoong Jung
243688ea1b Make android_app_import multi targets arch module.
This makes it consistent with android_app. Also, most android_app_import
modules with JNI libs target a single arch.

Test: TreeHugger
Bug: 154281342
Change-Id: I5bbb2d2b733bbd6b868898285683ba5ff45be10b
2020-05-01 15:50:08 -07:00
Songchun Fan
4b25e319e6 Revert "[soong] new field in Android.bp to request APK signing V4"
This reverts commit 17d69e3484.

Reason for revert: This new field is not useful without dependencies in aosp

Test: builds
Change-Id: I87bd820cd6dbc5274ce3d28c4578381718aa805d
Merged-In: I70d6f7dc751510311b03e245b2189a76b395a49c
2020-05-01 11:29:36 -07:00
Treehugger Robot
6e2fb5c0cd Merge "soong: Add support for override_runtime_resource_overlay" 2020-04-29 17:30:00 +00:00
Liz Kammer
9c11f7fba5 Merge "Document Instrumentation_for android app tests." am: 8e25bcb895 am: 189f6704c1
Change-Id: Idfb4f575e84eb865545e06e355efff4c425d7331
2020-04-29 16:39:47 +00:00
Roshan Pius
4df2bc76d5 soong: Add support for override_runtime_resource_overlay
Bug: 154960712
Test: go test ./... -test.v -run TestOverrideAndroidApp
(cherry-picked from ag/11270710)

Change-Id: I8ca9d173b6ab7f9306c83c2b434107111aa2ca88
Merged-In: I8ca9d173b6ab7f9306c83c2b434107111aa2ca88
2020-04-29 09:01:51 -07:00
Liz Kammer
6b0c55263c Document Instrumentation_for android app tests.
Test: m soong_docs

Change-Id: I84fd20ea563fc75dc04ac41f44f2f53df994925f
2020-04-28 16:45:51 -07:00
Roshan Pius
db48e6b051 Merge "soong: Add support for override_runtime_resource_overlay" into rvc-dev am: 016159dfe4
Change-Id: Ie6a180887eab39fbf46a583a2629c2924add4c5b
2020-04-28 22:11:40 +00:00
Roshan Pius
016159dfe4 Merge "soong: Add support for override_runtime_resource_overlay" into rvc-dev 2020-04-28 22:09:15 +00:00
Roshan Pius
b830796ca4 soong: Add support for override_runtime_resource_overlay
Bug: 154960712
Test: go test ./... -test.v -run TestOverrideAndroidApp
Change-Id: I8ca9d173b6ab7f9306c83c2b434107111aa2ca88
2020-04-28 13:08:55 -07:00
Treehugger Robot
c869812b04 Merge "runtime_resource_overlay can be included in APEXes" 2020-04-28 17:13:26 +00:00
Jiyong Park
69aeba9982 runtime_resource_overlay can be included in APEXes
runtime_resource_overlay is put to an APEX via 'apps' property. It is
placed under ./overlay directory in it.

Bug: 154822536
Test: m
Change-Id: I8edf4a26c26368c52fb7b327b2ecc829f21ea148
2020-04-28 22:55:54 +09:00