The boot-debug.img should NOT be release signed and can only be used
if the device is unlocked. Adding a check to prevent the tool from
signing this debuggable boot.img.
See the following for more details about boot-debug.img:
https://android-review.googlesource.com/c/platform/build/+/947857
Bug: 126493225
Test: put a file /force_debuggable into boot.img, checks the following
command fails:
./build/tools/releasetools/sign_target_files_apks \
out/dist/*-target_files-*.zip signed-target_files.zip
Change-Id: Ia5232949cb9582d2b4eaa171d9e9f3fe7317d418
It's a vendor-specific property, which was historically included into
/system/build.prop prior to this change.
Whether a target uses A/B OTA shouldn't affect anything on the system
image, including the `ro.build_ab_update` property. Moving it to vendor
partition will also make it consistent with other A/B specific configs,
such as the `slotselect` flag in device fstab
(/vendor/etc/fstab.$(PRODUCT_PLATFORM)).
Bug: 130516531
Test: Build and flash crosshatch-userdebug. Check /system/build.prop,
/vendor/build.prop and the runtime property.
Change-Id: I927625fbcc02c4a875a1f39850b51576f5ff6c66
This is to migrate sepolicy Makefiles into Soong. For the first part,
file_contexts, hwservice_contexts, property_contexts, and
service_contexts are migrated. Build-time tests for contexts files are
still in Makefile; they will also be done with Soong after porting the
module sepolicy.
The motivation of migrating is based on generating property_contexts
dynamically: if we were to amend contexts files at build time in the
future, it would be nicer to manage them in Soong. To do that, building
contexts files with Soong can be very helpful.
Bug: 127949646
Bug: 129377144
Test: 1) Build blueline-userdebug, flash, and boot.
Test: 2) Build blueline-userdebug with TARGET_FLATTEN_APEX=true, flash,
and boot.
Test: 3) Build aosp_arm-userdebug.
Change-Id: I486f7065207468697320776f726b732077656c6c
Non-installable, non-library modules can still have notice files
attached if they are bundled in an apex module, in which case the
current make setting would generate an error. This change makes it just
ignore them silently if the module is ETC. Other classes will still
trigger an error.
Test: manual build + TreeHugger
Change-Id: Ic7931f990369f744c8de62956a1a0a9c0451d6ab
The two new debugging images adds additional files based on
boot.img and ramdisk.img/ramdisk-recovery.img, respectively.
File /force_debuggable is to trigger special logic in /init to load an
userdebug version of sepolicy and an additional property file from this
ramdisk to allow adb root, if the device is unlocked.
It's intentional to skip signing for boot-debug.img, as it can
only be used if the device is unlocked, where verification error
is allowed.
Those debugging images allows adb root on user build
system.img, vendor.img, product.img, etc. This can facilitate more
automated testings on user builds and is helpful to narrow down the
delta between what's being tested v.s. what's being shipped.
Bug: 126493225
Test: `make dist`, checks both boot-debug.img and ramdisk-debug.img
are in $OUT/ and out/dist.
Test: `make dist`, checks installed-files-ramdisk-debug.{json,txt} are
in out/dist.
Test: `system/core/mkbootimg/unpack_bootimg.py --boot_img $OUT/boot-debug.img`,
checks the extracted out/ramdisk is as expected
Test: Run `gunzip -c ramdisk | cpio -idm` for the ramdisk extracted from
$OUT/boot-debug.img and $OUT/boot.img, respectively.
Then compare the root dirs of both, e.g.,
`diff -rq --no-dereference ./ramdisk ./ramdisk-debug`
Test: `make ramdisk_debug-nodeps` and `make bootimage_debug-nodeps`
Change-Id: I30137c3caef91805d9143d404e5e4d06c0fccc30
This reverts commit a280a66b5a.
/init now switched to read adb_debug.prop from debug ramdisk instead
of GSI or other system.img. No need to keep the file in GSI.
See the following for more details:
https://android-review.googlesource.com/c/platform/system/core/+/946517
Bug: 126493225
Test: tree hugger
Change-Id: I981db8e13216fbe0f066f4d3684ee149b1177d22
The extensions is for OEM. To avoid AOSP code using OEM
extensions mistakenly. GSI denys product to use the extensions
by enabling the following property:
ro.nnapi.extensions.deny_on_product=true
Bug: 129900377
Test: make gsi_arm64-userdebug, check /system/build.prop
Change-Id: Ia679f1f9c108bd5a164c8cdeb1d73f57da755608
This allows update_engine listing the file as a required module,
regardless of the value in AB_OTA_UPDATER.
Bug: 130516531
Test: Build aosp_arm64-userdebug w/o setting AB_OTA_UPDATER. Check that
/system/etc/update_engine/update-payload-key.pub.pem is available.
Change-Id: Ied041aca750e7260402ae8dbf65ff740d0b87205
Bug: 30414428
Test: `m -j dist` with aosp_taimen-userdebug. Check
/system/etc/security/otacerts.zip available under system and
recovery images.
Change-Id: I5abeb2da441fb3e3231e094063c2383eb3807852
Merged-In: I5abeb2da441fb3e3231e094063c2383eb3807852
So that it can be overridden by PRODUCT_PROPERTY_OVERRIDES.
Test: native bridge property is overridden when requested
Bug: 130825973
Bug: 130564502
Change-Id: I8413b9b5b2ac24ac62b6cf22a5f14393420927f5
This variable is used to populate the ro.sf.lcd_density property
in /vendor/build.prop, as well as choosing the correct density
bucket for assets in recovery.
Bug: 118676832
Test: inspect taimen and crosshatch in recovery
Test: adb shell getprop ro.sf.lcd_density
Change-Id: I80cf4d28ecfbae17f1ee206a279e7d9144bd7c05
Merged-In: I80cf4d28ecfbae17f1ee206a279e7d9144bd7c05
(cherry picked from commit 0dc9878af0)
Add all the boot image files necessary of offline inspection and
compilation in a single zip file (boot.zip).
This replaces the previous boot_profiles_jars.zip which contained only the
jar files.
Bug: 130376456
Test: m dist
Change-Id: I25b0c03ee9e7a2c2ff25db406656ce79baff5a46
Merged-In: Ib71c4fcc0d451570d0bb0584745487c54f884fd9
(cherry picked from commit 3dfae3f149)
This simplifies the use case for mixed build users. Instead of having to
remember to call img_from_target_files.py after this script, they can
use this flag to automatically create the IMG package.
Also includes an update to super_empty.img logic. The super_empty.img is
now always created for dynamic-partition builds. The flag now only
controls copying the super_empty.img to a user-provided location.
Bug: 129976345
Test: Ran merge_target_files.py using --output-img and
--output-super-empty and inspected the resulting img zip and
super_empty.img.
Change-Id: Ida602942bb7a6b4b94f4e225640af9104fc9360c
Use codename.fingerprint format for targetSdkVersion if it is unset
in the manifest and UNBUNDLED_BUILD_TARGET_SDK_WITH_API_FINGERPRINT=true.
Test: manual
Bug: 130541924
Change-Id: Ie748d1963ff6f525f8d9e551b73846c3e1c7f9a2
Removing AAPT1 support removed the distinction between unset
LOCAL_USE_AAPT2 and LOCAL_USE_AAPT2 := true, which enabled the
LCOAL_SDK_RES_VERSION setting for some modules that had previously
bypassed it because of LOCAL_USE_AAPT2 := true. The workaround
was too broad, it shouldn't apply if LOCAL_SDK_VERSION is already
set to *current. In particular, if it is core_current to disable
using framework-res.apk completely, then LOCAL_SDK_RES_VERSION
must not be set to current.
Fixes: 130782219
Test: atest android.server.wm.PrereleaseSdkTest
Change-Id: I250d65b1ef66e591f2c9779580df4cc3f0f2b028
Bug: 130787336
Test: m oemaids_header_gen oemaids_headers passwd group
Test: Set TARGET_FS_CONFIG_GEN to a list of paths
Change-Id: I5186b378fea8865f46cfd891420ba576f36e2565
Also start the deprecation for BUILD_HOST_TEST_CONFIG and
BUILD_TARGET_TEST_CONFIG, which have no users.
Bug: 130720555
Bug: 130723115
Bug: 130734993
Test: treehugger
Test: Add entries to DEFAULT_ERROR / OBSOLETE to manually test behavior
Change-Id: Icfdff43a29b6512494d44b9be11d178333505010
AAPT2 is used everywhere now, remove support for AAPT1. Also
removes dpi_specific_apk.mk, it was never updated to use AAPT2
and has been generating bad APKs (resource ID mismatch between
the dex files and the resources) since AAPT2 was made the default
in May 2018 (I9b67fd2a9b3234798b2aac879b5242c2097b3863).
Bug: 80450981
Test: m checkbuild
Change-Id: I2ff768897360ff866dbae5562455bab22be270f7
Merged-In: I2ff768897360ff866dbae5562455bab22be270f7
* changes:
Adds --output-ota flag to enable building the OTA package.
Adds --output-super-empty flag to enable building super_empty.img.
Adds output-dir and output-item-list for copying only certain files.