Skip to content

Commit

Permalink
Add Android 14 related build flags
Browse files Browse the repository at this point in the history
Tracked-On: OAM-112683
Signed-off-by: Tanuj Tekriwal <[email protected]>
  • Loading branch information
tanujtekriwal authored and SaliniVenate committed Oct 16, 2023
1 parent 5ffc803 commit 91c8cbc
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions mfx_omx_defs.mk
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
MFX_OMX_CFLAGS := -DANDROID

# Android version preference:
ifneq ($(filter 14 14.% U% ,$(PLATFORM_VERSION)),)
MFX_ANDROID_VERSION:= MFX_U
endif
ifneq ($(filter 12 12.% S ,$(PLATFORM_VERSION)),)
MFX_ANDROID_VERSION:= MFX_S
endif
Expand Down Expand Up @@ -61,7 +64,7 @@ MFX_OMX_CFLAGS += \

ifeq ($(BOARD_USES_GRALLOC1),true)
MFX_OMX_CFLAGS += -DMFX_OMX_USE_GRALLOC_1
ifneq ($(filter MFX_P MFX_Q MFX_R MFX_S,$(MFX_ANDROID_VERSION)),)
ifneq ($(filter MFX_P MFX_Q MFX_R MFX_S MFX_U,$(MFX_ANDROID_VERSION)),)
# plugins should use PRIME buffer descriptor since Android P
MFX_OMX_CFLAGS += -DMFX_OMX_USE_PRIME
endif
Expand Down Expand Up @@ -94,7 +97,7 @@ ifneq ($(filter $(MFX_ANDROID_VERSION), MFX_O),)
MFX_OMX_CFLAGS_LIBVA += -DANDROID_O
endif

ifneq ($(filter $(MFX_ANDROID_VERSION), MFX_Q MFX_R MFX_S),)
ifneq ($(filter $(MFX_ANDROID_VERSION), MFX_Q MFX_R MFX_S MFX_U),)
# HDR10 support on Android Q
MFX_OMX_CFLAGS += -DHEVC10HDR_SUPPORT
MFX_OMX_CFLAGS += -DENABLE_READ_SEI
Expand All @@ -113,15 +116,15 @@ MFX_OMX_INCLUDES_LIBVA := $(TARGET_OUT_HEADERS)/libva
MFX_OMX_HEADER_LIBRARIES := libmfx_headers

# Setting usual imported headers
ifneq ($(filter MFX_O_MR1 MFX_P MFX_Q MFX_R MFX_S,$(MFX_ANDROID_VERSION)),)
ifneq ($(filter MFX_O_MR1 MFX_P MFX_Q MFX_R MFX_S MFX_U,$(MFX_ANDROID_VERSION)),)
MFX_OMX_HEADER_LIBRARIES += \
media_plugin_headers \
libnativebase_headers \
libui_headers \
libhardware_headers
endif

ifneq ($(filter MFX_P MFX_Q MFX_R MFX_S,$(MFX_ANDROID_VERSION)),)
ifneq ($(filter MFX_P MFX_Q MFX_R MFX_S MFX_U,$(MFX_ANDROID_VERSION)),)
MFX_OMX_HEADER_LIBRARIES += \
libbase_headers
endif
Expand Down

0 comments on commit 91c8cbc

Please sign in to comment.