Commit Graph

37834 Commits

Author SHA1 Message Date
Yi Kong dd65f96c3d Switch to clang-4053586
Bug: 37423073
Test: Build on multiple devices
Change-Id: Ic1a5f515db66275ee96fb6a614ffbb719bb91859
2017-06-02 22:13:01 -07:00
Steven Moreland 930d880148 Merge "Move math function definitions." into oc-dev
am: fb3424166b  -s ours

Change-Id: I699f0527d58eb146686e40271aa766420dbdb99a
2017-06-03 00:18:22 +00:00
TreeHugger Robot fb3424166b Merge "Move math function definitions." into oc-dev 2017-06-03 00:15:10 +00:00
Tao Bao 7db0ac5d38 Merge "DO NOT MERGE Revert "Revert "releasetools: Support OTAs that have OEM properties changes.""" into cw-f-dev am: fccf4ec06e am: a1980abe1f -s ours
am: 132566628b  -s ours

Change-Id: I75790b209f2b246deb1a71b70b07db4ab9a035df
2017-06-02 23:03:14 +00:00
Tao Bao 132566628b Merge "DO NOT MERGE Revert "Revert "releasetools: Support OTAs that have OEM properties changes.""" into cw-f-dev am: fccf4ec06e
am: a1980abe1f  -s ours

Change-Id: I613b3f6e028acf05213db3e3765b9faf973c9976
2017-06-02 22:59:44 +00:00
Tao Bao fdbab23a98 Merge "DO NOT MERGE Revert "Revert "releasetools: Support OTAs that have OEM properties changes.""" into cw-f-dev am: fccf4ec06e am: a1980abe1f -s ours
am: 2ad185af2a

Change-Id: Ib00c56c88f42150a7c65276c996a2e9f524ea0c9
2017-06-02 22:56:44 +00:00
Tao Bao 2ad185af2a Merge "DO NOT MERGE Revert "Revert "releasetools: Support OTAs that have OEM properties changes.""" into cw-f-dev am: fccf4ec06e
am: a1980abe1f  -s ours

Change-Id: I8558172a3171d992073b34ed249e69d0f6ca33f3
2017-06-02 22:53:13 +00:00
Tao Bao a1980abe1f Merge "DO NOT MERGE Revert "Revert "releasetools: Support OTAs that have OEM properties changes.""" into cw-f-dev
am: fccf4ec06e

Change-Id: If7d5b3cd4de5f558275453d0d4a599995390a4a0
2017-06-02 22:50:15 +00:00
Tao Bao fccf4ec06e Merge "DO NOT MERGE Revert "Revert "releasetools: Support OTAs that have OEM properties changes.""" into cw-f-dev 2017-06-02 22:42:27 +00:00
Tao Bao 891c29766e Merge "Support re-generating DTBO image from add_img_to_target_files.py." am: 4536e45f66 am: b88e3f20a6
am: cdabed4ee8

Change-Id: Ic890baa277142baf355c1196afd7705c117761a3
2017-06-02 22:39:44 +00:00
Tao Bao cdabed4ee8 Merge "Support re-generating DTBO image from add_img_to_target_files.py." am: 4536e45f66
am: b88e3f20a6

Change-Id: I6f0ea6434516be6f71285f9b715a8f9bb0d8b3b3
2017-06-02 22:32:43 +00:00
Tao Bao b88e3f20a6 Merge "Support re-generating DTBO image from add_img_to_target_files.py."
am: 4536e45f66

Change-Id: I014ce603524c917cfa2f3011788fd25db01b1f6a
2017-06-02 22:25:43 +00:00
Dan Willemsen ccc48163ea Fix ALLOW_MISSING_DEPENDENCIES in PDK builds
ALLOW_MISSING_DEPENDENCIES was being set up before TARGET_BUILD_PDK, so
PDK builds were not triggering ALLOW_MISSING_DEPENDENCIES.

Bug: 62086238
Test: m -j nothing (check out/soong/soong.variables for AllowMissingDependencies)
Test: PDK_FUSION_PLATFORM_ZIP=test.zip m -j nothing (check AllowMissingDependencies)
Change-Id: I70919fbc7e397e55356cb467c6218cf6e7279c6c
2017-06-02 15:25:20 -07:00
Tao Bao 4536e45f66 Merge "Support re-generating DTBO image from add_img_to_target_files.py." 2017-06-02 22:13:36 +00:00
Tianjie Xu 9989175c0e Merge "Generate care_map.txt when AVB is enabled" am: 65b98cd3b1 am: 1e0b14eb33
am: 72274464c4

Change-Id: I7549c4f1b66ee1bf8dfaab26e90a2022f9f19dea
2017-06-02 18:24:35 +00:00
Tianjie Xu 72274464c4 Merge "Generate care_map.txt when AVB is enabled" am: 65b98cd3b1
am: 1e0b14eb33

Change-Id: I08cbb2e92028131511a9740aa50c4ddaf3f9fd95
2017-06-02 18:21:10 +00:00
Tianjie Xu 1e0b14eb33 Merge "Generate care_map.txt when AVB is enabled"
am: 65b98cd3b1

Change-Id: I9fd14966a7264d560c940bacebe8ef5b8a4722da
2017-06-02 18:18:09 +00:00
Tianjie Xu 65b98cd3b1 Merge "Generate care_map.txt when AVB is enabled" 2017-06-02 18:09:58 +00:00
Tianjie Xu 6b2e155ee6 Generate care_map.txt when AVB is enabled
When AVB is enabled, generate care_map.txt and add it to the target
files. Also copy it into the OTA package where it will later be used
by the update_verifier.

Bug: 62208947
Test: \
1. Run add_img_to_target_files on the TF of a new pixel device,
and care_map.txt generates successfully.

2. Make dist in oc-dr1-release and find care_map.txt in the OTA package.

3. update_verifier succeeds in reading all the blocks on the care_map,
and fails to read out-of-bound blocks.

Change-Id: I2881711e6f87789cb7de150dbeca18b756fed68a
2017-06-01 21:36:43 -07:00
Julius D'souza caa6d7aa1b Merge "DO NOT MERGE: Add the option to reserve headroom for partition images. This is useful for devices with low disk space with different build variants." into cw-f-dev am: 1590301a9b am: 92aa9636ad -s ours
am: 5f0c0da2b2  -s ours

Change-Id: I8d4afbf4f39829c7034cf4b8b11f2b48698dd8db
2017-06-02 04:28:54 +00:00
Julius D'souza 5f0c0da2b2 Merge "DO NOT MERGE: Add the option to reserve headroom for partition images. This is useful for devices with low disk space with different build variants." into cw-f-dev am: 1590301a9b
am: 92aa9636ad  -s ours

Change-Id: I1dbb5a705f4aca21864c1072bd39f7924d43a4f8
2017-06-02 04:25:01 +00:00
Julius D'souza 3ec59fa015 Merge "DO NOT MERGE: Add the option to reserve headroom for partition images. This is useful for devices with low disk space with different build variants." into cw-f-dev am: 1590301a9b am: 92aa9636ad -s ours
am: 5a30a841ed

Change-Id: Id8da8a652fdec6ca35db052256bc87b1a25509be
2017-06-02 03:20:24 +00:00
Julius D'souza 5a30a841ed Merge "DO NOT MERGE: Add the option to reserve headroom for partition images. This is useful for devices with low disk space with different build variants." into cw-f-dev am: 1590301a9b
am: 92aa9636ad  -s ours

Change-Id: I6e01024aebefcbd46ba993dfb4290a2925080305
2017-06-02 03:17:54 +00:00
Julius D'souza 92aa9636ad Merge "DO NOT MERGE: Add the option to reserve headroom for partition images. This is useful for devices with low disk space with different build variants." into cw-f-dev
am: 1590301a9b

Change-Id: I85bbf6b85c42ff3e9e69565812f8a2b8a0f41833
2017-06-02 03:14:54 +00:00
Tao Bao c633ed0230 Support re-generating DTBO image from add_img_to_target_files.py.
This is a step to enable signing a given target_files zip with release
keys.

When calling sign_target_files_apks.py, we will delete all the entries
under IMAGES/ in order to re-generate them (with the proper release
keys). In order to support that, we need to pack everything in need into
TF.zip.

Steps to test the CL.
a) Choose a target that has both AVB and DTBO enabled.
 $ m dist

b) Check IMAGES/dtbo.img and PREBUILT_IMAGES/dtbo.img both exist in the
   generated out/dist/TF.zip.

