blob: 3bd61f50791fd704c4135af5b6918826a8466801 [file] [log] [blame]
Alexander Martinze925b6f2022-04-08 08:52:53 +02001#
2# Copyright (C) 2022 SHIFT GmbH
3#
4# SPDX-License-Identifier: Apache-2.0
5#
6
Alexander Martinzcc0b7202022-05-31 10:20:59 +02007### AVB
8
Alexander Martinzd1974742023-01-04 22:34:09 +01009#ifeq ($(WITH_GMS_MAINLINE),true)
10# PRIVATE_KEY_PATH := vendor/shiftos/private/keys/mainline/avb-4096.pem
11#else
Alexander Martinzcc0b7202022-05-31 10:20:59 +020012 PRIVATE_KEY_PATH := vendor/shiftos/private/keys/stock/avb-4096.pem
Alexander Martinzd1974742023-01-04 22:34:09 +010013#endif
Alexander Martinzcc0b7202022-05-31 10:20:59 +020014
15# If private key does not exist, fallback to testkey
16ifeq ($(wildcard $(PRIVATE_KEY_PATH)),)
17 PRIVATE_KEY_PATH := external/avb/test/data/testkey_rsa4096.pem
18endif
19
20# AVB - vbmeta
21BOARD_AVB_ALGORITHM := SHA256_RSA4096
22BOARD_AVB_KEY_PATH := $(PRIVATE_KEY_PATH)
23
24# AVB - vbmeta_system
25BOARD_AVB_VBMETA_SYSTEM := system system_ext
26BOARD_AVB_VBMETA_SYSTEM_KEY_PATH := $(PRIVATE_KEY_PATH)
27BOARD_AVB_VBMETA_SYSTEM_ALGORITHM := SHA256_RSA4096
28BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
29BOARD_AVB_VBMETA_SYSTEM_ROLLBACK_INDEX_LOCATION := 11
30
31# AVB - vbmeta_vendor
32BOARD_AVB_VBMETA_VENDOR := vendor
33BOARD_AVB_VBMETA_VENDOR_KEY_PATH := $(PRIVATE_KEY_PATH)
34BOARD_AVB_VBMETA_VENDOR_ALGORITHM := SHA256_RSA4096
35BOARD_AVB_VBMETA_VENDOR_ROLLBACK_INDEX := $(PLATFORM_SECURITY_PATCH_TIMESTAMP)
36BOARD_AVB_VBMETA_VENDOR_ROLLBACK_INDEX_LOCATION := 12
37
38# AVB - clear any set flags
39BOARD_AVB_MAKE_VBMETA_IMAGE_ARGS :=
40
41#############################################################
42
Alexander Martinzb6fc4182022-12-22 00:04:56 +010043# DRM
44TARGET_ENABLE_MEDIADRM_64 := true
45
Alexander Martinz97f727f2022-04-08 10:01:35 +020046# Kernel
Alexander Martinze925b6f2022-04-08 08:52:53 +020047ifeq ($(TARGET_BUILD_VARIANT),eng)
48 TARGET_KERNEL_CONFIG := axolotl_eng_defconfig
49else
50 ifeq ($(TARGET_BUILD_VARIANT),userdebug)
51 TARGET_KERNEL_CONFIG := axolotl_userdebug_defconfig
52 else
53 TARGET_KERNEL_CONFIG := axolotl_user_defconfig
54 endif
55endif
Alexander Martinzb801a9b2022-06-01 09:39:48 +020056
57# Security patch level
58VENDOR_SECURITY_PATCH := $(PLATFORM_SECURITY_PATCH)