Commit Graph

47976 Commits

Author SHA1 Message Date
Treehugger Robot 8faac3669e Merge "Add security patch level to hashtree footer of system" 2019-01-24 19:28:29 +00:00
Paul Duffin 22efcc114e Merge "Remove REMOVE_OAHL_FROM_BCP flag" 2019-01-24 16:01:40 +00:00
Nicolas Geoffray 9f5ed17225 Merge "Differentiate between runtime apex jars and framework jars." 2019-01-24 14:38:17 +00:00
Nicolas Geoffray 6bcc93983b Differentiate between runtime apex jars and framework jars.
And use the apex paths of runtime apex jars.

Test: m
Change-Id: I7bd6e6029c2d5d596d672545271b5ed9819090b6
2019-01-24 13:10:22 +00:00
Calin Juravle ba3e26d5da Merge "Replace PRODUCT_BOOT_JARS with DEXPREOPT_BOOT_JARS_MODULES for nopreloads" 2019-01-24 07:56:37 +00:00
Suren Baghdasaryan 5fe50948da Merge "DO NOT MERGE: Revert "Add libprocessgroup into VNDK"" 2019-01-24 06:57:55 +00:00
Treehugger Robot b045705971 Merge "Build System: Add java lib header files to module dependency list im module-info.mk" 2019-01-24 06:50:33 +00:00
Nicolas Geoffray 3d54ce08fe Merge "Pass the right dex files to dex preopt." 2019-01-24 06:37:40 +00:00
Treehugger Robot d2da2ce398 Merge "Sign system_other.img with AVB" 2019-01-24 05:31:37 +00:00
Suren Baghdasaryan fec192e98f DO NOT MERGE: Revert "Add libprocessgroup into VNDK"
This reverts commit 1877db4591.

Reason for revert: Broke AOSP

Change-Id: I4f4b8bae60966f1459365387bbde5a1f60c7b727
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
2019-01-23 20:52:04 -08:00
Calin Juravle b741d1cfa9 Replace PRODUCT_BOOT_JARS with DEXPREOPT_BOOT_JARS_MODULES for nopreloads
boot_profile_jars.zip is used to process the boot image profile (by
filtering out data that does not belong to the boot classpath).
We only need the jars that are actually preloaded, and not the ones which
are updatable.

Test: launch taimen_nopreload-userdebug; m
Bug: 123313750
Change-Id: I630f78dda3d9b38aac04b0f364b25fbcda4e26a3
2019-01-23 18:06:50 -08:00
bralee 090336232e Build System: Add java lib header files to module dependency list im module-info.mk
To solve AIDEGen issue: DocumentsUI have no dependency libcore.

Bug: 122557164
Test: 1. m  `build/soong/soong_ui.bash --dumpvar-mode PRODUCT_OUT`/module-info.json
      2. open $ANDROID_PRODUCT_OUT/module-info.json
         "out/target/common/obj/JAVA_LIBRARIES/core-lambda-stubs_intermediates/classes-header.jar",
         "out/target/common/obj/JAVA_LIBRARIES/core.platform.api.stubs_intermediates/classes-header.jar",
	 "out/target/common/obj/JAVA_LIBRARIES/ext_intermediates/classes-header.jar",
	 "out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-header.jar"
	 will be added to DocumentsUI's dependencies.

Change-Id: I6b20c315f3367ff2a016d305ec6fe2a8de620a14
2019-01-24 09:27:48 +08:00
Yifan Hong 2c0a7bc56d Merge "Really support removing / adding partitions." 2019-01-24 00:51:32 +00:00
Treehugger Robot 2463c3ab2a Merge "Support including DTB image" 2019-01-23 20:56:55 +00:00
Hridya Valsaraju 9683b2f136 Support including DTB image
Bug: 111136242
Test: When BOARD_PREBUILT_DTB_DIR is set correctly,
generated $OUT/boot.img contains the DTB image.

Change-Id: I282e31b04cc60383377b9e9b54f8fe64a8140242
2019-01-23 09:14:55 -08:00
Nicolas Geoffray f084e7847e Pass the right dex files to dex preopt.
We currently pass the boot dex files installed on /system, but these
may be eg stripped. That's currently OK as dex2oat is looking
at the dex files in boot.oat, but dex2oat could look at them for
various reasons.

