vendor/lineage: Hookup TARGET_USES_MTK_APNS_CONF & copy mtk apns from tetris
Description
Currently, APN configurations are maintained separately in multiple device repos.
It will be ideal to keep it commonized, to avoid multiple issues regarding APNs for each device.
Screenshots
Technical details
Introduce TARGET_USES_MTK_APNS_CONF variable to control which apn gets copied to product/etc/apns-conf.xml.
Existing behavior of copying apns is not affected unless TARGET_USES_MTK_APNS_CONF is set in BoardConfig.mk.
When TARGET_USES_MTK_APNS_CONF := true is set in BoardConfig.mk, mtk-specific apn config is copied.
When TARGET_USES_MTK_APNS_CONF := false is set in BoardConfig.mk, generic apn config is copied.
When TARGET_USES_MTK_APNS_CONF is not set in BoardConfig.mk, generic apn config is copied.
NOTE:
generic config refers to vendor/lineage/prebuilt/common/etc/apns-conf.xml.
mtk-specific config refers to vendor/lineage/prebuilt/common/etc/apns-conf-mtk.xml (introduced in this PR).
Tests
- Build a14 for device with
TARGET_USES_MTK_APNS_CONF := trueset inBoardConfig.mkand checkproduct/etc/apns-conf.xml.-
product/etc/apns-conf.xmlshould containmtk-specificapn config.
-
- Build a14 for device with
TARGET_USES_MTK_APNS_CONF := falseset inBoardConfig.mkand checkproduct/etc/apns-conf.xml.-
product/etc/apns-conf.xmlshould containgenericapn config.
-
- Build a14 for device with
TARGET_USES_MTK_APNS_CONFnot set inBoardConfig.mkand checkproduct/etc/apns-conf.xml.-
product/etc/apns-conf.xmlshould containgenericapn config.
-
Issues
https://gitlab.e.foundation/e/devices/backlog/-/issues/1410