Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0c3ad80f authored by Edward Savage-Jones's avatar Edward Savage-Jones Committed by Yurii Zubrytskyi
Browse files

Allow packages to be enabled depending on sku value

This change allows packages to be enabled on boot depending
on the sku of the device.  This enables the same product image
to be used on different skus.

Example:
Packages are listed here in a disabled state:
/product/etc/sysconfig/disabled-in-sku.xml
<?xml version="1.0" encoding="utf-8"?>
<config>
    <disabled-in-sku package="com.sony.product1.app"/>
    <disabled-in-sku package="com.sony.product2.app"/>
</config>

Then enabled depending on the sku values read from
"ro.boot.hardware.sku"

e.g. an sku of '00001':
/product/etc/sysconfig/sku_00001/enabled-in-sku-override.xml
<?xml version="1.0" encoding="utf-8"?>
<config>
    <enabled-in-sku-override package="com.sony.product2.app"/>
</config>

Status of apps after customisation:
product2 app - enabled
product1 app - disabled and not visible to PackageManager

Bug: 376275452
Test: atest FrameworksServicesTests:com.android.server.systemconfig.SystemConfigTest
Change-Id: Id1418beda7e264cab90086836c32785341fb5aac
parent 238801c3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment