1# Copyright (C) 2007 The Android Open Source Project 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); 4# you may not use this file except in compliance with the License. 5# You may obtain a copy of the License at 6# 7# http://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, 11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12# See the License for the specific language governing permissions and 13# limitations under the License. 14 15LOCAL_PATH := $(call my-dir) 16 17# Needed by build/make/core/Makefile. Must be consistent with the value in Android.bp. 18RECOVERY_API_VERSION := 3 19RECOVERY_FSTAB_VERSION := 2 20 21# TARGET_RECOVERY_UI_LIB should be one of librecovery_ui_{default,wear,vr,ethernet} or a 22# device-specific module that defines make_device() and the exact RecoveryUI class for the 23# target. It defaults to librecovery_ui_default, which uses ScreenRecoveryUI. 24TARGET_RECOVERY_UI_LIB ?= librecovery_ui_default 25 26# librecovery_ui_ext (shared library) 27# =================================== 28include $(CLEAR_VARS) 29 30LOCAL_MODULE := librecovery_ui_ext 31LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-MIT SPDX-license-identifier-OFL 32LOCAL_LICENSE_CONDITIONS := by_exception_only notice 33LOCAL_NOTICE_FILE := $(LOCAL_PATH)/NOTICE 34 35# LOCAL_MODULE_PATH for shared libraries is unsupported in multiarch builds. 36LOCAL_MULTILIB := first 37 38ifeq ($(TARGET_IS_64_BIT),true) 39LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/system/lib64 40else 41LOCAL_MODULE_PATH := $(TARGET_RECOVERY_ROOT_OUT)/system/lib 42endif 43 44LOCAL_WHOLE_STATIC_LIBRARIES := \ 45 $(TARGET_RECOVERY_UI_LIB) 46 47LOCAL_SHARED_LIBRARIES := \ 48 libbase \ 49 liblog \ 50 librecovery_ui.recovery 51 52include $(BUILD_SHARED_LIBRARY) 53 54# recovery_deps: A phony target that's depended on by `recovery`, which 55# builds additional modules conditionally based on Makefile variables. 56# ====================================================================== 57include $(CLEAR_VARS) 58 59LOCAL_MODULE := recovery_deps 60LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-MIT SPDX-license-identifier-OFL 61LOCAL_LICENSE_CONDITIONS := by_exception_only notice 62LOCAL_NOTICE_FILE := $(LOCAL_PATH)/NOTICE 63 64ifeq ($(TARGET_USERIMAGES_USE_F2FS),true) 65LOCAL_REQUIRED_MODULES += \ 66 make_f2fs.recovery \ 67 sload_f2fs.recovery 68endif 69 70# On A/B devices recovery-persist reads the recovery related file from the persist storage and 71# copies them into /data/misc/recovery. Then, for both A/B and non-A/B devices, recovery-persist 72# parses the last_install file and reports the embedded update metrics. Also, the last_install file 73# will be deteleted after the report. 74LOCAL_REQUIRED_MODULES += recovery-persist 75ifeq ($(BOARD_CACHEIMAGE_PARTITION_SIZE),) 76LOCAL_REQUIRED_MODULES += recovery-refresh 77endif 78 79include $(BUILD_PHONY_PACKAGE) 80 81include \ 82 $(LOCAL_PATH)/updater/Android.mk \ 83