Commit Graph

20636 Commits

Author SHA1 Message Date
Sasha Smundak 06fcac6f24 Handle universal APK case in extract_apks
Bug: 157081961
Test: manual and builtin
Change-Id: I5ac64c845328a54024171da41c369050243462b0
2020-05-20 00:38:02 -07:00
Nikita Ioffe 5f6771e160 Always set targetSdkLevel to DefaultAppTargetSdk
Test: m
Bug: 156914912
Change-Id: Ibe63352c2fc474dd816d87ac79b31a56d32b35d2
2020-05-20 00:20:00 +01:00
Liz Kammer 7fe241f623 Add signing lineage for runtime_resource_overlay
Add ability to specify a signing lineage file for
runtime_resource_overlay.

Test: app_test.go
Bug: 153366049
Change-Id: I68286bc0caa9daad6ef74db39f7750924f1d93dd
2020-05-19 16:16:42 -07:00
TreeHugger Robot bf5c640aa5 Merge "Add --no-force-assign-all for java_sdk_library" into rvc-dev 2020-05-19 23:08:47 +00:00
Paul Duffin 31b84c83bf Add --no-force-assign-all for java_sdk_library
Previously, the flag was only added for java_library modules that were
being instrumented. This will also add if for java_sdk_library modules
too.

Bug: 156705688
Test: TARGET_BUILD_VARIANT=userdebug PRODUCT=mainline_modules_x86 EMMA_INSTRUMENT=true NATIVE_COVERAGE=true ./vendor/google/build/build_unbundled_coverage_mainline_module.sh -j8
Change-Id: I5d06ec037007b1770748df24a2e2e8691f177f4f
2020-05-19 21:18:05 +01:00
Jeff Tinker 999cff9a36 Merge "Revert "Generate the ART boot image for host as well (used by ART tests)."" into rvc-dev 2020-05-19 18:10:51 +00:00
Jeff Tinker 74cc81c399 Revert "Generate the ART boot image for host as well (used by ART tests)."
This reverts commit e920d2d0c5.

Reason for revert: b/157053931 - Broken test:
com.android.devicehealthchecks.SystemAppCheck#system_app_native_crash
on git_rvc-dev on crosshatch-userdebug at 6510182

This CL is the only change in this build range so seems likely to be
the culprit.

Build break bug number:
bug:157053931

Original CL bug numbers:
Bug: 147817558
Bug: 147819342
Bug: 156649984

Change-Id: If8bf2f646789b583adcbfbc5df263ce953c05b76
2020-05-19 18:08:01 +00:00
TreeHugger Robot 47df9bc10d Merge "Add support for remotely executing header-abi-dumper actions." into rvc-dev 2020-05-19 16:27:38 +00:00
Ulyana Trafimovich b3b814cbdd Merge "Generate the ART boot image for host as well (used by ART tests)." into rvc-dev 2020-05-19 14:13:16 +00:00
Treehugger Robot 35a91836e4 Add support for remotely executing header-abi-dumper actions.
Bug: b/156613606
Test: built with and without RBE_ABI_DUMPER set.
Change-Id: Ie752c07325453076d191813eaa50da03e3a0c2d8
Merged-In: Ie752c07325453076d191813eaa50da03e3a0c2d8
2020-05-19 09:55:36 -04:00
Ramy Medhat 9adb15e4d3 Merge "Add implicit outputs to link actions Bug: b/154733231" into rvc-dev 2020-05-19 13:43:06 +00:00
David Srbecky e920d2d0c5 Generate the ART boot image for host as well (used by ART tests).
This will allow us to remove the core.art image compiled in make.

