Commit Graph

46041 Commits

Author SHA1 Message Date
Søren Gjesse 6601397608 Merge "Ensure that the R8 minification map (ProGuard dictionary) file exists" 2018-08-27 16:06:07 +00:00
Søren Gjesse b22934382f Ensure that the R8 minification map (ProGuard dictionary) file exists
R8 no longer outputs an empty map file when minification
(obfuscation) is turned off.

Test: m -j PRODUCT-aosp_x86-eng
Change-Id: I3bd3f2900225dca05a972f46a3b882041e17ba49
2018-08-27 11:19:35 +02:00
Tao Bao 687da3b0a5 releasetools: Fix the path to the OTA keys in recovery image.
The recovery image will be packed under BOOT/RAMDISK only if
system_root_image and recovery_as_boot both are true (e.g. non-A/B
devices launched since P).

Bug: 113191245
Test: Run sign_target_files_apks.py on a target_files file that uses
      system-as-root but not recovery-as-boot.
Change-Id: I262a268055c6b5078d21694b5094a1c393d0d37c
2018-08-26 14:39:58 -07:00
Yifan Hong c247436e2f Merge changes from topic "resizable_ota"
* changes:
  Add _b to super.
  Create build-superimage-target.
2018-08-24 23:03:22 +00:00
Tao Bao 22f28aa1b5 Merge "A/B update: Replace the zip FileHeader mechanism for update package" 2018-08-24 19:54:10 +00:00
Anton Hansson 6861c9f98d Merge "Install /system/product_services apps odex in system-other." 2018-08-24 18:03:10 +00:00
Treehugger Robot 2f2b5bb224 Merge "Add the missing rule for including product_services.img into vbmeta.img." 2018-08-24 16:51:23 +00:00
Narayan Kamath e4f41463fd Provisionally increase PLATFORM_MIN_SUPPORTED_TARGET_SDK_VERSION to 23.
Bug: 112828438
Test: m
Change-Id: Id66e19cab1248ce7c89a39e3bd21b7e0dae8c4e7
2018-08-24 16:08:41 +01:00
Narayan Kamath e7d93422d1 Fix misleading comment in version_defaults.mk
Test: m
Bug: 111003817
Change-Id: Iaf185a2cce0c53b0c3dc52bce2d03ea6df0ca681
2018-08-24 15:17:33 +01:00
Anton Hansson 648b0a875e Install /system/product_services apps odex in system-other.
This will cause odex/vdex files for apps installed under
/system/product_services/{priv-,}app to be installed in system-other
instead of next to the APKs themselves.

This change is analogous to I63406f91acc3de4b4f142767e28d45308706c7da,
which was for /system/product apps.

Test: diff installed-files{,-system-other}.txt on pixel with a PS app
Bug: 80741439
Change-Id: I79fac41cb665a649028f1f0e30350d42e8b80598
2018-08-24 14:59:32 +01:00
Treehugger Robot 916f710b96 Merge "Correct PRODUCT_SERVICES_COPY_FILES in envsetup.mk" 2018-08-24 08:41:00 +00:00
Tao Bao 0da4347827 Clean up the rules for making vbmeta.img.
This CL intends to be a no-op change to functionality. It prepares for
the upcoming changes that support creating chained VBMeta images.

Bug: 112007947
Test: `m dist` with aosp_taimen-userdebug
Change-Id: Iaac45bde7971b056e17a6e7b0c89336ed206916e
2018-08-23 22:21:13 -07:00
Tao Bao cee6d0456d Add the missing rule for including product_services.img into vbmeta.img.
Bug: 80741439
Test: `m -j vbmetaimage` for a target that uses product_services image
      (i.e. `BOARD_PRODUCT_SERVICESIMAGE_FILE_SYSTEM_TYPE := ext4`).
      Verify that the generated `vbmeta.img` includes the descriptor for
      `product_services.img`.
Change-Id: Ia2d64523319c3313803acbc63dd56154a0426334
2018-08-23 22:14:28 -07:00
Treehugger Robot be4ad83ef3 Merge "Atest: add LOCAL_TEST_CONFIG to module_info.json" 2018-08-24 02:49:52 +00:00
yangbill c9347b3167 Atest: add LOCAL_TEST_CONFIG to module_info.json
Bug: 112335032

Test: 1. Add LOCAL_TEST_CONFIG := ahat-tests.xml in
         art/tools/ahat/Android.mk for ahat-tests
      2. add ahat-tests.xml in local
      3. atest -m hello_world_test
      4. check module_info.json
         local_full_test_config": ["art/tools/ahat/ahat-tests.xml"]