Test: m
Change-Id: I85915c979cf94ec29751b10a0d8a5957b6cea956
2019-01-23 16:07:02 +00:00
Bowgo Tsai 1e04bf7260 Sign system_other.img with AVB
Support signing system_other.img but shouldn't include it into the
top-level vbmeta.img. system_other verifiation will not be included
in /vbmeta chains and will be done separately.

Bug: 112103720
Test: avbtool info_image --image $OUT/system_other.img
Test: avbtool info_image --image $OUT/vbmeta.img, checks 'system_other' is NOT included.
Test: Checks $OUT/obj/PACKAGING/system_other_intermediates/system_other_image_info.txt
      See the following:
        avb_system_other_hashtree_enable=true
        avb_system_other_add_hashtree_footer_args=--rollback_index 1551744000
        avb_system_other_key_path=external/avb/test/data/testkey_rsa4096.pem
        avb_system_other_algorithm=SHA256_RSA4096

Change-Id: Ia152aaab1387dcf556a42222adb39ea76881263a
2019-01-23 15:17:41 +00:00
Anton Hansson 2ec9fcd951 Merge "Move ModuleMetadata to base_product" 2019-01-23 11:17:43 +00:00
Anton Hansson 767569b489 Merge "Enable 64-bit mediadrmserver for mainline" 2019-01-23 09:56:46 +00:00
Logan Chien 9779c57cd0 Merge "Add $(SOONG_OUT_DIR)/ndk/% to artifact whitelist" 2019-01-23 07:22:43 +00:00
Logan Chien f42823aa7c Merge "Add prebuilt ELF binaries checker" 2019-01-23 07:21:17 +00:00
Nicolas Geoffray ac8d67573e Merge "Use the jars, not the classes.dex for passing to hiddenapi." 2019-01-23 06:37:06 +00:00
Suren Baghdasaryan 6f62f79db9 Merge "Add libprocessgroup into VNDK" 2019-01-22 20:58:16 +00:00
Suren Baghdasaryan 1877db4591 Add libprocessgroup into VNDK
Include libprocessgroup into vndk because libprocessgroup now implements
sched_policy control functions.

Bug: 111307099
Test: builds, boots
Merged-In: If18227e8a824a1e606df78dfe01d9d2437c62792
Change-Id: If18227e8a824a1e606df78dfe01d9d2437c62792
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
2019-01-22 18:16:56 +00:00
Anton Hansson f2d90e9143 Move ModuleMetadata to base_product
The app is moving from /system to /product.

Bug: 122353713
Test: make
Change-Id: I0987b46013527503eedf75350bc30b303722552b
2019-01-22 18:07:03 +00:00
Nicolas Geoffray e5b368bfe6 Use the jars, not the classes.dex for passing to hiddenapi.
The instructions to look up for classes.dex don't work when looking
at different jar versions (aligned, unaligned, etc).

Test: m
Change-Id: I5f178ca0d00497edbab892722a5ee84f0c47d0a0
2019-01-22 14:28:12 +00:00
Paul Duffin fd24c9fe1f Remove REMOVE_OAHL_FROM_BCP flag
The REMOVE_OAHL_FROM_BCP flag is always set to true and is no longer
necessary so this change removes any uses of the flag.

Bug: 18027885
Test: cts/tests/signature/runSignatureTest.sh
Change-Id: Ied8c3315b29094ad6acee539520af3e4c9e79839
2019-01-22 14:16:12 +00:00
Hsin-Yi Chen 41319b3abc Add security patch level to hashtree footer of system
Test: avbtool info_image --image system.img
Bug: 122705329
Change-Id: I7b325a9a9aba2d98cb94c5fb8488b92f54e45dab
2019-01-22 17:11:15 +08:00
Treehugger Robot e8f1a420bc Merge "Don't depend on classes-header.jar when turbine is disabled" 2019-01-21 21:55:14 +00:00
Colin Cross b405fe3765 Don't depend on classes-header.jar when turbine is disabled
TARGET_BUILD_APPS sets TURBINE_ENABLED := false, which triggers
an issue where a dependency is added on classes-header.jar but
there is no rule to create it.  Skip creating the dependency
when TURBINE_ENABLED is false for now.