Test: lunch aosp_x86_64 && m test-art-host-gtest
Bug: 147817558
Bug: 147819342
Bug: 156649984
Change-Id: I864f72198d875dc1421c9c029a683bafbe7b71ac
Merged-In: I864f72198d875dc1421c9c029a683bafbe7b71ac
(cherry picked from commit 7f8dac1254)
2020-05-19 09:44:51 +01:00
Stephen Hines 13b041d6ea Merge "Default to zero-initialization instead of pattern." into rvc-dev 2020-05-18 22:18:21 +00:00
Liz Kammer 2bc57f6afe Add signing linage support for android_app_import
Test: app_test
Bug: 153366049
Change-Id: I260f198637a1a0f8b3373250413356785c56588a
2020-05-18 10:46:19 -07:00
Paul Duffin c8f2f186d1 Extract common behavior between Module and Import
Although the duplication being eliminated here is minimal follow up
changes will add more functionality that is common to Module and
Import.

Test: m nothing
Bug: 156723295
Merged-In: I1733405526764272beba63470a9bc8a958d41024
Change-Id: I1733405526764272beba63470a9bc8a958d41024
(cherry picked from commit 0d3c2e136b)
2020-05-18 11:31:53 +01:00
Paul Duffin c5d954a48d java_sdk_library: Remove unnecessary qualification of fields
Fields in embedded structures can be accessed without qualifying them
by the type of the embedded structure.

This reduces the size of follow up changes that switch java_sdk_library
from embedding Library.

Bug: 156618935
Test: m nothing
Merged-In: I84f294c6f02d5089055130c63f5fb0538a1f21b9
Change-Id: I84f294c6f02d5089055130c63f5fb0538a1f21b9
(cherry picked from commit a18abc2a61)
2020-05-18 11:30:19 +01:00
easoncylee ba60625021 Add test_mainline_modules to the auto-gen test config(AndroidJUnitTest only).
To support parameterized mainline modules in Test Mapping, we plan to
add a new parameter called test_mainline_modules in build system to
auto-generate the test config based on the parameter.

For detailed information: go/test-mapping-mainline-gcl
(search for auto-generated pattern)

Bug: 155238134
Test: add "test_mainline_modules: [some.apk]" to TetheringTests,
and build the modules, confirm the parameterized option is added
in the test config.

Change-Id: I41ba8749ce46da62db402a8b8a555d4874e1cfc0
Merged-In: I41ba8749ce46da62db402a8b8a555d4874e1cfc0
2020-05-18 09:59:07 +08:00
TreeHugger Robot 53754e3592 Merge "Remove apex_available whitelist for the extservices APEX" into rvc-dev 2020-05-17 15:17:58 +00:00
Paul Duffin dc424ffdf8 Merge "Remove unnecessary copying of common properties" into rvc-dev 2020-05-17 13:04:23 +00:00
Jiyong Park db4ce6e80a Remove apex_available whitelist for the extservices APEX
The marked library(ies) were available to the APEX 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: I827d604c7e5a469a8b8a6d5a4b7917f2eaca48ca
Change-Id: I827d604c7e5a469a8b8a6d5a4b7917f2eaca48ca
2020-05-17 21:23:08 +09:00
Paul Duffin f8e08b20d6 java_sdk_library: Propagate naming_scheme to snapshot
Bug: 155164730
Test: m nothing
Merged-In: Iec7c52d2102b6294540090f3c1e32bd9d8cc7da8
Change-Id: Iec7c52d2102b6294540090f3c1e32bd9d8cc7da8
(cherry picked from commit f7a6433bab)
2020-05-16 18:36:08 +01:00
Paul Duffin d41712d365 Remove unnecessary copying of common properties
The (Soc/Device/Product/System_ext)_specific are all properties in
ModuleBase.commonProperties. Initially, they were explicitly copied
from the parent to the child. Since then the CreateModule() method
was modified to automatically copy all the commonProperties from the
parent to the child so this code is no longer necessary.

Bug: 156618935
Test: m nothing
      checked that it does not change the generated xml permissions
	  file for a java_sdk_library that sets soc_specific: true and
	  is in the vendor partition.