Change-Id: Ice2a0c85979fa6b872c92aea5ff4a340342408ad
2018-08-24 09:29:11 +08:00
Chih-hung Hsieh 8668e9228a Merge "Define CLANG_TIDY_UNKNOWN_CFLAGS in tidy.mk" 2018-08-23 22:23:59 +00:00
Yifan Hong ebba784d0a Add _b to super.
During OTA, update_engine expects both slots in super,
so that it doesn't have to create the missing slot. Thus,
UUIDs of all logical partitions are consistent. Values
are the result of `uuidgen.py {name}_{slot}` for A/B and
`uuidgen.py {name}` for non-A/B).

Test: adb shell lpdump /dev/block/by-name/super
Bug: 110717529
Change-Id: Ibb90d4dbe1a56bf314d4a02d7aa2f2be18d04855
2018-08-23 09:38:00 -07:00
David Brazdil b67402ecce Support hidden API whitelist generated by class2greylist
Libcore has support for annotating a virtual method which is known
to change its return type in a future release. This annotation is
recognized by the dexer and a future-proof bridge method is created.
This patch integrates changes in class2greylist to support this
annotation into the build system and generation of hidden API lists.

Calling class2greylist on each boot classpath module now produces two
text files instead of one: signatures for greylisting and now also
whitelisting. They are passed on to the hidden API list generating rules
in frameworks/base.

Bug: 112186571
Test: m appcompat, diff public-list.txt whitelist.txt
Change-Id: I9861203e6e07a17d50850892ec13880971457d11
2018-08-23 10:38:03 +01:00
Bowgo Tsai d241226936 Correct PRODUCT_SERVICES_COPY_FILES in envsetup.mk
Bug: 80741439
Test: build
Change-Id: Ibc37a1c011ad00a4763911ca0842c74f31d8bc0d
2018-08-23 15:54:34 +08:00
Tao Bao ebe17177fe Merge "releasetools: Look for recovery.fstab at both locations." 2018-08-23 06:05:40 +00:00
Tao Bao b4adc06732 releasetools: Look for recovery.fstab at both locations.
The change in [1] moved the recovery etc files from /etc to /system/etc.
However, we may use the latest OTA tools to build incremental OTAs for
old target_files zips. This CL adds a workaround to look at both of the
old and new locations.

[1] commit 696bb33676

Bug: 113073663
Test: Build a previously failing incremental OTA for taimen.
Change-Id: Ie07aa1713e616d523838b1260a992b20f5a11612
2018-08-22 18:41:49 -07:00
Shashikant Baviskar 338856f92b A/B update: Replace the zip FileHeader mechanism for update package
When the update package gets larger than 2 GiB, payload.bin offset
mentioned in metadata file for ota-streaming-property-files gets
shifted (CrAU of payload.bin) because ZipInfo FileHeader() returns
incorrect value. To solve the issue, offset is re-calculated from
fixed bytes of central directory file header, filename length and
extra length.

This patch is to sync with update_device.py script.

Test: manually create an A/B update package and run it using
      update_device.py
Bug: 111198589

Change-Id: I9bf5a5ca24938cad3206d04af529f70d45e992c0
2018-08-23 10:13:20 +09:00
Tao Bao da9f2d8fd4 Merge changes Icf44032f,Iec8524d3
* changes:
  Add the missing dependency on BOARD_PREBUILT_DTBOIMAGE.
  use BOARD_PREBUILT_DTBOIMAGE in target-files-package
2018-08-22 23:56:55 +00:00
Yifan Hong 251a02f2f0 Create build-superimage-target.
Combine INSTALLED_SUPERIMAGE_TARGET with INSTALLED_SUPERIMAGE_EMPTY_TARGET.

Also fixes inconsistent UUIDs for super_empty.img
because PRIVATE_SUPER_PARTITION_SUFFIX is not defined.

Test: flash and inspect device mapper
Change-Id: I7f00c4e21ebdd21e94fa387c6e2fbea06a6e75b7
2018-08-22 16:43:57 -07:00
Tao Bao f4866c72ca Add the missing dependency on BOARD_PREBUILT_DTBOIMAGE.
Test: Use a target that defines `BOARD_INCLUDE_RECOVERY_DTBO := true`
      and BOARD_PREBUILT_DTBOIMAGE. Touching a prebuilt dtbo file
      triggers rebuilding of recovery image.
Change-Id: Icf44032fb29542c6836a401c79fb85345ad6cc3c
2018-08-22 14:40:45 -07:00
cfig 286874053c use BOARD_PREBUILT_DTBOIMAGE in target-files-package
it's better to use the original $(BOARD_PREBUILT_DTBOIMAGE) instead
of AVB-padded $(INSTALLED_DTBOIMAGE_TARGET), the latter will be padded
to the size of /dtbo partition

Test: `make target-files-package` target file RECOVERY/recovery_dtbo is
    the original BOARD_PREBUILT_DTBOIMAGE
Test: `make otapackage` build pass and OTA file works fine