Bug: 123183568
Test: m TARGET_PRODUCT=mainline_modules_arm UNBUNDLED_BUILD_SDKS_FROM_SOURCE=true TARGET_BUILD_APPS=com.android.media
Change-Id: I8ec3e244b8f9618c58f4ac57329a5a07f01dc797
2019-01-21 10:59:42 -08:00
Logan Chien 86eeedbcc7 Add $(SOONG_OUT_DIR)/ndk/% to artifact whitelist
This commit adds `$(SOONG_OUT_DIR)/ndk/%` to artifact whitelist so that
when NDK stub libraries won't be blocked by artifact path requirements.

This commit does not break the integrity of artifact path requirements
because they are not installed to devices.

Bug: 123053270
Bug: 119084334
Test: lunch aosp_crosshatch-userdebug
Change-Id: Ieea76a8126269f53b0a58bd069b449a9f9b1263a
2019-01-21 14:34:19 +00:00
David Brazdil 4ac7810755 Merge changes from topics "coreapi-flag", "coreapi-stubs-csv"
* changes:
  hiddenapi: Process core.platform.api.stubs
  Replace hiddenapi-{public,private}-list.txt with a CSV file
2019-01-21 14:31:05 +00:00
Logan Chien 0e53d887d6 Add prebuilt ELF binaries checker
This commit introduces a prebuilt ELF binaries checker.  The checker
will check:

1. Whether all DT_NEEDED shared libraries are specified in
   `shared_libs` (Android.bp) or `LOCAL_SHARED_LIBRARIES` (Android.mk).

2. Whether all undefined symbols in the prebuilt binary can be resolved
   to defined symbols exported by its dependencies.

This ensures that prebuilt binaries won't silently become ABI
incompatible.

To check the prebuilt binaries, all of the dependencies must be
specified in `shared_libs` (Android.bp) or `LOCAL_SHARED_LIBRARIES`
(Android.mk).

If your prebuilt binaries cannot be checked for some reason, you may add
the following property to Android.bp:

    check_elf_files: false,

Or, add the following setting to Android.mk:

    LOCAL_CHECK_ELF_FILES := false

Bug: 119084334
Test: CHECK_ELF_FILES=true make check-elf-files
Change-Id: I523d3083f22fd4053c096d26f61f8375800281c8
2019-01-21 21:35:01 +08:00
David Brazdil 96e973b304 hiddenapi: Process core.platform.api.stubs
Pass @CorePlatformApi stubs to the `hiddenapi` singleton rule which
generate a CSV of all public or domain API flags.

Bug: 119068555
Test: m appcompat
Test: dexlayout <core-oj jar> | grep CORE-PLATFORM-API
Change-Id: I597ee330835e564d61cfac44497e762b552b901c
2019-01-19 15:57:35 +00:00
David Brazdil fc274bab4d Replace hiddenapi-{public,private}-list.txt with a CSV file
`hiddenapi` is being refactored to work with a single CSV file as
opposued to a multitude of text files (one per flag). This patch
changes the singleton rule for listing public/private APIs from
stubs to expect a CSV as an output.

Bug: 119068555
Test: compiles, hiddenapi-flags.csv unchanged
Change-Id: If56c7ab8a4c3bbd33e447ef0dfd33f2c303a937c
2019-01-19 15:57:35 +00:00
Dan Willemsen 241d7cdba0 Merge "Add previously debug-tagged modules" 2019-01-19 07:39:56 +00:00
Treehugger Robot 082fd2c5bc Merge "Move UPDATABLE_BOOT_(MODULES|JARS) to base_system.mk for further extension" 2019-01-19 04:37:13 +00:00
Colin Cross 3087d93cc6 Merge "Build docs zips with make docs" 2019-01-19 04:09:20 +00:00
Treehugger Robot 6bd6318880 Merge "Define non-system module as variable" 2019-01-19 01:48:39 +00:00
Evgenii Stepanov ffaf4815fc Merge "Limit 2 uses of SANITIZE_TARGET to ASan." 2019-01-19 01:32:51 +00:00
Yifan Hong 45433e44dd Really support removing / adding partitions.
- When removing a partition, BlockDifference() object
will have tgt=EmptyImage(). Fix the asserts accordingly.
Also, BlockDifference object now allow tgt=None case.

