Commit graph

66475 commits

Author SHA1 Message Date
Bob Badour
0390580262 [LSC] Add LOCAL_LICENSE_KINDS to build/make
Added SPDX-license-identifier-Apache-2.0 to:
  target/product/sysconfig/Android.bp
  tools/apicheck/Android.bp
  tools/product_config/Android.bp
  tools/releasetools/Android.bp
  tools/signapk/Android.bp
  tools/signtos/Android.bp
  tools/zipalign/Android.bp
  tools/ziptime/Android.bp

Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD
    SPDX-license-identifier-CC-BY SPDX-license-identifier-GPL
    SPDX-license-identifier-GPL-2.0 SPDX-license-identifier-LGPL
    SPDX-license-identifier-MIT legacy_not_a_contribution
    legacy_restricted
to:
  Android.bp

Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD
    SPDX-license-identifier-CC-BY SPDX-license-identifier-GPL
    SPDX-license-identifier-MIT
to:
  tools/Android.bp
  tools/droiddoc/Android.bp

Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD
    SPDX-license-identifier-GPL SPDX-license-identifier-GPL-2.0
    SPDX-license-identifier-LGPL SPDX-license-identifier-MIT
to:
  core/base_rules.mk
  core/dex_preopt_libart.mk
  core/package_internal.mk

Added SPDX-license-identifier-Apache-2.0 legacy_not_a_contribution
to:
  target/board/Android.mk

Added legacy_restricted
to:
  core/tasks/tools/package-modules.mk
  target/product/gsi/Android.bp
  target/product/gsi/Android.mk
  target/product/security/Android.bp
  target/product/security/Android.mk
  tools/acp/Android.bp
  tools/atree/Android.bp
  tools/fs_config/Android.bp
  tools/fs_config/Android.mk
  tools/fs_get_stats/Android.bp
  tools/libhost/Android.bp

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all

Exempt-From-Owner-Approval: janitorial work
Change-Id: Id67a4eb1312940f999643b2ae57f45f34f120724
2021-02-14 10:37:20 -08:00
Yo Chiang
25d0acf00f Merge "Revert "Set PRODUCT_SHIPPING_API_LEVEL in gsi_release.mk"" 2021-02-13 06:09:36 +00:00
Yo Chiang
1178673d5e Revert "Set PRODUCT_SHIPPING_API_LEVEL in gsi_release.mk"
This reverts commit ecaa592310.

Reason for revert: b/177495407#comment9 breaks aosp_arm

Exempt-From-Owner-Approval: Clean revert

Change-Id: If4586901fc1806c5394a385c8686ef5fd8748f24
2021-02-13 06:08:54 +00:00
Ulyana Trafimovich
e5511ed739 Merge "Preserve <uses-library> order in dexpreopt.config files." 2021-02-12 10:22:39 +00:00
Yo Chiang
2ecbebdcd2 Merge "Set PRODUCT_SHIPPING_API_LEVEL in gsi_release.mk" 2021-02-12 09:35:55 +00:00
Treehugger Robot
3c1a6ee5ad Merge "Fix error where otacerts in VENDOR_BOOT isn't replaced" 2021-02-12 06:06:11 +00:00
Treehugger Robot
ba106847ff Merge "Fix signing errors where some partitions aren't properly signed" 2021-02-12 04:29:44 +00:00
Treehugger Robot
d3f5268dfb Merge changes Icd25d2d0,I39ef10b0,I06bb80fe
* changes:
  Rearrange the methods on ErrorReporter to be more convenient.
  Add glue to run product-config-test as a standalone commandline executable.
  CommandException to cleanly exit product-config on error.
2021-02-12 04:03:44 +00:00
Treehugger Robot
2adfd28cdb Merge "Check for existence of private key before generating OTA" 2021-02-12 02:32:03 +00:00
Treehugger Robot
28aab78e53 Merge "Prevent SPL downgrade OTAs from generating" 2021-02-12 02:28:59 +00:00
Kelvin Zhang
9f781ff907 Fix error where otacerts in VENDOR_BOOT isn't replaced
Test: sign a target_file, check otacerts.zip
Bug: 180025432

