Ninja stops parsing top level options after -t is used to select a
tool. Put any inserted command line options at the beginning of the
command.
Change-Id: I2ba903143366aaded63e21d749476248617c8962
When building incremental packages, the info_dict from the source build
should be the one in use. We have done that for most of the partitions
(system and etc.), and should pass that to vendor's script as well.
Also includes the CL in commit aac4ad56b6
that fixes a bug in commit 6f0b219ac5.
Bug: 24898607
Change-Id: I4ea6037dad7061e1683661fc4c394fa3a7a7c5cd
(cherry picked from commit 6f0b219ac5)
Append error-correcting codes to verified partitions provided that
PRODUCT_SUPPORTS_VERITY_FEC is true.
This moves verity metadata to be after the hash tree, and requires
matching changes from
Ide48f581bbba77aed6132f77b309db71630d81ed
Bug: 21893453
Change-Id: I6945cbab99e214566a1f9d3702333f2dbbc35816
When building incremental packages, the info_dict from the source build
should be the one in use. We have done that for most of the partitions
(system and etc.), and should pass that to vendor's script as well.
Bug: 24898607
Change-Id: Ie2973d41b905637862616286663baf80df83bd88
This CL changes to use a fixed timestamp only when packaging
into the target_files zip.
Bug: 24377993
Change-Id: I01d136f4b99e1eff80c559192d93db83a3c5c0a4
(cherry picked from commit 822f5840c0)
* commit '761fcbe7920ccc3fc2e85fde2844f19ce9163658':
add unique ID to each windows download link. These IDs are necessary for the TOS wall to identify which link should be applied to the download button.
* commit '1b5eef1b490cc143474ec74d58369aac9bf6629e':
add unique ID to each windows download link. These IDs are necessary for the TOS wall to identify which link should be applied to the download button.
* commit 'b16edb5f3ef9032b7e19c29aac2496c34bb8ac76':
add unique ID to each windows download link. These IDs are necessary for the TOS wall to identify which link should be applied to the download button.
These IDs are necessary for the TOS wall to identify which link should be applied to the download button.
Change-Id: I1b5b8b516a5b8d7fd8433c02011cb4fb2044b71f
[1] changed to use a fixed timestamp for all the generated images
(either the one under $ANDROID_PRODUCT_OUT/ or the one added into the
target_files zip). It makes 'adb sync' after 'fastboot flashall' to
resync all the files. This CL changes to use a fixed timestamp only when
packaging into the target_files zip.
[1]: commit 052ae3542b
Bug: 24377993
Bug: 24536411
Change-Id: I209318966109fd4902468dfe96caf777464f9fe1
When signapk.jar is invoked by scripts like
sign_target_files_apks.py, there is no console as signapk is
invoked using popen(). To support signing of APKs using
software keys with passwords, we need to read
the password from stdin if there is no console.
Change-Id: Icf69ba1e58bf1f91979eaf1d3b91cb202782e8fd
Signed-off-by: adattatr <anisha.dattatraya.kulkarni@intel.com>
Signed-off-by: Brad Geltz <brad.geltz@intel.com>
ro.bootimage.build.fingerprint should be updated when signing.
Bug: 22720426
Bug: 24009888
Change-Id: Ib246a257581fd31f90ad6b3d21f39d1a2de24ba8
(cherry picked from commit 265d9aeb62)
Allow makeparallel to pass better -j and -k arguments to ninja if the
first argument to makeparallel is --ninja. Uses getopt to parse
MAKEFLAGS to get values for --jobserver-fds, -k, and -j, and uses the
result to not pass any -j argument to ninja for make -j with no number,
and pass -k0 to ninja for make -k.
Also improve the test makefile to provide many more tests.
Bug: 24199503
Change-Id: Id6481430f77e9e952213be58a98fe78c46ee5d6a
The signing process requires the boot and recovery images be signed
by CROS-Signer, which is done after a signed_target_files.zip is
available. Once the boot/recovery images are signed, we need
to insert it back into signed_target_files.zip and regenerate the
system.map and verity tree. The script (add_img_to_target_files) does
this operation and needs to be aware of verity specific flags.
Bug: 23831896
Change-Id: Id24e878161052c768b74da1231b97eb0574b4c8b
makeparallel communicates with the GNU make jobserver
(http://make.mad-scientist.net/papers/jobserver-implementation/)
in order claim all available jobs, and then passes the number of jobs
claimed to a subprocess with -j<jobs>.
Change-Id: Id41a2d81e0d835517da8ba52c818c763fc455c14
With the change in [1], it zeroes out extra blocks that might be read
by dm-verity. We should update the expected number of blocks that get
touched.
[1] commit e9b619108d.
Bug: 23786644
Change-Id: I7a7c3531e5af6bf381d3a14832e77abfa9a8efce
For a DataImage, we may have no mapping of ZERO or NONZERO blocks. Don't
write those groups if they are empty.
Bug: 19024504
Change-Id: I1e921effcdbf0661d4f4b541c104dd456ac0c582
In BBOTAs if the last block of a DataImage is padded, we should always
write the whole block even for incremental OTAs. Because otherwise the
last block may be skipped if unchanged, but would fail the post-install
verification if it has non-zero contents in the padding bytes.
Bug: 23828506
Change-Id: I6f6789eec568ed0b808b9e425f5ecdbea1bdf446
(cherry picked from commit 7589e961a7)
In BBOTAs if the last block of a DataImage is padded, we should always
write the whole block even for incremental OTAs. Because otherwise the
last block may be skipped if unchanged, but would fail the post-install
verification if it has non-zero contents in the padding bytes.
Bug: 23828506
Change-Id: I4b0af7344d18261258cd48d18c029c089d6ff365
For file-based OTAs, we used to remove unneeded files in ascending
order, which failed to delete non-empty directories. Reverse the order
to fix the issue.
For example, now we have the following in our generated script:
delete("/system/app/Calculator/arm/Calculator.odex",
"/system/app/Calculator/arm/",
"/system/app/Calculator/Calculator.apk",
"/system/app/Calculator/");
Bug: 22960996
Change-Id: I0d36d29b7862fb53bf55bf5685a990180f9c0b3b
Instead of wrapping a host module definition in 'ifeq($(HOST_OS),...)'
in the Android.mk files, define which hosts are supported using
LOCAL_MODULE_HOST_OS.
A blank LOCAL_MODULE_HOST_OS means that linux and darwin are supported.
A non-empty LOCAL_MODULE_HOST_OS lists the supported HOST_OSs.
Change-Id: I1e342d1908cfa00aef2c39c145b4f5f81c373bc6
For file-based OTAs, symlinks in the source build but not in the target
build will be deleted. However, if a symlink is replaced by a regular
file in the target build, the file will be accidentally deleted when
applying (resuming) the same package again.
Verify the checksum of a symlink that will be unpacked or renamed to.
Delete the file only if it doesn't have the target checksum.
Bug: 23646151
Change-Id: I77bae035e39f2e0be25f7f6d71c5882464e3d50f
(cherry picked from commit 84006eacd0)
For file-based OTAs, symlinks in the source build but not in the target
build will be deleted. However, if a symlink is replaced by a regular
file in the target build, the file will be accidentally deleted when
applying (resuming) the same package again.
Verify the checksum of a symlink that will be unpacked or renamed to.
Delete the file only if it doesn't have the target checksum.
Bug: 23646151
Change-Id: Ie322abb6022b6fa812c6b36a3127872d9614fc3b
* commit '59bc470107ad2e1aac75155f3acc07755232534c':
Fix bug that caused table of Studio links to result in "stand-alone" tools instructions. bug: 23570662
* commit '77c1ff7bf983ef4622ecb227d4e5b0c75728c28f':
Fix bug that caused table of Studio links to result in "stand-alone" tools instructions. bug: 23570662
* commit '4ffdc8faf2c795027f38b6ef4685dd6d1179878e':
Fix bug that caused table of Studio links to result in "stand-alone" tools instructions. bug: 23570662
* commit 'e337093e6c5d502f0f4094639b41c001b3048d0f':
Split large files for BBOTA v3.
Revise stash for BBOTAs when needed.
Assert the stash size when generating OTAs.
Changes in [1] break the backward compatibility of the OTA scripts. Fix
the issue by extracting the file basename from the info dict in
META/misc_info.txt.
[1] commit d3a803e668
Bug: 23620049
Change-Id: I40a5625bbe0beb295f34b2328906a4a4283fe59b
So that we can support building both linux and windows binaries at the
same time on a linux host. This replaces the ifeq($(HOST_OS),...) checks
in Android.mk files.
Bug: 23566667
Change-Id: I693e11984e36d55bb6f09fa0d49bc485463e16fb
RangeSet("2-10").monotonic gives a wrong result of "False". Fix the bug
and add more tests into test_rangelib.py.
Change-Id: I04780571b45ecafd34040f405756b9745a9e21a5
Separate the test cases in rangelib.py comments into a python unittest
file.
To invoke:
$ python -m unittest test_rangelib
Change-Id: I59e4ce0aaccc83bcbb42fee15775683dcd559d99
For BBOTA v3, we need to stash source blocks to support resumable
feature. However, with the growth of file size and the shrink of the
cache size, source blocks that represent a file are too large to be
stashed as a whole. CL in [1] solves the issue by replacing the diff
command with a "new" command. However, it may increase the generated
package size substantially (e.g. from ~100MB to ~400MB).
With this CL, if a file spans too many blocks, we split it into smaller
pieces by generating multiple commands. For the same case above, it
reduces the package size to ~150MB.
One potential downside is that after splitting, files like .jar,
.apk and .zip can no longer use imgdiff. We may lose the potential
benefit of using imgdiff for patch size reduction.
[1] commit 82c47981bd
Bug: 22430577
Change-Id: Iee1ad6543f3d40368e079e418cc31728e1ab3f48
(cherry picked from commit 9a5caf2c30)
When generating incremental BBOTAs (v2 and above), we need to ensure
that the needed runtime stash is below the given threshold. If it's
running out of space on /cache, we replace the command that uses a
stash with a "new" command instead.
This may increase the OTA package size, since it is carrying more full
blocks instead of patches. It gets even worse for large files that span
a number of blocks, because currently we will store all the blocks for
the file as "new" blocks if stashing cannot be satisfied. We may further
optimize by splitting them into smaller chunks so that most of them can
still be stashed.
Bug: 22430577
Change-Id: Ieae5243d461e3f899f613f76a380f6f7c3edb356
(cherry picked from commit 82c47981bd)
With block-based OTA v2 and v3, it requires stash space on the /cache
partition to back up blocks during an update. We need to ensure that
it doesn't exceed the partition size. Since there might be other files
on /cache as well, we use cache_size * threshold as the maximum allowed
size. The threshold defaults to 0.8, which can be overridden by command
line option '--stash_threshold'.
Change-Id: Ieee5d373c9bfb2ea401d85ca8a3adb491579de76
(cherry picked from commit 23ac404212)
For BBOTA v3, we need to stash source blocks to support resumable
feature. However, with the growth of file size and the shrink of the
cache size, source blocks that represent a file are too large to be
stashed as a whole. CL in [1] solves the issue by replacing the diff
command with a "new" command. However, it may increase the generated
package size substantially (e.g. from ~100MB to ~400MB).
With this CL, if a file spans too many blocks, we split it into smaller
pieces by generating multiple commands. For the same case above, it
reduces the package size to ~150MB.
One potential downside is that after splitting, files like .jar,
.apk and .zip can no longer use imgdiff. We may lose the potential
benefit of using imgdiff for patch size reduction.
[1] commit 82c47981bd
Bug: 22430577
Change-Id: I5684fab0ac41c8d94fe18f52a34cef77e06f741c
* commit '425e1d5c57f808ae6308d49125d68b5b43e78d7c':
fix a few bugs in the studio download button behavior: - make button text always white (avoid blue on blue during hover) - revise logic to add the platform name to download button to avoid weird duplicity bug on small screens - remove the animation script when clicking download before agree because it reloaded the page (unkown cause) depends on: https://googleplex-android-review.git.corp.google.com/#/c/752757/
* commit '15bb28fc73fa30e9c7b8ee0d924c8906724809e0':
fix a few bugs in the studio download button behavior: - make button text always white (avoid blue on blue during hover) - revise logic to add the platform name to download button to avoid weird duplicity bug on small screens - remove the animation script when clicking download before agree because it reloaded the page (unkown cause) depends on: https://googleplex-android-review.git.corp.google.com/#/c/752757/
* commit 'ed7e864a735f004f1dbb4a2db5261855b5693913':
fix a few bugs in the studio download button behavior: - make button text always white (avoid blue on blue during hover) - revise logic to add the platform name to download button to avoid weird duplicity bug on small screens - remove the animation script when clicking download before agree because it reloaded the page (unkown cause) depends on: https://googleplex-android-review.git.corp.google.com/#/c/752757/
* commit 'ed7e864a735f004f1dbb4a2db5261855b5693913':
fix a few bugs in the studio download button behavior: - make button text always white (avoid blue on blue during hover) - revise logic to add the platform name to download button to avoid weird duplicity bug on small screens - remove the animation script when clicking download before agree because it reloaded the page (unkown cause) depends on: https://googleplex-android-review.git.corp.google.com/#/c/752757/
- make button text always white (avoid blue on blue during hover)
- revise logic to add the platform name to download button to avoid weird duplicity bug on small screens
- remove the animation script when clicking download before agree because it reloaded the page (unkown cause)
depends on: https://googleplex-android-review.git.corp.google.com/#/c/752757/
Change-Id: I1b2b4ff9c0b0cbbd34f1c77a2b736fe3425a16e4
For squashfs, we currently don't have a system.map. So the whole system
image will be treated as a single file. But for some unknown bug, the
updater will be killed due to OOM when writing back the patched image to
flash (observed on lenok-userdebug MEA49). Prior to getting a real fix,
we evenly divide the non-zero blocks into smaller groups (currently 1024
blocks or 4MB per group).
Bug: 23227672
Change-Id: Ifeddd8d802f01f8cd2a743a1d1217a284fb6e182
* commit 'c10e65ac58064ee1595864c2db3c39e35f70944f':
DO NOT MERGE Revert "D.N.M. Revert "Add the ability to display annotations in the generated docs""
We still support HOST_OS=windows for the SDK host tools cross-builds, but
that's only when USE_MINGW is set when running under linux.
Change-Id: I37da87dc9fbbd69ba10ce4d7f2668ab3f6482d92
When generating incremental BBOTAs (v2 and above), we need to ensure
that the needed runtime stash is below the given threshold. If it's
running out of space on /cache, we replace the command that uses a
stash with a "new" command instead.
This may increase the OTA package size, since it is carrying more full
blocks instead of patches. It gets even worse for large files that span
a number of blocks, because currently we will store all the blocks for
the file as "new" blocks if stashing cannot be satisfied. We may further
optimize by splitting them into smaller chunks so that most of them can
still be stashed.
Bug: 22430577
Change-Id: I5a49e361adc7d3d41de2e9c08ee9b08c1e6c091a
In BBOTA v2, the stash size computation is inaccurate. A stash will be
used only once, so we deduct its size from stashed_blocks right after
its use. However, the stash doesn't actually get freed until being
overwritten by another stash or destroyed at the end of an update. This
leads to OTA failures due to insufficient space on /cache. This CL
changes the BBOTA v2 script to generate an explicit free right after
its use.
Bug: 23119955
Change-Id: Icdd8352bb0ff778945937c870990a888c7a4d38b
This moves all of the date references under build/ to using a single
datetime that can be set manually using BUILD_DATETIME.
It also adds an option, OVERRIDE_C_DATE_TIME, that if set to true, will
redefine __DATE__ and __TIME__ for all C/C++ files so that it matches
BUILD_DATETIME.
Bug: 23117013
Change-Id: I7c17a32b794a5adf40b9cd69136fb0ff9f6084ec
In ext4 filesystems, some blocks might be changed even being mounted
R/O, such as the superblock (block 0). We need to exclude such blocks
from integrity verification. Plus such blocks should always be
written to the target by copying instead of patching.
Bug: http://b/20939131
Change-Id: If9efab3d7a0071a87b4d4297daf7963c3b818afe
(cherry picked from commit ff7778166b)
This moves all of the date references under build/ to using a single
datetime that can be set manually using BUILD_DATETIME.
It also adds an option, OVERRIDE_C_DATE_TIME, that if set to true, will
redefine __DATE__ and __TIME__ for all C/C++ files so that it matches
BUILD_DATETIME.
Bug: 23117013
Change-Id: I880ef103a26bca86bd7bf42d58e62e740a6228c8
This is reverted along with ag/745924 due to GmsCore build breakage.
This reverts commit a76428792f.
Change-Id: Ib66777e003cd7ab3ed056777686086e9b5d92698
* commit '540abfef5e1a0b73b928914100842e000f8ea010':
Add the ability to display annotations in the generated docs (cherry-picked from commit 87c44d8a11) Bug: 8440225 Change-Id: I41c1c7909b283832b818b8860ffe370cd4328f20
* commit '86e510cc313a464870ff82a9cd7f7206ea4aeb63':
Add the ability to display annotations in the generated docs (cherry-picked from commit 87c44d8a11) Bug: 8440225 Change-Id: I41c1c7909b283832b818b8860ffe370cd4328f20
* commit '71a33c4d5b010757423980b90681445ca2bb2be0':
Add the ability to display annotations in the generated docs (cherry-picked from commit 87c44d8a11) Bug: 8440225 Change-Id: I41c1c7909b283832b818b8860ffe370cd4328f20
* commit '71a33c4d5b010757423980b90681445ca2bb2be0':
Add the ability to display annotations in the generated docs (cherry-picked from commit 87c44d8a11) Bug: 8440225 Change-Id: I41c1c7909b283832b818b8860ffe370cd4328f20
With the change in vboot_signer (CL:744257), an additional parameter
is required to vboot_signer script. This change adds the required
parameter to releasetools as well.
BUG=23076037
Change-Id: Ice5329578b3a9bc459e278a9d404a1981b35ca88
Signed-off-by: Furquan Shaikh <furquan@google.com>
For some old builds, we may not define cache partition size. Change the
exception into a warning to make the script backward compatible.
Change-Id: Ie94c7fbb1a9f3a7db3f16e8d845e493a534aac5b