Commit Graph

18244 Commits

Author SHA1 Message Date
Automerger Merge Worker e0d6f7d9d3 Merge "Document apex and apex_test" am: a871ee2067
Change-Id: If96e254184f5b494eab775d29f234a2ab7740fdb
2020-02-11 03:12:35 +00:00
Treehugger Robot a871ee2067 Merge "Document apex and apex_test" 2020-02-11 03:03:23 +00:00
Automerger Merge Worker 7f811dcd28 Merge "Implement vendor snapshot" am: 705cd4600d
Change-Id: Idc852df62be109ce969e79dd2c54267c7894c1eb
2020-02-10 23:52:53 +00:00
Treehugger Robot 705cd4600d Merge "Implement vendor snapshot" 2020-02-10 23:40:50 +00:00
Jiyong Park fce0b4209f Document apex and apex_test
Bug: 149082647
Test: m
Change-Id: I39e72eecda1d0e2984a3dde4987c4928f58d2afc
2020-02-11 03:56:06 +09:00
Automerger Merge Worker 4fb5002458 Merge "Pass library kind when linking native libraries." am: 2b2aee33a7
Change-Id: I0fcbb598a97ca8d2f292d3c838c67104eb104caf
2020-02-10 17:10:42 +00:00
Ivan Lozano 2b2aee33a7 Merge "Pass library kind when linking native libraries." 2020-02-10 16:50:40 +00:00
Automerger Merge Worker 3a12c94bc9 java_sdk_library_import - Allow it to replace java_sdk_library am: 0bdcb27970
Change-Id: Ic3200366fc92fefdd568d9f87e15e58caf73c254
2020-02-10 10:57:03 +00:00
Automerger Merge Worker f731846322 Merge "java_sdk_library - pass patch_module through to stubs library" am: 3b531e3c85
Change-Id: I5ce03ac14084048f2223fe14b26f86fc52b4ebd2
2020-02-10 10:56:53 +00:00
Paul Duffin 0bdcb27970 java_sdk_library_import - Allow it to replace java_sdk_library
Previously a java_sdk_library_import module did not replace the
corresponding java_sdk_library module, even when it was marked as
prefer=true. That is because the java_sdk_library_import had an empty
set of sources.	However, the stubs modules that are created by the
java_sdk_library_import did override the stubs modules created by the
corresponding java_sdk_library module.

That created inconsistent behavior between the cases where only the
prebuilt is available and both source and prebuilt are available and
the prebuilt is preferred. e.g. assume a java_sdk_library/import module
called SDKLIB.

When both prebuilt and source modules are available for SDKLIB then
even if the prebuilt is preferred then any dependencies on the
SDKLIB module would use the source module.

This change fixes that inconsisteny by making the array of sources
non-empty.

Bug: 148080325
Test: m droid && TARGET_BUILD_APPS=Camera2 m
Change-Id: I25395e020393921735ada20c5492f27f1260f6c5
2020-02-10 10:45:29 +00:00
Paul Duffin 3b531e3c85 Merge "java_sdk_library - pass patch_module through to stubs library" 2020-02-10 10:42:34 +00:00
Automerger Merge Worker 1cf0db8136 Merge "add walkPayloadDeps" am: 58b5030e30
Change-Id: I6ad05ac167f0b50b451fe905f69c4f04b9e234c2
2020-02-10 05:41:38 +00:00
Jiyong Park 58b5030e30 Merge "add walkPayloadDeps" 2020-02-10 05:20:59 +00:00
Automerger Merge Worker 77baed21ee Merge "<apexname>-installed-file.txt shows symlinks" am: 22f3ce1ea7
Change-Id: I11099256c34ba31054dca2b83367ff0f36fde8bd
2020-02-10 03:55:52 +00:00
Jiyong Park 22f3ce1ea7 Merge "<apexname>-installed-file.txt shows symlinks" 2020-02-10 03:44:00 +00:00
Automerger Merge Worker a80e0e808b Merge "Remove UseApexImage and GenerateApexImage." am: d862f0bce7
Change-Id: I1e8c4bd829f8538ce013380de2654f10ce970907
2020-02-09 23:17:22 +00:00
Nicolas Geoffray d862f0bce7 Merge "Remove UseApexImage and GenerateApexImage." 2020-02-09 22:53:56 +00:00
Automerger Merge Worker 0130538069 Fix sdk aidl include for droiddoc am: 26bf49b0b2
Change-Id: I32175997110d76f39ac8442aaeb0f1c07cefd701
2020-02-09 13:31:17 +00:00
Anton Hansson 26bf49b0b2 Fix sdk aidl include for droiddoc
Prior to this change droidstubs modules that set sdk_version
did not get framework.aidl added to its aidl includes.

Bug: 149138391
Test: patch CL in bug && m system_aidl_test-droidstubs
Change-Id: I92ab344c8a4311e10c1e5c8ebf525fa2dc704075
(cherry picked from commit f278ca60e06da86c67f6a3865c290f8451657ce9)
2020-02-08 20:37:07 +00:00
Paul Duffin ab8da5dd53 java_sdk_library - pass patch_module through to stubs library
When building java.lang classes it is necessary to compile them using
patch_module: "java.base". This change causes patch_module to be passed
through to the java_library created to compile the stubs to allow this
to be used to generate stubs for java.lang.