Change-Id: I918c3772a6de83314d76884dff3b26a85ed66eb2
2021-02-11 20:14:24 -05:00
Kelvin Zhang
119f279455 Fix signing errors where some partitions aren't properly signed
Rewrite build.prop of all partitions

Test: sign an target_file, check build prop of partitions

Bug: 179186447
Bug: 180025432

Change-Id: I01249532dc2df1b6d9ec8d0be58424a76814b53e
2021-02-11 19:51:05 -05:00
Kelvin Zhang
eb586efe6f Check for existence of private key before generating OTA
At the end of OTA generation, we will use some private key to sign the
OTA payload. Since signing happens after the payload is being generated,
if caller passes an incorrect key path, caller won't notice it until 1
hour later when delta_generator finishes. At which point caller has to
staart from scratch, pass in another key path, and wait for an hour.
Let's detect incorrect key path before calling delta_generator, so
caller will get an error message right at beginning.

Test: th
Change-Id: Iefb1e0a9ed86f82664be1675afb84c020ec28fe7
2021-02-11 19:06:09 -05:00
Kelvin Zhang
80ff466780 Prevent SPL downgrade OTAs from generating
Previously we allow all spl downgrade OTA to generate. But applying such
OTA often causes device to hang and rollback, because keymaster refuses
to attach if it detects spl downgrade. When such error happens, it's
really hard to debug. So instead of debugging a mysterious boot failure,
let''s prevent such OTA from generating in the first place.

Test: th
Bug: 178584781

Change-Id: I8e271862d804e86b16aea70424b4d3e289d43cc9
2021-02-11 19:06:08 -05:00
Peter Kalauskas
a632e7f855 Merge "Fix pm.dexopt.first-boot for eng builds" 2021-02-11 18:57:45 +00:00
Peter Kalauskas
9255f59f9b Fix pm.dexopt.first-boot for eng builds
Fix pm.dexopt.first-boot missing on -eng builds causing device not to
boot

Test: Build -eng target, confirm device boots
Bug: 179990152
Change-Id: Ic963a0f7db5a39aff6198842c468de99e4949900
2021-02-11 10:45:08 -08:00
Ulya Trafimovich
8edad8f7a3 Preserve <uses-library> order in dexpreopt.config files.
Library order is important because it is used to construct class loader
context, which is then written into OAT/ODEX files and chacked against
class loader context constructed by PackageManager on the device. If the
orders are different, dexpreopted code is rejected.

This CL fixes a few problems that caused reordering:

- 'filter' function arguments are swapped so that patterns list comes
  first, and the library list second

- JSON representation of class loader context is changed to avoid
  unmarshaling it to Go maps, which may reorder keys

