-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBoardConfig.mk
74 lines (59 loc) · 2.11 KB
/
BoardConfig.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
#
# Copyright (C) 2022-2023 SHIFT GmbH
#
# SPDX-License-Identifier: Apache-2.0
#
### AVB
# Enable AVB 2.0
BOARD_AVB_ENABLE := true
ifeq ($(WITH_GMS_MAINLINE),true)
PRIVATE_KEY_PATH := vendor/shiftos/private/keys/mainline/avb-4096.pem
else
PRIVATE_KEY_PATH := vendor/shiftos/private/keys/stock/avb-4096.pem
endif
# If private key does not exist, fallback to testkey
ifeq ($(wildcard $(PRIVATE_KEY_PATH)),)
PRIVATE_KEY_PATH := external/avb/test/data/testkey_rsa4096.pem
endif
# AVB - vbmeta
BOARD_AVB_ALGORITHM := SHA256_RSA4096
BOARD_AVB_KEY_PATH := $(PRIVATE_KEY_PATH)
# AVB - vbmeta_system
BOARD_AVB_VBMETA_SYSTEM := system system_ext
BOARD_AVB_VBMETA_SYSTEM_KEY_PATH := $(PRIVATE_KEY_PATH)
BOARD_AVB_VBMETA_SYSTEM_ALGORITHM := SHA256_RSA4096
BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX_LOCATION := 11
# AVB - vbmeta_vendor
BOARD_AVB_VBMETA_VENDOR := odm vendor
BOARD_AVB_VBMETA_VENDOR_KEY_PATH := $(PRIVATE_KEY_PATH)
BOARD_AVB_VBMETA_VENDOR_ALGORITHM := SHA256_RSA4096
BOARD_AVB_VBMETA_VENDOR_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
BOARD_AVB_VBMETA_VENDOR_ROLLBACK_INDEX_LOCATION := 12
# AVB - clear any set flags
BOARD_AVB_MAKE_VBMETA_IMAGE_ARGS :=
#############################################################
# DRM
TARGET_ENABLE_MEDIADRM_64 := true
# Kernel
ifeq ($(TARGET_BUILD_VARIANT),eng)
TARGET_KERNEL_CONFIG := axolotl_eng_defconfig
else
ifeq ($(TARGET_BUILD_VARIANT),userdebug)
TARGET_KERNEL_CONFIG := axolotl_userdebug_defconfig
TARGET_KERNEL_CONFIG += vendor/debugfs.config
else
TARGET_KERNEL_CONFIG := axolotl_user_defconfig
TARGET_KERNEL_CONFIG += vendor/debugfs.config
endif
endif
# Enable console for non-user builds
ifneq ($(TARGET_BUILD_VARIANT),user)
BOARD_KERNEL_CMDLINE += console=ttyMSM0,115200n8 earlycon=msm_geni_serial,0xA84000
endif
# Security patch level
VENDOR_SECURITY_PATCH := $(PLATFORM_SECURITY_PATCH)
# Sepolicy
BOARD_VENDOR_SEPOLICY_DIRS += device/shift/axolotl/shiftos/sepolicy/vendor/automation_setup
# Super
BOARD_BUILD_SUPER_IMAGE_BY_DEFAULT := true