1ifneq ($(BUILD_TINY_ANDROID),true) 2 3LOCAL_PATH:= $(call my-dir) 4include $(CLEAR_VARS) 5 6OMXCORE_CFLAGS := -g -O3 -DVERBOSE 7OMXCORE_CFLAGS += -O0 -fno-inline -fno-short-enums 8OMXCORE_CFLAGS += -D_ANDROID_ 9OMXCORE_CFLAGS += -U_ENABLE_QC_MSG_LOG_ 10 11ifeq ($(VIDC_STUB_HAL),true) 12OMXCORE_CFLAGS += -DVIDC_STUB_HAL 13endif 14 15#=============================================================================== 16# Figure out the targets 17#=============================================================================== 18 19MPEGH_TARGET_LIST := kona lito bengal 20ifeq ($(call is-board-platform-in-list, $(MPEGH_TARGET_LIST)), true) 21OMXCORE_CFLAGS += -DAUDIO_MPEGH_ENABLED 22endif 23 24ifeq ($(filter $(TARGET_BOARD_PLATFORM), bengal),$(TARGET_BOARD_PLATFORM)) 25OMXCORE_CFLAGS += -D_BENGAL_ 26else ifeq ($(filter $(TARGET_BOARD_PLATFORM), $(MSMSTEPPE)),$(TARGET_BOARD_PLATFORM)) 27OMXCORE_CFLAGS += -D_STEPPE_ 28else 29OMXCORE_CFLAGS += -D_DEFAULT_ 30endif 31 32ifeq ($(call is-platform-sdk-version-at-least,27),true) # O-MR1 33OMXCORE_CFLAGS += -D_ANDROID_O_MR1_DIVX_CHANGES 34endif 35 36#=============================================================================== 37# Deploy the headers that can be exposed 38#=============================================================================== 39 40LOCAL_COPY_HEADERS_TO := mm-core/omxcore 41LOCAL_COPY_HEADERS := inc/OMX_Audio.h 42LOCAL_COPY_HEADERS += inc/OMX_Component.h 43LOCAL_COPY_HEADERS += inc/OMX_ContentPipe.h 44LOCAL_COPY_HEADERS += inc/OMX_Core.h 45LOCAL_COPY_HEADERS += inc/OMX_Image.h 46LOCAL_COPY_HEADERS += inc/OMX_Index.h 47LOCAL_COPY_HEADERS += inc/OMX_IVCommon.h 48LOCAL_COPY_HEADERS += inc/OMX_Other.h 49LOCAL_COPY_HEADERS += inc/OMX_QCOMExtns.h 50LOCAL_COPY_HEADERS += inc/OMX_Types.h 51LOCAL_COPY_HEADERS += inc/OMX_Video.h 52LOCAL_COPY_HEADERS += inc/qc_omx_common.h 53LOCAL_COPY_HEADERS += inc/qc_omx_component.h 54LOCAL_COPY_HEADERS += inc/qc_omx_msg.h 55LOCAL_COPY_HEADERS += inc/QOMX_AudioExtensions.h 56LOCAL_COPY_HEADERS += inc/QOMX_AudioIndexExtensions.h 57LOCAL_COPY_HEADERS += inc/OMX_CoreExt.h 58LOCAL_COPY_HEADERS += inc/QOMX_CoreExtensions.h 59LOCAL_COPY_HEADERS += inc/QOMX_FileFormatExtensions.h 60LOCAL_COPY_HEADERS += inc/QOMX_IVCommonExtensions.h 61LOCAL_COPY_HEADERS += inc/QOMX_SourceExtensions.h 62LOCAL_COPY_HEADERS += inc/QOMX_VideoExtensions.h 63LOCAL_COPY_HEADERS += inc/OMX_IndexExt.h 64LOCAL_COPY_HEADERS += inc/OMX_VideoExt.h 65LOCAL_COPY_HEADERS += inc/QOMX_StreamingExtensions.h 66LOCAL_COPY_HEADERS += inc/QCMediaDefs.h 67LOCAL_COPY_HEADERS += inc/QCMetaData.h 68 69#=============================================================================== 70# LIBRARY for Android apps 71#=============================================================================== 72 73LOCAL_C_INCLUDES := $(LOCAL_PATH)/src/common 74LOCAL_C_INCLUDES += $(QCOM_MEDIA_ROOT)/libplatformconfig 75 76LOCAL_HEADER_LIBRARIES := \ 77 libutils_headers \ 78 libomxcore_headers 79 80LOCAL_EXPORT_HEADER_LIBRARY_HEADERS := libomxcore_headers 81 82ifeq ($(TARGET_ENABLE_VIDC_INTSAN), true) 83LOCAL_SANITIZE := integer_overflow 84ifeq ($(TARGET_ENABLE_VIDC_INTSAN_DIAG), true) 85$(warning INTSAN_DIAG_ENABLED) 86LOCAL_SANITIZE_DIAG := integer_overflow 87endif 88endif 89 90LOCAL_PRELINK_MODULE := false 91LOCAL_MODULE := libOmxCore 92LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD SPDX-license-identifier-MIT 93LOCAL_LICENSE_CONDITIONS := notice 94LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../NOTICE 95LOCAL_MODULE_TAGS := optional 96LOCAL_VENDOR_MODULE := true 97LOCAL_SHARED_LIBRARIES := liblog libdl libcutils 98ifeq ($(call is-board-platform-in-list, $(MSM_VIDC_TARGET_LIST)),true) 99ifeq ($(VIDC_STUB_HAL),false) 100LOCAL_SHARED_LIBRARIES += libplatformconfig 101endif 102endif 103LOCAL_CFLAGS := $(OMXCORE_CFLAGS) 104 105LOCAL_SRC_FILES := src/common/omx_core_cmp.cpp 106LOCAL_SRC_FILES += src/common/qc_omx_core.c 107ifneq (,$(filter lito bengal kona $(MSMSTEPPE),$(TARGET_BOARD_PLATFORM))) 108LOCAL_SRC_FILES += src/registry_table_android.c 109else 110LOCAL_SRC_FILES += src/default/qc_registry_table_android.c 111endif 112 113include $(BUILD_SHARED_LIBRARY) 114 115#=============================================================================== 116# LIBRARY for command line test apps 117#=============================================================================== 118 119include $(CLEAR_VARS) 120 121LOCAL_C_INCLUDES := $(LOCAL_PATH)/src/common 122LOCAL_C_INCLUDES += $(QCOM_MEDIA_ROOT)/libplatformconfig 123 124LOCAL_HEADER_LIBRARIES := \ 125 libutils_headers \ 126 libomxcore_headers 127 128LOCAL_EXPORT_HEADER_LIBRARY_HEADERS := libomxcore_headers 129 130LOCAL_PRELINK_MODULE := false 131LOCAL_MODULE := libmm-omxcore 132LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD SPDX-license-identifier-MIT 133LOCAL_LICENSE_CONDITIONS := notice 134LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../NOTICE 135LOCAL_MODULE_TAGS := optional 136LOCAL_VENDOR_MODULE := true 137LOCAL_SHARED_LIBRARIES := liblog libdl libcutils 138ifeq ($(call is-board-platform-in-list, $(MSM_VIDC_TARGET_LIST)),true) 139ifeq ($(VIDC_STUB_HAL),false) 140LOCAL_SHARED_LIBRARIES += libplatformconfig 141endif 142endif 143LOCAL_CFLAGS := $(OMXCORE_CFLAGS) 144 145ifeq ($(TARGET_ENABLE_VIDC_INTSAN), true) 146LOCAL_SANITIZE := integer_overflow 147ifeq ($(TARGET_ENABLE_VIDC_INTSAN_DIAG), true) 148$(warning INTSAN_DIAG_ENABLED) 149LOCAL_SANITIZE_DIAG := integer_overflow 150endif 151endif 152 153LOCAL_SRC_FILES := src/common/omx_core_cmp.cpp 154LOCAL_SRC_FILES += src/common/qc_omx_core.c 155ifneq (,$(filter lito bengal kona $(MSMSTEPPE),$(TARGET_BOARD_PLATFORM))) 156LOCAL_SRC_FILES += src/$(MM_CORE_TARGET)/registry_table.c 157else 158LOCAL_SRC_FILES += src/$(MM_CORE_TARGET)/default/qc_registry_table.c 159endif 160 161include $(BUILD_SHARED_LIBRARY) 162 163include $(CLEAR_VARS) 164 165LOCAL_MODULE := libomxcore_headers 166LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD SPDX-license-identifier-MIT 167LOCAL_LICENSE_CONDITIONS := notice 168LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../NOTICE 169LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/inc 170LOCAL_VENDOR_MODULE := true 171 172include $(BUILD_HEADER_LIBRARY) 173 174endif #BUILD_TINY_ANDROID 175