The test also runs on soong-only build. "KATI only" does not make sense and makes confusion. Replace them with PRODUCT_PACKAGES to make it clear to understand. Bug: 455671267 Test: m Change-Id: I5a2f6f9fefc0590c29269ad6d32d9d4b25f0b10c
Resolving System Image File List Differences
The Android build system uses the file_list_diff tool to ensure consistency
between the lists of installed files in system images defined by Kati and Soong.
This check is crucial when transitioning to Soong-defined system images. If the
tool detects any discrepancies, the build will fail.
This document helps you understand and resolve the reported errors. There are
two main types of errors: files present only in the Kati-defined image
(PRODUCT_PACKAGES) and files present only in the Soong-defined image
(Handwritten android_system_image module in Android.bp).
Understanding and Fixing Errors
Files from PRODUCT_PACKAGES that are missing in the Soong definition
This error indicates that certain system modules are included via
PRODUCT_PACKAGES in your device's Makefiles (.mk files) but are not
explicitly defined within the android_system_image module (or its
dependencies) in Android.bp.
To resolve this:
- Default System Modules: If the module is defined in a common system
Makefile (like
base_system.mk,generic_system.mk, etc.), ensure it's listed in thesystem_image_defaultsmodule withinbuild/make/target/product/generic/Android.bp. - Device-Specific Modules: For modules specific to your device, add them to
the relevant
android_system_imagemodule defined inPRODUCT_SOONG_DEFINED_SYSTEM_IMAGEfor your target.
Files in the Soong definition that are missing from PRODUCT_PACKAGES
This error means that certain system modules are present in the Soong-defined
system image (specified by PRODUCT_SOONG_DEFINED_SYSTEM_IMAGE) but are not
included in the PRODUCT_PACKAGES list for your target.
To resolve this:
- Remove Incorrect Modules: If these modules shouldn't be part of the system
image, remove them from the
android_system_imagemodule definition. - Add Missing Modules to Makefiles: If these modules are indeed required,
add them to the appropriate
.mkfiles, following the guidance in the previous section to ensure they are correctly included in both the Kati and Soong definitions.