Test: m droid
Change-Id: I7c27953a5d782eeedd7f25e849ab444d28e28228
2020-02-08 10:38:52 +00:00
Jiyong Park bd63a108a0 <apexname>-installed-file.txt shows symlinks
Bug: 147605944
Test: m and inspect the generated txt files
Change-Id: I26ecaf66a531478d22fb4611bb4ea19e92ef132e
2020-02-08 17:18:03 +09:00
Automerger Merge Worker be6804a21d Merge "Differentiate between exported and internal sdk members" am: 7a8a425566
Change-Id: Ia768672d2b3daecb4cd24612489887ef7aedc8a6
2020-02-08 00:17:42 +00:00
Treehugger Robot 7a8a425566 Merge "Differentiate between exported and internal sdk members" 2020-02-08 00:12:04 +00:00
Automerger Merge Worker 9bbb25fc3a Merge "Add android.hardware.light-ndk_platform to vndkMustUseVendorVariantList" am: c17a04dbbb
Change-Id: I00ac5ac05893c9746cc1af622a172aa4295fc59f
2020-02-07 20:36:09 +00:00
Treehugger Robot c17a04dbbb Merge "Add android.hardware.light-ndk_platform to vndkMustUseVendorVariantList" 2020-02-07 20:22:52 +00:00
Automerger Merge Worker 47511a0393 Merge "Add java_system_modules to sdk/module_exports" am: 568a82a36e
Change-Id: I74d7795e5a22c11a253508a37b2215bedcd2b778
2020-02-07 18:11:55 +00:00
Treehugger Robot 568a82a36e Merge "Add java_system_modules to sdk/module_exports" 2020-02-07 17:57:08 +00:00
Automerger Merge Worker c5518698b6 Merge "Add support for transitive sdk members" am: 7be7886960
Change-Id: Icd8a0bde8157871250d980cc260794cd039da35b
2020-02-07 17:38:02 +00:00
Treehugger Robot 7be7886960 Merge "Add support for transitive sdk members" 2020-02-07 17:18:36 +00:00
Automerger Merge Worker aa112da5c3 Merge "Support dexpreopt against the primary boot image." am: 396b950a1b
Change-Id: Ib77e51d5f47c54bb5533dbe7560dfbcf4728d11e
2020-02-07 14:30:47 +00:00
Nicolas Geoffray 73d5983af0 Remove UseApexImage and GenerateApexImage.
These options are not used anymore.

Bug: 119800099
Test: m
Change-Id: I4568ff23ed71a5c288ed87828aed6e4bc4f8bd4d
2020-02-07 14:19:28 +00:00
Vladimir Marko 396b950a1b Merge "Support dexpreopt against the primary boot image." 2020-02-07 14:12:52 +00:00
Paul Duffin 7291095d82 Differentiate between exported and internal sdk members
Internal sdk members are used by an sdk member but not exported by the
sdk. The exported sdk members are those listed explicitly in one of the
sdk member list properties, e.g. java_header_libs.

The prebuilts of an internal sdk member use a unique name so that they
do not clash with the source module. The use of the module internally
is an implementation detail that must not have any effect outside the
snapshot. Having the same name as the source module could cause it to
override the source module, hence why it needs a unique name.

Similarly, they are marked as private so as to prevent their accidental
use from outside the snapshot.

Bug: 142940300
Test: m nothing
Change-Id: Id5364b410be0592f65666afb3e40e9d3f020251c
2020-02-07 14:03:03 +00:00
Paul Duffin 7b81f5e9d7 Add java_system_modules to sdk/module_exports
Adds an SdkMemberType implementation for java_system_modules. It
specifies that java_system_modules can be used with sdk as well as
module_exports, and also that the libs property should be included
as transitive members in the sdk.

It also adds support for treating appropriate tagged properties in
the snapshot prebuilts module as references to sdk members so that
they are correctly transformed when creating the versioned modules.

Bug: 142940300
Test: m nothing
Change-Id: Ic10b5a6d5b92b6018334fe876f06feaf79cc55e9
2020-02-07 14:03:03 +00:00
Paul Duffin f4ae4f1390 Add support for transitive sdk members
Allow an sdk member type to treat some of its dependencies as being
members of the sdk.

Needed for the java_system_modules type whose libs property are an
implementation detail of the system module and so should not be
explicitly listed in the sdk module but still have to be included in
the sdk snapshot.

Bug: 142940300
Test: m nothing
Change-Id: I90f37dae269ef64a6fe9debd0bbaf29a64dd74d8
2020-02-07 14:03:03 +00:00
Ivan Lozano 6aa660218e Pass library kind when linking native libraries.
When linking native libraries with rustc, be explicit about the
kind of native library being linked. This prevents confusion when
two kinds of one library (e.g. static/dynamic) are available in
the library search paths.