Merged-In: I8c985b50cb6b6c019b33a4652de482ded689fee4
Change-Id: I8c985b50cb6b6c019b33a4652de482ded689fee4
(cherry picked from commit 1dbe3ca254)
2020-05-16 17:55:23 +01:00
Martin Stjernholm 57029c07bf Include runtime-module-sdk in the SDK build.
Test: build/soong/scripts/build-mainline-modules.sh
Bug: 152255951
Merged-In: I39f9024205a198ef8ce19e2c70e3b9dced54add1
Change-Id: I39f9024205a198ef8ce19e2c70e3b9dced54add1
(cherry picked from commit 6ee5f754fe)
2020-05-16 12:14:08 +01:00
Nicolas Geoffray 36469f7121 Add conscrypt-module-host-exports to the list.
// Added for rvc-dev. Used this bug as it is the bug that needs all the build changes.
Bug: 155164730

Test: build-mainline-modules.sh
Merged-In: I9ca14cc37a69b1172f52412297977dd03c6ca1a0
Change-Id: I9ca14cc37a69b1172f52412297977dd03c6ca1a0
(cherry picked from commit 0a2e297206)
2020-05-16 12:14:08 +01:00
Martin Stjernholm f39ef8aa10 Reduce the number of Soong invocations, and various other minor script fixes.
-  We can pass all targets at once to build-aml-prebuilts.sh.
-  Less noise from build-mainline-modules.sh.
-  Default to the same out directory in both build scripts.
-  Addressed post-submit comments on https://r.android.com/1170907.
-  Various minor cleanups.

// Added for rvc-dev. Used this bug as it is the bug that needs all the build changes.
Bug: 155164730

Test: build/soong/scripts/build-mainline-modules.sh
Merged-In: Id21ef80c2334462836e217032fc5bf63b7cd04e1
Change-Id: Id21ef80c2334462836e217032fc5bf63b7cd04e1
(cherry picked from commit 691503ea0b)
2020-05-16 12:14:08 +01:00
Nicolas Geoffray 168ea3d4e1 Use FORCE_BUILD_LLVM_COMPONENTS.
And remove the allow missing dependencies flag.

// Added for rvc-dev. Used this bug as it is the bug that needs all the build changes.
Bug: 155164730

Test: build-mainline-modules.sh
Merged-In: I6ba8892ef66eeb42c7bd3abc989a80ad4b6a1cf9
Change-Id: I6ba8892ef66eeb42c7bd3abc989a80ad4b6a1cf9
(cherry picked from commit 7cad0f860b)
2020-05-16 12:14:08 +01:00
Nicolas Geoffray 7356fffd6d Add linux_bionic cross compilation for mainline SDKs.
ART requires linux bionic prebuilts.

Bug: 142935992
Test: build-mainline-modules.sh
Merged-In: If0f97e58d2afccbc3f5d0b2e7dabac51330cc5c7
Change-Id: If0f97e58d2afccbc3f5d0b2e7dabac51330cc5c7
(cherry picked from commit 71233e4732)
2020-05-16 12:14:08 +01:00
Nicolas Geoffray 164451c1f0 Support secondary arch for host module exports.
Bug: 142935992
Test: build-aml-prebuilts.sh generate x86 prebuilts