Change-Id: Iec8524d3a0544ddca89481dc613f076b36aeed25
2018-08-22 14:34:55 -07:00
Treehugger Robot 10f1a69a2b Merge "Build image for clean super partition." 2018-08-22 20:06:14 +00:00
Anton Hansson 82182c8233 Merge "Add OTA support to mainline_system." 2018-08-22 18:41:30 +00:00
David Anderson 433f822d76 Build image for clean super partition.
This adds a new super_empty.img output to the build when
PRODUCT_USE_LOGICAL_PARTITIONS is true and a super partition size is
set. This will be used by fastboot flashall in fastbootd, since it needs
a record of the partition layout in case the super partition is corrupt
or not yet flashed.

Unlike the full super.img, super_empty.img is not a sparse image. It
contains the minimal data sequence needed to format the super partition.
It also does not contain partition sizes, since flashing is responsible
for choosing the correct partition size.

The full super.img (which contains embedded partition data) is still
available via "make dist".

Bug: 78793464
Test: super_empty.img generated when PRODUCT_USE_LOGICAL_PARTITIONS is
      true.
      mmm system/extras/partition_tools && lpdump super_empty.img works

Change-Id: I34e915a1fead806287dde554d190474785e52500
2018-08-22 11:40:22 -07:00
Anton Hansson 0de30815ff Merge "Fix dump-products." 2018-08-22 16:58:13 +00:00
Anton Hansson ae6bf49575 Merge "Make FULL_BUILD not set for the dont_bother case." 2018-08-22 16:57:48 +00:00
Treehugger Robot 7a9f3889f0 Merge "Rename INSTALLED_SYSTEMIMAGE to INSTALLED_SYSTEMIMAGE_TARGET." 2018-08-22 16:49:23 +00:00
Anton Hansson 33611b1173 Add OTA support to mainline_system.
update_engine applies an OTA, and update_verifier verifies
partitions post boot.

Note that this also adds cacerts_google as it's a required module by
update_engine, so this reduces the disparity between pixel /system
and mainline_system /system by ~100 files.

Bug: 110410711
Bug: 111495787
Test: make
Change-Id: Idd31407bbd5543fe1dd2b52e87894ac501a025df
2018-08-22 17:48:52 +01:00
Chih-Hung Hsieh 4275dcf866 Define CLANG_TIDY_UNKNOWN_CFLAGS in tidy.mk
* Moved from build/soong because the list is used only in make rules.

Bug: 111885396
Test: build with WITH_TIDY=1
Change-Id: I6ca7420e7ed1e342a5b92996724c6659a406d5ae
2018-08-22 09:21:53 -07:00
Anton Hansson 9b8e6cf067 Fix dump-products.
m dump-products didn't print anything useful prior to this change,
however this was visible in the terminal:
15:18:58 Error dumping make vars: Failed to parse make line: "==== build/target/product/aosp_arm.mk ===="

Convert this goal to normal target instead, which apart from making
$(info) actually print something, considers the build successful
when running "m dump-products" too. This makes it easier to run with
e.g. multiproduct_kati.

Test: m dump-products
Change-Id: I944c87cd0fd323687690b0fcc3c37a8f37242cd9
2018-08-22 10:49:18 +01:00
Anton Hansson 85d8ce044f Make FULL_BUILD not set for the dont_bother case.
If dont_bother is set, we're not going to read all the module makefiles,
so the checks gated behind FULL_BUILD will fail.

Test: lunch mainline_system_arm64; m vnod
Change-Id: Ic7842f772edd6b6a6fdc427d018ea1dfe3cbfdbf
2018-08-22 10:49:03 +01:00
Tao Bao e9d61b02e8 Rename INSTALLED_SYSTEMIMAGE to INSTALLED_SYSTEMIMAGE_TARGET.
This gives a consistent mapping between partition names and the image
targets (i.e. partition => INSTALLED_PARTITIONIMAGE_TARGET). This CL
also creates an alias for the old name so that device-specific Makefiles
that refer to INSTALLED_SYSTEMIMAGE would keep working.

This CL renames image-for-partitions to images-for-partitions, and
returns INSTALLED_SYSTEMIMAGE_TARGET for system. It doesn't change the
actual functionality, but allows substantially simplifying the rule.

Test: `m dist` with aosp_taimen-userdebug
Test: `m dist` with a target that uses super partition
Change-Id: I2954ee5d855c1652a33c640ee615649588d5bc04
2018-08-21 21:57:21 -07:00
Treehugger Robot 8e639205d7 Merge changes from topic "from-pi-gsi"
* changes:
  Fix unbundled branch by not having it pick up goldfish dependency
  Add emulator audio policy config in /vendor not /system
  emulator: factor vendor partition out of emulator.mk