- When adding a partition, BlockDifference() object
will have src=None. Fix the asserts accordingly.

Also, add unit tests to DynamicPartitionsDifference.

Test: create incremental OTA
Test: test_common.DynamicPartitionsDifferenceTest
Bug: 111801737

Change-Id: I3a35378ecf93111b8f44545cff6ae9696b6b4851
2019-01-18 17:09:33 -08:00
Dongwon Kang 167758a153 Move UPDATABLE_BOOT_(MODULES|JARS) to base_system.mk for further extension
Test: build & boot
Bug: 112766913

Change-Id: I5af02d44c4b4163acdc4e3078dcebd84556ee049
2019-01-18 17:06:18 -08:00
Treehugger Robot 215e2c828c Merge changes I685ab841,I6ab7e488
* changes:
  Add PRODUCT_BUILD_*_IMAGE, BUILDING_*_IMAGE to control building of images
  Always package ext filesystem tools
2019-01-19 00:18:02 +00:00
Colin Cross 103d6e8856 Build docs zips with make docs
The docs zips were being built for make docs dist but not for
make docs.  Add them to ALL_DOCS and to the $(LOCAL_MODULE)
phony rule.

Bug: 123068677
Test: m docs
Test: m ds-docs
Change-Id: I32634c05e392f7a5483c81d59de35ca9bc4d4ad0
2019-01-18 16:08:14 -08:00
Dan Willemsen ec6cc8521d Add previously debug-tagged modules
These all had `LOCAL_MODULE_TAGS := debug`

Test: treehugger
Change-Id: I848d1d9fb7e9921827ef6b5b72376710150ce839
2019-01-18 15:51:41 -08:00
Treehugger Robot 5f93c3a929 Merge "Add PROGUARD_HOME and PROGUARD_DEPS" 2019-01-18 22:18:50 +00:00
Treehugger Robot 12e7e928a2 Merge "Move HIDDENAPI_FLAGS dependencies to frameworks/base" 2019-01-18 22:13:53 +00:00
Evgenii Stepanov 60beecc90c Limit 2 uses of SANITIZE_TARGET to ASan.
These two places are checking for ifdef(SANITIZE_TARGET) but what
they are really looking for is the second stage of ASan build.

Fix the checks so that they do not apply to HWASan.

I have not seen any change in behavior, but there are some new files
under /system in hwasan build that were not there before, and things
keep working in general, so this feels like the right move.

Bug: 112438058
Test: none; SANITIZE_TARGET=hwaddress keeps working
Change-Id: I4544f408263b908be6ef4a47dd2b5c937e0c1f33
2019-01-18 14:06:11 -08:00
Dan Willemsen 674952098b Add PRODUCT_BUILD_*_IMAGE, BUILDING_*_IMAGE to control building of images
These centralize the decisions on whether to build certain images or
not, and allow the product definition to override that choice.

There are a few use cases here:

 * For GSI-like cases, we only want to build the system image. This
   didn't really change, but it's somewhat simpler to configure, and
   easier to understand the build logic.

 * On the opposite side, when you're planning on using a GSI, the device
   specific build can only build the vendor images (or some other set).

 * Some cases (Fuchsia, etc) don't want to build any images, as they'll
   be distributing the build artifacts in their own packaging.

I suspect in the future, TARGET_BUILD_APPS may be able to be refactored
into the third use case.

Test: treehugger
Test: Create a product definition that includes nothing, try to build it.
Test: compare build-aosp_crosshatch.ninja and build-crosshatch.ninja before/after
Change-Id: I685ab841be3718d3dd7052c28ccd764bb6f1991a
2019-01-18 13:11:34 -08:00
Dan Willemsen df0808331d Always package ext filesystem tools
Every target we have needs these now.

Test: treehugger; codesearch
Change-Id: I6ab7e48887b19f956b2a7aeac78169f0e2035c73
2019-01-18 10:44:34 -08:00