Merged-In: Iec4d8aa59a3ad55583c788f8ec40dd0637e7af33
Change-Id: Iec4d8aa59a3ad55583c788f8ec40dd0637e7af33
(cherry picked from commit abdc8c5501)
2020-05-16 12:14:08 +01:00
Nicolas Geoffray 270916d8ff Add a build script to compile modules and SDKs in AOSP.
Test: build-mainline-modules.sh
Bug: 142935992
Merged-In: I80a9bf8ce03d77705ba677f95b03aeb2ac2451d5
Change-Id: I80a9bf8ce03d77705ba677f95b03aeb2ac2451d5
(cherry picked from commit 90bc3cd304)
2020-05-16 12:07:03 +01:00
Martin Stjernholm adb189529a Fix special case when appending a visibility rule to //visibility:private.
Test: m nothing
Bug: 151303681
Merged-In: Ibe7e953219e4660c653063e87cb08407a2cb513d
Change-Id: Ibe7e953219e4660c653063e87cb08407a2cb513d
(cherry picked from commit 64aeaaddef)
2020-05-16 12:07:03 +01:00
Martin Stjernholm f8533bc636 Add explicit visibility on the self package in EffectiveVisibilityRules.
Modules in a package is implicitly visible within the same package.
When making effective visibility rules which work from another location
that visibility needs to be mentioned explicitly. In practice this
allows prebuilts to remain visible to other modules in the source
package when the prebuilts are preferred.

Test: m nothing
Test: m conscrypt-module-sdk, check that the snapshot Soong modules give
  visibility to //external/conscrypt
Bug: 151303681
Merged-In: I404f6e5ca7021974a8c7be5e4d6b4982c050b8a5
Change-Id: I404f6e5ca7021974a8c7be5e4d6b4982c050b8a5
(cherry picked from commit 0641d189d0)
2020-05-16 12:07:03 +01:00
Martin Stjernholm 68e9d96d61 Don't print :__pkg__ for package rules, since that's the default.
To reduce clutter a little.

// Added for rvc-dev. Used this bug as it is the bug that needs all the build changes.
Bug: 155164730

Test: m nothing
Merged-In: I0d2d86f00c3d38e603d6f58c4b1dd9a4170bf819
Change-Id: I0d2d86f00c3d38e603d6f58c4b1dd9a4170bf819
(cherry picked from commit 01407c525a)
2020-05-16 12:06:54 +01:00
Anton Hansson 18a289560d Fix API lint copy command
The space after the backtick prevents it working when copy-pasting it
into the shell.

Test: create lint error => m => cp/pasted command runs successfully
Merged-In: I42b8b60d01dcaed34dbde0390eb1691d656a32cf
Change-Id: I42b8b60d01dcaed34dbde0390eb1691d656a32cf
(cherry picked from commit 3361a294c0)

// Added for rvc-dev. Used this bug as it is the bug that needs all the build changes.
Bug: 155164730
Change-Id: I42b8b60d01dcaed34dbde0390eb1691d656a32cf
2020-05-16 11:03:46 +00:00
Paul Duffin c91aafb699 Merge "Replace javaLibrary with java.Dependency,android.Module" into rvc-dev 2020-05-16 07:24:18 +00:00
TreeHugger Robot ff91b3c29a Merge "Add apex_set module." into rvc-dev 2020-05-16 02:37:39 +00:00
Jaewoong Jung 8cf307e754 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
Merged-In: I1da8bbcf1611b7c580a0cb225856cbd7029cc0a7
2020-05-16 00:37:36 +00:00
TreeHugger Robot a91a16b484 Merge "Use system modules for prebuilt SDKs >=30" into rvc-dev 2020-05-15 23:47:29 +00:00
TreeHugger Robot 3fcdb81cf2 Merge "Don't use SDK variant for vendor JNI libraries" into rvc-dev 2020-05-15 23:45:36 +00:00
Sasha Smundak 4de27a5757 Implement android_app_set module
Bug: 152319766
Test: manual and builtin
Change-Id: Id0877476f9ae23311d92c0b59a9c568140ab4119
Merged-In: Id0877476f9ae23311d92c0b59a9c568140ab4119
2020-05-15 10:49:59 -07:00
Sasha Smundak bbf0579ac7 Implement extract_apks
Bug: 152319766
Test: manual and builtin
Change-Id: Ia15d66e86c7bcfd52f5b776173ca1665b68ff438
Merged-In: Ia15d66e86c7bcfd52f5b776173ca1665b68ff438
2020-05-15 10:49:45 -07:00
Colin Cross eb03296b57 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
Merged-In: I21ba67e8e9fb05016caf5888129adc1a939545c2
(cherry picked from commit c2d24050c5)
2020-05-15 10:13:42 -07:00
Paul Duffin f299cbefcd Replace javaLibrary with java.Dependency,android.Module
Passes an additional android.Module parameter through to avoid having
to use javaLibrary interface.