2018-08-22 04:14:25 +00:00
Tao Bao c901630789 Merge "Install recovery etc files to recovery/root/system/etc." 2018-08-21 22:35:49 +00:00
Tao Bao 696bb33676 Install recovery etc files to recovery/root/system/etc.
They used to be installed under recovery/root/etc. This CL moves the
files to the new location and creates a symlink from /etc to /system/etc
(done by the rule in system/core/rootdir). This gives similar layout
between normal boot and recovery, and allows installing prebuilt_etc
files with Soong (`recovery_available: true`).

As part of the change, we no longer need the whitelisting rule for
mke2fs.conf.

Bug: 112780007
Test: Build with other changes in the topic (aosp_taimen-userdebug).
      Check the generated files under recovery (/etc being a symlink to
      /system/etc).
Test: Boot into recovery. Verify basic functionalities (`adb shell` and
      `adb sideload`, factory reset).
Test: `build/soong/build_test.bash --dist`
Change-Id: Ibb6dea6f179a339f0c2d0fd8ba05ec0085b79a12
2018-08-21 10:30:49 -07:00
Tao Bao e56d112bd0 Merge "Add the Cleanspec rule for product-services symlink." 2018-08-21 15:57:40 +00:00
Tao Bao d6b3a4cc79 Add the Cleanspec rule for product-services symlink.
Bug: 112431447
Test: `m dist` when there's a leftover symlink of "/product-services".
Change-Id: I39bb79bd7790fe2243075768c6423b0fddc379f7
2018-08-21 07:34:18 -07:00
Hyunyoung Song 3aa57d8d90 Fix unbundled branch by not having it pick up goldfish dependency
Bug: 110165361

Change-Id: I0824b140fdfee296288c03fd03a3bac7966e9179
Merged-In: I0824b140fdfee296288c03fd03a3bac7966e9179
(cherry picked from commit 16e7004e3f)
2018-08-21 06:55:33 +00:00
Kevin Rocard b4150586c5 Add emulator audio policy config in /vendor not /system
audio_policy_configuration_generic.xml is pushed in /system as the default
configuration (used if the vendor does not provide one in /vendor or /odm)
and for the emulator.

As a result it can be parsed by 2.0 and 4.0 audio HALs. The format
is retro-compatible, but not forward-compatible.

Additionally, the generic config pushed in /system should never be used
as the vendor should always provide a configuration file describing its
target architecture. Thus it should not be part of the GSI.

Those files were originally pushed in /system the emulator
target does not provide its own configuration file.
The emulator should provide config file instead in /vendor instead.

Bug: 78543061
Test: sdk_gphone_x86 and aosp_x86_64 emulator has audio
Test: adb shell cat /vendor/etc/audio_policy_configuration.xml | diff - \
          frameworks/av/services/audiopolicy/config/audio_policy_configuration_generic.xml
Change-Id: Ice43cb4670a82f4e60fcccc58a636d224f240b5a
Merged-In: Ice43cb4670a82f4e60fcccc58a636d224f240b5a
Signed-off-by: Kevin Rocard <krocard@google.com>
(cherry picked from commit dad3ad6126)
2018-08-21 06:42:11 +00:00
bohu ebbdea824f emulator: factor vendor partition out of emulator.mk
The emulator vendor paritions are better moved out of
emulator.mk into device/generic/goldfish/vendor.mk
so that changes in vendor.mk will just concentrate on
vendor partition.

this cl does not impact real devices, and it does not
even impact emulator images (it does code refactoring only)

BUG: 110030159

Change-Id: Ic5778cda8ca6ccf7bc2bc2f9028f801cda970143
Merged-In: Ic5778cda8ca6ccf7bc2bc2f9028f801cda970143
(cherry picked from commit 6676853016)
2018-08-21 14:40:43 +08:00
Colin Cross 5d1688bf27 Merge "Fix reference to cleared global variable" 2018-08-21 02:50:50 +00:00
Colin Cross cceb7ab6d7 Fix reference to cleared global variable
Use PRIVATE_general_tests_list_zip inside the rule.  Also remove the
output files to make it more likely that an incremental build fails
the same was as a clean build.

Bug: 112865316
Test: rm $OUT/general-tests* && m general-tests
Change-Id: Idbca35f9ca71f65ef45ef026df41bd933fb9d37d
2018-08-20 19:26:33 -07:00
Yifan Hong d35fdd8b3d Merge changes from topic "product-service-remove-hyphen"
* changes:
  s/product-services/product_services/g
  Reland "s/PRODUCT-SERVICES/PRODUCT_SERVICES/g"
  Update CleanSpec to remove generated files from IVold.aidl.
2018-08-21 01:07:56 +00:00
Treehugger Robot 36ea50d760 Merge "Add "hwaddress" sanitizer." 2018-08-20 23:22:35 +00:00
Treehugger Robot 5d1926376e Merge "Use multiple globs/emails in per-file syntax" 2018-08-20 22:34:36 +00:00