1LOCAL_PATH := $(call my-dir) 2 3# 4# OTA Executable 5# 6 7include $(CLEAR_VARS) 8LOCAL_MODULE := otapreopt 9LOCAL_CFLAGS := -Wall -Werror 10 11# Base & ASLR boundaries for boot image creation. 12ifndef LIBART_IMG_HOST_MIN_BASE_ADDRESS_DELTA 13 LOCAL_LIBART_IMG_HOST_MIN_BASE_ADDRESS_DELTA := -0x1000000 14else 15 LOCAL_LIBART_IMG_HOST_MIN_BASE_ADDRESS_DELTA := $(LIBART_IMG_HOST_MIN_BASE_ADDRESS_DELTA) 16endif 17ifndef LIBART_IMG_HOST_MAX_BASE_ADDRESS_DELTA 18 LOCAL_LIBART_IMG_HOST_MAX_BASE_ADDRESS_DELTA := 0x1000000 19else 20 LOCAL_LIBART_IMG_HOST_MAX_BASE_ADDRESS_DELTA := $(LIBART_IMG_HOST_MAX_BASE_ADDRESS_DELTA) 21endif 22LOCAL_CFLAGS += -DART_BASE_ADDRESS=$(LIBART_IMG_HOST_BASE_ADDRESS) 23LOCAL_CFLAGS += -DART_BASE_ADDRESS_MIN_DELTA=$(LOCAL_LIBART_IMG_HOST_MIN_BASE_ADDRESS_DELTA) 24LOCAL_CFLAGS += -DART_BASE_ADDRESS_MAX_DELTA=$(LOCAL_LIBART_IMG_HOST_MAX_BASE_ADDRESS_DELTA) 25 26LOCAL_SRC_FILES := otapreopt.cpp otapreopt_parameters.cpp globals.cpp utils.cpp dexopt.cpp 27LOCAL_HEADER_LIBRARIES := dex2oat_headers 28LOCAL_SHARED_LIBRARIES := \ 29 libbase \ 30 libcrypto \ 31 libcutils \ 32 liblog \ 33 liblogwrap \ 34 libselinux \ 35 libutils \ 36 37LOCAL_STATIC_LIBRARIES := libdiskusage 38LOCAL_CLANG := true 39include $(BUILD_EXECUTABLE) 40 41# OTA slot script 42 43include $(CLEAR_VARS) 44LOCAL_MODULE:= otapreopt_slot 45LOCAL_MODULE_TAGS := optional 46LOCAL_MODULE_CLASS := EXECUTABLES 47LOCAL_SRC_FILES := otapreopt_slot.sh 48LOCAL_INIT_RC := otapreopt.rc 49 50include $(BUILD_PREBUILT) 51 52# OTA postinstall script 53 54include $(CLEAR_VARS) 55LOCAL_MODULE:= otapreopt_script 56LOCAL_MODULE_TAGS := optional 57LOCAL_MODULE_CLASS := EXECUTABLES 58LOCAL_SRC_FILES := otapreopt_script.sh 59 60# Let this depend on otapreopt, the chroot tool and the slot script, so we just have to mention one 61# in a configuration. 62LOCAL_REQUIRED_MODULES := otapreopt otapreopt_chroot otapreopt_slot 63 64include $(BUILD_PREBUILT) 65