Bug: 146586360
Test: m nothing
Merged-In: Ie533c16c753dc9c43171d0223953adea7b2b5ee6
Change-Id: Ie533c16c753dc9c43171d0223953adea7b2b5ee6
(cherry picked from commit 581bbbe8cb)
2020-05-15 17:07:02 +01:00
Colin Cross db22475ecb Use system modules for prebuilt SDKs >=30
Prebuilt SDKs >=30 now contain core-for-system-modules.jar,
convert them to system modules and use them when compiling against
the SDK to allow using javac -source 1.9 -target 1.9.

Bug: 117069453
Test: TestClasspath
Change-Id: Iebadad5980b952ed91c3ffd56cff1ce1827d3247
2020-05-14 19:51:31 -07:00
Kousik Kumar 459c6b25e5 Add implicit outputs to link actions
Bug: b/154733231

Change-Id: I9b6ae97f5bbfe8f9c4b9c089544a768982794f32
Merged-In: I9b6ae97f5bbfe8f9c4b9c089544a768982794f32
Test: Built the failing action with / without this change
2020-05-14 17:33:35 +00:00
Paul Duffin 0f27063a9e Correct module_lib scope name
The module_lib scope should be called module-lib in order to pick up
the latest filegroup. Without it the API lint does not use a baseline
and so reports issues with released and unchangeable APIs.

It is also needed for the correct dist path.

Test: m update-api
Bug: 155164730
Merged-In: I7dbafd7164d5da600ca45c39a7f93a5a40027a1f
Change-Id: I7dbafd7164d5da600ca45c39a7f93a5a40027a1f
(cherry picked from commit 6b836ba566)
2020-05-14 12:16:16 +01:00
Paul Duffin dd89a28104 java_sdk_library_import: Propagate prefer to child modules
Bug: 155164730
Test: m nothing
Merged-In: Idb06d79baf346ac570beada79880814c5ef6bb50
Change-Id: Idb06d79baf346ac570beada79880814c5ef6bb50
(cherry picked from commit 38b5785e3f)
2020-05-13 23:39:01 +01:00
TreeHugger Robot fa891cb178 Merge "Use StopServicesSetup to stop/start framework." into rvc-dev 2020-05-13 21:13:50 +00:00
Dan Shi 30ed3d4ce9 Use StopServicesSetup to stop/start framework.
Bug: 155774142
Test: atest VtsHalWifiV1_2TargetTest (update Android.bp with
disable_framework: true)

Change-Id: I5d5326f415352d50ace7f456d29b257d1d769318
Merged-In: I5d5326f415352d50ace7f456d29b257d1d769318
2020-05-13 17:27:56 +00:00
Paul Duffin 080f5ee6f2 java_sdk_library: Add sdk_version for API scopes
Allow the sdk_version against which the stubs for a scope are compiled
to be specified in the module on a per scope basis.

Bug: 155164730
Test: m nothing
Merged-In: I5881e5ee7c2169c30f544882344a60a602dae917
Change-Id: I5881e5ee7c2169c30f544882344a60a602dae917
(cherry picked from commit 87a05a389d)
2020-05-13 18:07:09 +01:00
Paul Duffin 1f4ad0e44d Remove unused Module.visibility() method
Bug: 155787200
Test: m nothing
Merged-In: Iee7a9ab9d816ed1948e2c7cde23f9907cfda337d
Change-Id: Iee7a9ab9d816ed1948e2c7cde23f9907cfda337d
(cherry picked from commit 36c5b8d0b8)
2020-05-13 13:50:34 +01:00