c) Remove the entries under IMAGES/ from the generated TF.zip.
 $ zip -d TF.zip IMAGES/\*

d) Re-generate the images with TF.zip.
 $ build/make/tools/releasetools/add_img_to_target_files.py TF.zip

e) Check that IMAGES/dtbo.img is re-generated, and it's identical to the
   image in b). Note that by default the re-generated image will carry a
   different footer, because of the random salt. This CL is verified by
   specifying the same salt.

Bug: 38315721
Test: see above.
Change-Id: I0bdc4e1cd4800962dc3902ca550dad6a8ca56c78
2017-06-01 20:07:33 -07:00
TreeHugger Robot 1590301a9b Merge "DO NOT MERGE: Add the option to reserve headroom for partition images. This is useful for devices with low disk space with different build variants." into cw-f-dev 2017-06-02 03:06:59 +00:00
Steven Moreland 8fb19697da Merge "Move math function definitions." am: b5e90583ef am: d1eab0ea46
am: a2f3561259

Change-Id: I86436840a6c5877901a13384faea6e699f0edfa9
2017-06-02 00:25:16 +00:00
Steven Moreland a2f3561259 Merge "Move math function definitions." am: b5e90583ef
am: d1eab0ea46

Change-Id: Ibef05e7c0ffee8d02e49c2d4893b4fa28f153a2f
2017-06-02 00:21:43 +00:00
Steven Moreland 15f5672a5d Move math function definitions.
Created math.mk and moved all math function definitions there.
Then, included this file in config.mk. This allows the functions to be
used by whatever includes config.mk (envsetup and build).

Test: manually setting combinations of PRODUCT_SHIPPING_API_LEVEL
  and PRODUCT_FULL_TREBLE_OVERRIDE and looking at values of
  PRODUCT_FULL_TREBLE.
Bug: 62229856
Merged-In: Icdab4214a1e65ae202411613dbcb9c9ea5f43b09
Change-Id: Icdab4214a1e65ae202411613dbcb9c9ea5f43b09
2017-06-01 17:18:56 -07:00
Steven Moreland d1eab0ea46 Merge "Move math function definitions."
am: b5e90583ef

Change-Id: I5da450082180b92cbb1028887ce6d492bdba39a0
2017-06-02 00:18:43 +00:00
Treehugger Robot b5e90583ef Merge "Move math function definitions." 2017-06-02 00:11:04 +00:00
Tao Bao 7fc951ca6a DO NOT MERGE Revert "Revert "releasetools: Support OTAs that have OEM properties changes.""
This CL fixes the bug in [1] (copy-paste error) and reenables it.

We need to handle a special case that an OTA goes from a source build
without OEM properties to a target build with those properties (or vice
versa). Add support in OTA scripts to deal the case properly, by a)
using two oem_props variables to handle source and target builds
respectively; b) adjusting the fingerprint/thumbprint assertions to
allow a mix of both.

[1] commit c086370440

Bug: 62252466
Change-Id: I98118d77d5a0ff694fa1ee33602b5ee5e048599b
(cherry picked from commit eee30d97dde42416a1762c161ed7217d4e7ebf2c6)
2017-06-01 14:59:46 -07:00
Dan Willemsen 9afb656369 Merge "Fix make warning/error colors on Mac" am: a46695c337 am: 6ee5e52f77
am: c9b89ad0fe

Change-Id: I2349136dcf43dd0336bbb8638bd03eab84082f2f
2017-06-01 08:34:58 +00:00
Dan Willemsen c9b89ad0fe Merge "Fix make warning/error colors on Mac" am: a46695c337
am: 6ee5e52f77

Change-Id: I84a562377b14c310cd0c3259f110e82dd0fcfcca
2017-06-01 08:32:34 +00:00
Dan Willemsen 6ee5e52f77 Merge "Fix make warning/error colors on Mac"
am: a46695c337

Change-Id: Ia9b08f47cbe9098c262f9202465475dac4912b63
2017-06-01 08:30:03 +00:00
Treehugger Robot a46695c337 Merge "Fix make warning/error colors on Mac" 2017-06-01 08:24:49 +00:00
Tao Bao ffa864c5ed Merge "Pack avbtool into otatools.zip." am: db5fa05429 am: 308b234593
am: 0c2bc7a7b1