Bug: 147140513
Test: The correct prebuilt is selected when linking native prebuilts.
Change-Id: I37975bcd284e6c33ce3dd45fab8a3b5011b0803b
2020-02-07 08:29:13 -05:00
Automerger Merge Worker aaf63bc5d5 Merge "Fix lib name resolution if extension is substring." am: f3c9d74cfa
Change-Id: Icac222c1d1f7e1d6e61c795e6e31c201668df83a
2020-02-07 13:27:52 +00:00
Ivan Lozano f3c9d74cfa Merge "Fix lib name resolution if extension is substring." 2020-02-07 13:17:31 +00:00
Automerger Merge Worker e1c279f889 Merge "java_sdk_library - Allow it to be replaced by prebuilt" am: 9be2556d90
Change-Id: Iccf2bf512c559dd505266c152a0fe14cd3a8d9fc
2020-02-07 11:34:10 +00:00
Treehugger Robot 9be2556d90 Merge "java_sdk_library - Allow it to be replaced by prebuilt" 2020-02-07 11:16:41 +00:00
Vladimir Marko 40139d6422 Support dexpreopt against the primary boot image.
Framework and other dex files are used without image.

Test: taimen-userdebug boots when built with
      DEXPREOPT_USE_ART_IMAGE=true
Test: Check logcat for checksum verification failures.
      (Build ART with extra logging in OatFileAssistant.)
Test: Check that bootclasspath-checksums from some prebuilt
      oat files (say input.odex) contain only one image
      checksum followed by dex file checksums with
          grep -az -A1 -E '^bootclasspath-checksums$' <oat-file> | \
          xargs -0 echo | gawk '{print $2}'
Bug: 119800099
Change-Id: I65c2f247656e41f2c37df1ecb9e06af7dabab76e
2020-02-07 10:32:50 +00:00
Jiyong Park 201cedd608 add walkPayloadDeps
The function visits dependencies of an APEX that contribute to the
payload. checkApexAvailability is rewritten using the generic function.
There is no change in behavior.

Bug: N/A
Test: m

Change-Id: I1a8b4eb0a60a432f667a61b4f6f457c3b8f1cd3d
2020-02-07 18:48:26 +09:00
Automerger Merge Worker 40f770951d Merge "Do not add bootstrap libs as providing from apex" am: 570147469f
Change-Id: Ife32b401186b61365e915d9202c18b130aa0dce3
2020-02-07 07:44:06 +00:00
Treehugger Robot 570147469f Merge "Do not add bootstrap libs as providing from apex" 2020-02-07 07:23:14 +00:00
Automerger Merge Worker a0be49cd72 Merge "Don't use apexName where apexBundleName is expected" am: f48392279c
Change-Id: Ia8c256873f0044c1020503910c1fe7edd9634c04
2020-02-07 05:49:02 +00:00
Automerger Merge Worker bef2f16ca4 Merge "java_sdk_library - Use prebuilt/prefer for unbundled app builds" am: 7300095182
Change-Id: I4ccfd4f9ea3271fab429361ca3a8e2b7bd8b012e
2020-02-07 05:48:45 +00:00
Jiyong Park f48392279c Merge "Don't use apexName where apexBundleName is expected" 2020-02-07 05:41:26 +00:00
Treehugger Robot 7300095182 Merge "java_sdk_library - Use prebuilt/prefer for unbundled app builds" 2020-02-07 05:28:35 +00:00
Jiyong Park a594801999 Don't use apexName where apexBundleName is expected
With I63f8a1de463011c6e0b97f5f6eee83103e22bc30, a flattened APEX is
installed to /system/apex/<apexBundleName> not /system/apex/<apexName>.
The change was to be in sync with the non-flattened APEXes that are
installed to /system/apex/<apexBundleName>.apex.

apexName is from the 'name' property while apexBundleName is from the
'apex_name' property. The two names are mostly the same, but can be
different, notably for the ART and the VNDK APEXes. e,g apexName =
com.android.art, apexBundleName = com.android.art.release.

However, there was a bug in the fix; we haven't updated the path for the
flattened APEXes in other places: filecontexts and symlinks. As a
result, the files for the APEXes where apexName is different from
apexBundleName were incorrectly labeled and caused a boot loop.

Fixing the bug.

Bug: 140136207
Bug: 149013536
Test: m
Test: OVERRIDE_TARGET_FLATTEN_APEX=true m; then inspect the built
system.img to verify that
/system/apex/com.android.vndk.current/lib/libcrypto.so is correctly
labeled as system_lib_file.

Exempt-From-Owner-Approval: cherry-pick from internal

Merged-In: I4aaf674a5daeabab5ed6e7025c5389821ee9a013
(cherry picked from commit be95e6b245)
Change-Id: I4aaf674a5daeabab5ed6e7025c5389821ee9a013
2020-02-07 13:20:13 +09:00
Automerger Merge Worker 4fb6707eeb Merge changes I38fb22b2,I281bdefe,Ieaaa590c am: df51b061cd
Change-Id: I26a4f9512649c9a505faeffb693bd238e7b1d7a9
2020-02-07 03:54:15 +00:00