- library list is no longer sorted (it's unclear why it was sorted)

Bug: 132357300
Test: lunch cf_x86_64_phone-userdebug && m && launch_cvd \
      adb wait-for-device && adb root && adb logcat \
      | grep -E 'ClassLoaderContext [a-z ]+ mismatch'
      # empty grep output, no errors
Change-Id: Ie76996d497e60da0948f1879d6db589ff3e968a2
2021-02-11 17:09:19 +00:00
Oli Lan
b976c07d85 Merge "Add build task for cts_root." 2021-02-11 14:30:39 +00:00
Martin Stjernholm
a06d64be37 Merge "Ensure ART module prebuilts aren't used in sanitizer builds." 2021-02-11 14:26:06 +00:00
Oli Lan
9c8cafe38f Add build task for cts_root.
This adds the configuration necessary to allow the cts_root
test suite to be built.

Bug: 162933947
Test: m cts_root
Merged-In: I4732bf82d3cedc77e30d7fa5eff285d382992853
Change-Id: I4732bf82d3cedc77e30d7fa5eff285d382992853
2021-02-11 10:34:01 +00:00
Martin Stjernholm
52d0490d9b Ensure ART module prebuilts aren't used in sanitizer builds.
Change-Id: I128e116e182ba937ecb603f5ba92516a28cb28f9
Test: presubmits
Bug: 172480615
2021-02-11 08:06:43 +00:00
Calin Juravle
95f5213202 Merge "Update the default compiler filter used at boot time" 2021-02-11 02:07:59 +00:00
Yan Yan
57b9916d03 Merge "Add IKE to bcp and remove it from system server classpath" 2021-02-10 18:41:41 +00:00
Treehugger Robot
7b6988c026 Merge "Make common.py python3 compatible" 2021-02-10 18:29:43 +00:00
Bob Badour
dd163df3d0 Merge "Fix license_type. Contains GPL" 2021-02-10 07:03:17 +00:00
Jose "Pepe" Galmes
836c091756 Merge "Implement directed recovery snapshot." 2021-02-09 23:58:28 +00:00
Treehugger Robot
e51dcceae1 Merge "Updates merge_target_files soong_zip to use -r instead of -l." 2021-02-09 23:11:09 +00:00
Kelvin Zhang
645dcb8264 Make common.py python3 compatible
Test: th
Change-Id: Ibe4db0a367b7b8df5eeb7f2a6d0816e8e18bf342
2021-02-09 17:53:09 -05:00
Bob Badour
5feee0e957 Fix license_type. Contains GPL
See: http://go/android-license-checking-v2-lsc

Test: m all

Bug: 151953481
Bug: 151177513
Bug: 67772237

Exempt-From-Owner-Approval: janitorial work
Change-Id: I43f76a40157a912aaab7429225a2bd1fdf6646d6
2021-02-09 14:00:16 -08:00
Treehugger Robot
1975c1ba63 Merge changes from topic "ps 2.0 cp"
* changes:
  update vndk list
  powerstats: PowerStats HAL has been renamed
  Create Power Stats AIDL interface
2021-02-09 19:20:10 +00:00
Daniel Norman
eaf5c1dca2 Updates merge_target_files soong_zip to use -r instead of -l.
This is needed due to output artifacts in the zip that confuse globbing,
such as [.

(Also changes this call to RunAndCheckOutput, which prints the stderror
by default instead of RunAndWait which does not. Removes RunAndWait
which is now unused)

Bug: 179799226
Test: Run merge_target_files to merge two partial builds
Change-Id: Ibf8a5b0c013c9cd8b1e61195d97583f247d97c6f
2021-02-09 11:01:42 -08:00
Jose Galmes
7185c6c500 Implement directed recovery snapshot.
Bug: 177451657
Test: m -j nothing
Change-Id: I902afe71e7577c1c41371f1422512170edf6e492
2021-02-09 07:41:40 -08:00
Treehugger Robot
41f416d326 Merge "Add flag to manually disable vabc" 2021-02-09 01:14:50 +00:00
Treehugger Robot
6c9e319da7 Merge "extract_kernel: make it py2/py3 compatible" 2021-02-08 23:49:15 +00:00
Calin Juravle
b7e744cd82 Update the default compiler filter used at boot time
For the first-boot (happening after upgrades) use verify as quicken is deprecated.

For the usual boot operations use extract instead of the verify. Under normal behaviour all apps should already be optimized (either with the first-boot option, a/b option or in bg-dexopt). This will speed up the boot process in corner cases and reduce resource contention that could make the device janky in at boot time.

Bug: 172114559
Change-Id: I33f204911bdc825bf6731feb5cea7c260382798b
Test: m
2021-02-08 14:25:46 -08:00
Treehugger Robot
a5dcac761f Merge "Turn missing jarjar output files into errors" 2021-02-08 22:00:02 +00:00
Julien Desprez
1514b9a581 Merge "Clean TEST_MAPPING config based on go/a-unit-tests" 2021-02-08 21:25:05 +00:00
Treehugger Robot
c5bbb1ead1 Merge "Remove Use_lmkd_stats_log from build" 2021-02-08 20:58:19 +00:00
Treehugger Robot
7ef7116014 Merge "Keystore 2.0: Disable keystore 2 by default (for now)" 2021-02-08 20:04:38 +00:00
Colin Cross
a1271eb343 Turn missing jarjar output files into errors
Jarjar doesn't exit with a nonzero return code when there is a syntax
error in a rules file and doesn't write the output file.  Without a
nonzero return code ninja prints a warning but continues, which leads
to stale results on incremental builds where the output file already
exists, or delayed errors on clean builds whre the output file didn't
exist.

Delete the output file before running jarjar, and then check if it
exists after running jarjar.

Fixes: 119516143
Test: m out/target/common/obj/JAVA_LIBRARIES/noto-emoji-compat-java_intermediates/classes-jarjar.jar
Change-Id: Ib99167403948ee11f039dd4d2d7e63052bb92136
2021-02-08 10:55:05 -08:00
Ioannis Ilkos
8e568c52ab Remove Use_lmkd_stats_log from build
Use_lmkd_stats_log used to control LMKD_LOG_STATS when compiling lmkd.

However, for newer Android releases, we mandate that lmkd informs statsd of process kills (change id I8cb123b9488fbc6e88863c2f0e75f1422bcd282e)
After aosp/1555318 we compile lmkd with statsd by default, so this setting is a noop.

Change-Id: I91bd08198fe2275fb8aca77ae5ea637df360d416
Test: build
Bug: 177985094
2021-02-08 11:17:55 +00:00
Yo Chiang
ecaa592310 Set PRODUCT_SHIPPING_API_LEVEL in gsi_release.mk
Set PRODUCT_SHIPPING_API_LEVEL to the latest value (instead of empty) so
that GSIs are always built with the latest build system default configs,
such as PRODUCT_FULL_TREBLE := true and
PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE := true.

Bug: 177495407
Test: Presubmit build_test
Change-Id: Iabd67656c5ed1de8327c40f0f9f604841f24764b
2021-02-08 12:45:15 +08:00
Kelvin Zhang
bbfa182995 Add flag to manually disable vabc
Test: ota_from_target_files --disable_vabc
Change-Id: I9ae9ce2c3173909c335708329e787ae45dc5da6b
2021-02-07 10:43:15 -05:00
cfig
791378cda1
extract_kernel: make it py2/py3 compatible
use py3 for AOSP build, while the script itself can be
executed under py2/py3 environment directly.

TEST: extract info from Pixel 4 kernel

Change-Id: I00db6dabb1ff93f0758017a666c476816caefae7
2021-02-07 17:05:53 +08:00
Treehugger Robot
bff5273dd0 Merge "Adding repack_bootimg into otatools.zip" 2021-02-06 08:00:55 +00:00
Janis Danisevskis
a3c5395672 Keystore 2.0: Disable keystore 2 by default (for now)
Test: System starts without keystore 2 running.
Bug: 160623310
Change-Id: I83d54de602a0f70acc91fd8e55b07706e1b4e55b
2021-02-05 14:39:43 -08:00
Colin Cross
effaa0414b Merge "Use RSP file for soong_zip in target_files.zip" 2021-02-05 21:33:37 +00:00
Treehugger Robot
e174dca416 Merge "GSI: enable dynamic partitions" 2021-02-05 18:34:38 +00:00
Jeongik Cha
de2d7b11e6 update vndk list
Bug: 150578172
Test: m
Change-Id: Ifc160fc225883cc226bfcbacc8607f6f96d9501a
Merged-In: I76e73668faf248ca33a37eb221973d2164d9c9b8
2021-02-05 10:05:49 -08:00
Treehugger Robot
530b39afc9 Merge "Add logic to ensure the ART APEXes are built from source in coverage builds." 2021-02-05 13:49:53 +00:00