1 # Copyright (c) 2011 Intel Corporation. All Rights Reserved. 2 # 3 # 4 # Permission is hereby granted, free of charge, to any person obtaining a 5 # copy of this software and associated documentation files (the 6 # "Software"), to deal in the Software without restriction, including 7 # without limitation the rights to use, copy, modify, merge, publish, 8 # distribute, sub license, and/or sell copies of the Software, and to 9 # permit persons to whom the Software is furnished to do so, subject to 10 # the following conditions: 11 # 12 # The above copyright notice and this permission notice (including the 13 # next paragraph) shall be included in all copies or substantial portions 14 # of the Software. 15 # 16 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 17 # OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 18 # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. 19 # IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR 20 # ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 21 # TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 22 # SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 23 # 24 25 LOCAL_PATH:= $(call my-dir) 26 27 include $(CLEAR_VARS) 28 29 # pnw_H264.c, pnw_MPEG4.c, pnw_MPEG2.c, pnw_VC1.c, pnw_H263ES.c, tng_H263ES.c, etc. 30 # all use GNU old-style field designator extension. 31 # psb_drv_video.c: comparison of constant 32 with expression of type 'VAProfile' 32 # is always false 33 # pnw_H263ES.c and tng_hostcode.c has implicit conversion 34 # from one enumeration type to another 35 LOCAL_CLANG_CFLAGS += \ 36 -Wno-gnu-designator \ 37 -Wno-tautological-constant-out-of-range-compare \ 38 -Wno-enum-conversion 39 40 LOCAL_CFLAGS := \ 41 -DLINUX -DANDROID -g -Wall -Wno-unused \ 42 -DPSBVIDEO_LOG_ENABLE -DPSBVIDEO_VXD392 \ 43 -DPSBVIDEO_MSVDX_DEC_TILING -DPSBVIDEO_MSVDX_EC 44 45 LOCAL_C_INCLUDES := \ 46 $(call include-path-for, libhardware)/hardware \ 47 $(TARGET_OUT_HEADERS)/libva \ 48 $(TARGET_OUT_HEADERS)/libttm \ 49 $(TARGET_OUT_HEADERS)/libwsbm \ 50 $(TARGET_OUT_HEADERS)/libdrm \ 51 $(TARGET_OUT_HEADERS)/opengles \ 52 $(TARGET_OUT_HEADERS)/pvr \ 53 $(LOCAL_PATH)/hwdefs 54 55 LOCAL_SHARED_LIBRARIES += libdl libdrm libwsbm libcutils \ 56 libutils libbinder libhardware liblog 57 58 LOCAL_SRC_FILES := \ 59 object_heap.c \ 60 psb_buffer.c \ 61 psb_buffer_dm.c \ 62 psb_cmdbuf.c \ 63 psb_drv_video.c \ 64 psb_drv_debug.c \ 65 psb_surface_attrib.c \ 66 psb_output.c \ 67 android/psb_output_android.c \ 68 android/psb_android_glue.cpp \ 69 android/psb_surface_gralloc.c \ 70 android/psb_gralloc.cpp \ 71 psb_surface.c \ 72 psb_overlay.c \ 73 vc1_idx.c \ 74 vc1_vlc.c \ 75 pnw_H264.c \ 76 pnw_MPEG4.c \ 77 pnw_MPEG2.c \ 78 pnw_VC1.c \ 79 pnw_rotate.c \ 80 tng_vld_dec.c \ 81 tng_yuv_processor.c \ 82 tng_VP8.c \ 83 tng_jpegdec.c 84 85 ifneq ($(filter $(TARGET_BOARD_PLATFORM),merrifield moorefield morganfield),) 86 LOCAL_SRC_FILES += \ 87 pnw_H263ES.c \ 88 pnw_H264ES.c \ 89 pnw_MPEG4ES.c \ 90 pnw_cmdbuf.c \ 91 pnw_hostcode.c \ 92 pnw_hostheader.c \ 93 pnw_hostjpeg.c \ 94 pnw_jpeg.c \ 95 tng_ved_scaling.c \ 96 tng_cmdbuf.c \ 97 tng_hostheader.c \ 98 tng_hostcode.c \ 99 tng_picmgmt.c \ 100 tng_hostbias.c \ 101 tng_H264ES.c \ 102 tng_H263ES.c \ 103 tng_MPEG4ES.c \ 104 tng_jpegES.c \ 105 tng_slotorder.c \ 106 tng_hostair.c \ 107 tng_trace.c 108 109 ifeq ($(TARGET_HAS_ISV),true) 110 LOCAL_SRC_FILES += \ 111 vsp_VPP.c \ 112 vsp_cmdbuf.c \ 113 vsp_vp8.c \ 114 vsp_compose.c 115 116 LOCAL_CFLAGS += \ 117 -DPSBVIDEO_MRFL_VPP \ 118 -DPSBVIDEO_VPP_TILING 119 endif 120 121 ifeq ($(TARGET_HAS_VPP),true) 122 LOCAL_SRC_FILES += \ 123 vsp_VPP.c \ 124 vsp_vp8.c \ 125 vsp_cmdbuf.c \ 126 vsp_compose.c 127 endif 128 129 ifeq ($(TARGET_HAS_VPP),true) 130 LOCAL_C_INCLUDES += \ 131 $(TARGET_OUT_HEADERS)/libmedia_utils_vpp 132 endif 133 134 135 ifeq ($(TARGET_HAS_VPP),true) 136 LOCAL_SHARED_LIBRARIES += libvpp_setting 137 LOCAL_CFLAGS += DPSBVIDEO_MRFL_VPP_SETTING 138 endif 139 140 ifeq ($(TARGET_HAS_VPP),true) 141 LOCAL_CFLAGS += \ 142 -DPSBVIDEO_MRFL_VPP -DPSBVIDEO_MRFL \ 143 -DPSBVIDEO_VPP_TILING -DSLICE_HEADER_PARSING 144 else 145 LOCAL_CFLAGS += \ 146 -DPSBVIDEO_MRFL_VPP \ 147 -DPSBVIDEO_MRFL \ 148 -DSLICE_HEADER_PARSING 149 endif 150 151 ifeq ($(TARGET_BOARD_PLATFORM),merrifield) 152 ifeq ($(TARGET_HAS_VPP),true) 153 LOCAL_CFLAGS += -DPSBVIDEO_MRFL_VPP_ROTATE 154 endif 155 endif 156 157 else 158 LOCAL_CFLAGS += \ 159 -DPSBVIDEO_VXD392 -DBAYTRAIL \ 160 -DPSBVIDEO_MSVDX_DEC_TILING -DPSBVIDEO_MSVDX_EC 161 endif 162 163 ifeq ($(TARGET_HAS_MULTIPLE_DISPLAY),true) 164 LOCAL_SRC_FILES += android/psb_mds.cpp 165 LOCAL_CFLAGS += -DTARGET_HAS_MULTIPLE_DISPLAY 166 LOCAL_SHARED_LIBRARIES += libmultidisplay 167 endif 168 LOCAL_CFLAGS += -Werror 169 170 LOCAL_MODULE_TAGS := optional 171 LOCAL_MODULE := pvr_drv_video 172 173 include $(BUILD_SHARED_LIBRARY) 174