Change-Id: I1f15f62536e3030bee7fec0fdacb1ef8ee57a69e
2017-06-01 07:30:30 +00:00
Tao Bao 0c2bc7a7b1 Merge "Pack avbtool into otatools.zip." am: db5fa05429
am: 308b234593

Change-Id: I3c76f14de97fae8e35d713a0ea728c2d8c0ae587
2017-06-01 07:28:33 +00:00
Tao Bao 308b234593 Merge "Pack avbtool into otatools.zip."
am: db5fa05429

Change-Id: Iddc58c0c56b1437287e6d00d03cdbdef01f97c74
2017-06-01 07:26:30 +00:00
Treehugger Robot db5fa05429 Merge "Pack avbtool into otatools.zip." 2017-06-01 07:19:17 +00:00
Dan Willemsen 25f2d0ded7 Fix make warning/error colors on Mac
Apparently the default bash echo doesn't support \e even though the man
page says it does. So use \033 instead.

Test: m -j nothing on mac, get colors
Test: m -j nothing on linux, still get colors
Change-Id: I608fa87e3c28bf8f99264d39f9b250008a81235a
2017-05-31 19:20:09 -07:00
Tao Bao 30295a396f Merge "Remove the obsolete logic in img_from_target_files.py." am: ba029141dc am: f37c956b6d
am: 464fed4f53

Change-Id: If990a48a06ba4b48e865e4098d58fed4a074d896
2017-05-31 23:30:59 +00:00
Tao Bao 464fed4f53 Merge "Remove the obsolete logic in img_from_target_files.py." am: ba029141dc
am: f37c956b6d

Change-Id: Iad1c47544f82bf21297b4fdb36e983ff7a4dab38
2017-05-31 23:24:57 +00:00
Tao Bao f37c956b6d Merge "Remove the obsolete logic in img_from_target_files.py."
am: ba029141dc

Change-Id: Ic604d1afa537906033f2a4b59e9c0931bcaad29e
2017-05-31 23:22:26 +00:00
Tao Bao ba029141dc Merge "Remove the obsolete logic in img_from_target_files.py." 2017-05-31 23:18:15 +00:00
Steven Moreland a64f33668e Move math function definitions.
Created math.mk and moved all math function definitions there.
Then, included this file in config.mk. This allows the functions to be
used by whatever includes config.mk (envsetup and build).

Test: manually setting combinations of PRODUCT_SHIPPING_API_LEVEL
  and PRODUCT_FULL_TREBLE_OVERRIDE and looking at values of
  PRODUCT_FULL_TREBLE.
Bug: 62229856
Change-Id: Icdab4214a1e65ae202411613dbcb9c9ea5f43b09
2017-05-31 20:41:49 +00:00
Tao Bao 2bb109709a Remove the obsolete logic in img_from_target_files.py.
img_from_target_files.py used to handle the case that a given TF.zip not
containing the image entries under IMAGES/. That is only the case for
pre-Lollipop releases.

Also unzip the needed files only since we know that for sure now.

Test: img_from_target_files.py with an existing bullhead-TF.zip gives
      the same bullhead-img.zip.
Change-Id: I892379ba388df80ae63be9d3ce647fbb77fd4753
2017-05-31 11:17:56 -07:00
Tao Bao 3cba374da2 Pack avbtool into otatools.zip.
Also pack the test keys for easier testing.

Bug: 38315721
Test: m otatools-package and avbtool is present in otatools.zip.
Change-Id: Ieb63bf3f4bc211ef1f48ab278cb01b70845d06da
2017-05-31 10:20:25 -07:00
Bowgo Tsai b4c268eb7b Merge "Support signing custom images with AVB HASH or AVB HASHTREE" am: fe7aeb1de7 am: 16b64cbb58
am: 3989b738b8

Change-Id: I11393e1833db97301ffdd31ec3db0968e87c1a24
2017-05-31 03:38:24 +00:00
Bowgo Tsai 3989b738b8 Merge "Support signing custom images with AVB HASH or AVB HASHTREE" am: fe7aeb1de7
am: 16b64cbb58

Change-Id: I67b3fa64f13d08ee3e4232547d08f6d91e2676d7
2017-05-31 03:33:54 +00:00