Ethan Yonker | c798c9c | 2015-10-09 11:15:26 -0500 | [diff] [blame] | 1 | LOCAL_PATH := $(call my-dir) |
| 2 | include $(CLEAR_VARS) |
| 3 | |
| 4 | LOCAL_SRC_FILES := graphics_overlay.c events.c resources.c |
| 5 | ifneq ($(BOARD_CUSTOM_GRAPHICS),) |
| 6 | LOCAL_SRC_FILES += $(BOARD_CUSTOM_GRAPHICS) |
| 7 | else |
| 8 | LOCAL_SRC_FILES += graphics.c |
| 9 | endif |
| 10 | |
| 11 | LOCAL_C_INCLUDES +=\ |
| 12 | external/libpng \ |
| 13 | external/zlib \ |
| 14 | system/core/include/pixelflinger |
| 15 | |
| 16 | ifeq ($(TW_TARGET_USES_QCOM_BSP), true) |
| 17 | LOCAL_CFLAGS += -DMSM_BSP |
| 18 | ifeq ($(TARGET_PREBUILT_KERNEL),) |
| 19 | LOCAL_ADDITIONAL_DEPENDENCIES := $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr |
| 20 | LOCAL_C_INCLUDES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include |
| 21 | else |
| 22 | ifeq ($(TARGET_CUSTOM_KERNEL_HEADERS),) |
| 23 | LOCAL_C_INCLUDES += $(commands_recovery_local_path)/minui/include |
| 24 | else |
| 25 | LOCAL_C_INCLUDES += $(TARGET_CUSTOM_KERNEL_HEADERS) |
| 26 | endif |
| 27 | endif |
| 28 | else |
| 29 | LOCAL_C_INCLUDES += $(commands_recovery_local_path)/minui/include |
| 30 | endif |
| 31 | |
| 32 | ifeq ($(TW_NEW_ION_HEAP), true) |
| 33 | LOCAL_CFLAGS += -DNEW_ION_HEAP |
| 34 | endif |
| 35 | |
| 36 | LOCAL_STATIC_LIBRARY := libpng |
| 37 | LOCAL_WHOLE_STATIC_LIBRARIES := libpixelflinger_static |
| 38 | LOCAL_MODULE := libminui |
| 39 | |
| 40 | # This used to compare against values in double-quotes (which are just |
| 41 | # ordinary characters in this context). Strip double-quotes from the |
| 42 | # value so that either will work. |
| 43 | |
Kra1o5 | 7756859 | 2015-10-14 18:09:54 +0200 | [diff] [blame] | 44 | ifeq ($(subst ",,$(TARGET_RECOVERY_PIXEL_FORMAT)),RGBA_8888) |
| 45 | LOCAL_CFLAGS += -DRECOVERY_RGBA |
| 46 | endif |
Ethan Yonker | c798c9c | 2015-10-09 11:15:26 -0500 | [diff] [blame] | 47 | ifeq ($(subst ",,$(TARGET_RECOVERY_PIXEL_FORMAT)),RGBX_8888) |
| 48 | LOCAL_CFLAGS += -DRECOVERY_RGBX |
| 49 | endif |
| 50 | ifeq ($(subst ",,$(TARGET_RECOVERY_PIXEL_FORMAT)),BGRA_8888) |
| 51 | LOCAL_CFLAGS += -DRECOVERY_BGRA |
| 52 | endif |
| 53 | |
| 54 | ifneq ($(TARGET_RECOVERY_OVERSCAN_PERCENT),) |
| 55 | LOCAL_CFLAGS += -DOVERSCAN_PERCENT=$(TARGET_RECOVERY_OVERSCAN_PERCENT) |
| 56 | else |
| 57 | LOCAL_CFLAGS += -DOVERSCAN_PERCENT=0 |
| 58 | endif |
| 59 | |
| 60 | ifneq ($(TW_BRIGHTNESS_PATH),) |
| 61 | LOCAL_CFLAGS += -DTW_BRIGHTNESS_PATH=\"$(TW_BRIGHTNESS_PATH)\" |
| 62 | endif |
| 63 | ifneq ($(TW_MAX_BRIGHTNESS),) |
| 64 | LOCAL_CFLAGS += -DTW_MAX_BRIGHTNESS=$(TW_MAX_BRIGHTNESS) |
| 65 | else |
| 66 | LOCAL_CFLAGS += -DTW_MAX_BRIGHTNESS=255 |
| 67 | endif |
| 68 | ifneq ($(TW_NO_SCREEN_BLANK),) |
| 69 | LOCAL_CFLAGS += -DTW_NO_SCREEN_BLANK |
| 70 | endif |
| 71 | ifneq ($(BOARD_USE_CUSTOM_RECOVERY_FONT),) |
| 72 | LOCAL_CFLAGS += -DBOARD_USE_CUSTOM_RECOVERY_FONT=$(BOARD_USE_CUSTOM_RECOVERY_FONT) |
| 73 | endif |
| 74 | include $(BUILD_STATIC_LIBRARY) |
| 75 | |
| 76 | include $(CLEAR_VARS) |
| 77 | |
| 78 | LOCAL_SRC_FILES := graphics_overlay.c events.c resources.c |
| 79 | ifneq ($(BOARD_CUSTOM_GRAPHICS),) |
| 80 | LOCAL_SRC_FILES += $(BOARD_CUSTOM_GRAPHICS) |
| 81 | else |
| 82 | LOCAL_SRC_FILES += graphics.c |
| 83 | endif |
| 84 | |
| 85 | ifeq ($(TW_TARGET_USES_QCOM_BSP), true) |
| 86 | LOCAL_CFLAGS += -DMSM_BSP |
| 87 | ifeq ($(TARGET_PREBUILT_KERNEL),) |
| 88 | LOCAL_ADDITIONAL_DEPENDENCIES := $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr |
| 89 | LOCAL_C_INCLUDES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include |
| 90 | else |
| 91 | ifeq ($(TARGET_CUSTOM_KERNEL_HEADERS),) |
| 92 | LOCAL_C_INCLUDES += $(commands_recovery_local_path)/minui/include |
| 93 | else |
| 94 | LOCAL_C_INCLUDES += $(TARGET_CUSTOM_KERNEL_HEADERS) |
| 95 | endif |
| 96 | endif |
| 97 | else |
| 98 | LOCAL_C_INCLUDES += $(commands_recovery_local_path)/minui/include |
| 99 | endif |
| 100 | |
| 101 | LOCAL_C_INCLUDES +=\ |
| 102 | external/libpng\ |
| 103 | external/zlib |
| 104 | |
| 105 | LOCAL_MODULE := libminui |
| 106 | |
| 107 | LOCAL_ARM_MODE:= arm |
| 108 | LOCAL_SHARED_LIBRARIES := libpng libpixelflinger |
| 109 | # This used to compare against values in double-quotes (which are just |
| 110 | # ordinary characters in this context). Strip double-quotes from the |
| 111 | # value so that either will work. |
| 112 | |
| 113 | ifeq ($(subst ",,$(TARGET_RECOVERY_PIXEL_FORMAT)),RGBX_8888) |
| 114 | LOCAL_CFLAGS += -DRECOVERY_RGBX |
| 115 | endif |
| 116 | ifeq ($(subst ",,$(TARGET_RECOVERY_PIXEL_FORMAT)),BGRA_8888) |
| 117 | LOCAL_CFLAGS += -DRECOVERY_BGRA |
| 118 | endif |
| 119 | |
| 120 | ifneq ($(TARGET_RECOVERY_OVERSCAN_PERCENT),) |
| 121 | LOCAL_CFLAGS += -DOVERSCAN_PERCENT=$(TARGET_RECOVERY_OVERSCAN_PERCENT) |
| 122 | else |
| 123 | LOCAL_CFLAGS += -DOVERSCAN_PERCENT=0 |
| 124 | endif |
| 125 | |
| 126 | ifneq ($(TW_BRIGHTNESS_PATH),) |
| 127 | LOCAL_CFLAGS += -DTW_BRIGHTNESS_PATH=\"$(TW_BRIGHTNESS_PATH)\" |
| 128 | endif |
| 129 | ifneq ($(TW_MAX_BRIGHTNESS),) |
| 130 | LOCAL_CFLAGS += -DTW_MAX_BRIGHTNESS=$(TW_MAX_BRIGHTNESS) |
| 131 | else |
| 132 | LOCAL_CFLAGS += -DTW_MAX_BRIGHTNESS=255 |
| 133 | endif |
| 134 | ifneq ($(TW_NO_SCREEN_BLANK),) |
| 135 | LOCAL_CFLAGS += -DTW_NO_SCREEN_BLANK |
| 136 | endif |
| 137 | ifneq ($(BOARD_USE_CUSTOM_RECOVERY_FONT),) |
| 138 | LOCAL_CFLAGS += -DBOARD_USE_CUSTOM_RECOVERY_FONT=$(BOARD_USE_CUSTOM_RECOVERY_FONT) |
| 139 | endif |
| 140 | |
| 141 | LOCAL_CFLAGS += -DFASTMMI_FEATURE |
| 142 | |
| 143 | include $(BUILD_SHARED_LIBRARY) |