1#AM_CFLAGS = -Wall
2#AM_CFLAGS = -Wundef
3#AM_CFLAGS += -Wstrict-prototypes
4#AM_CFLAGS += -Wno-trigraphs
5#AM_CFLAGS += -Wno-multichar
6
7AM_CPPFLAGS = -D__alignx\(x\)=__attribute__\(\(__aligned__\(x\)\)\)
8AM_CPPFLAGS += -D__align=__alignx
9AM_CPPFLAGS += -Dinline=__inline
10AM_CPPFLAGS += -DIMAGE_APPS_PROC
11AM_CPPFLAGS += -DCDECL
12AM_CPPFLAGS += -DT_ARM
13AM_CPPFLAGS += -DNO_ARM_CLZ
14AM_CPPFLAGS += -D_ANDROID_
15AM_CPPFLAGS += -UENABLE_DEBUG_LOW
16AM_CPPFLAGS += -DENABLE_DEBUG_HIGH
17AM_CPPFLAGS += -DENABLE_DEBUG_ERROR
18AM_CPPFLAGS += -UINPUT_BUFFER_LOG
19AM_CPPFLAGS += -UOUTPUT_BUFFER_LOG
20AM_CPPFLAGS += -Werror
21AM_CPPFLAGS += -D_ANDROID_ICS_
22AM_CPPFLAGS += -DUSE_ION
23AM_CPPFLAGS += -Wno-enum-compare
24#AM_CPPFLAGS += "-include stdint.h"
25AM_CPPFLAGS += "-Dstrlcpy=g_strlcpy"
26AM_CPPFLAGS += "-Dstrlcat=g_strlcat"
27AM_CPPFLAGS += "-std=c++11"
28AM_CPPFLAGS += -Wno-undef
29AM_CPPFLAGS += -Wno-multichar
30AM_CPPFLAGS += -g -O3
31AM_CPPFLAGS += "-DHAVE_ANDROID_OS"
32AM_CPPFLAGS += "-DUSE_CAMERA_METABUFFER_UTILS"
33
34if USE_GLIB
35AM_CPPFLAGS += -D_USE_GLIB_
36endif
37
38if TARGET_MSM8610
39AM_CPPFLAGS += -D_MSM8610_
40endif
41
42if TARGETS_THAT_SUPPORT_PQ
43AM_CPPFLAGS += -D_PQ_
44endif
45
46if TARGETS_THAT_USE_FLAG_MSM8226
47AM_CPPFLAGS += -D_MSM8226_
48endif
49
50if TARGET_USES_MEDIA_EXTENSIONS
51AM_CPPFLAGS += -DUSE_NATIVE_HANDLE_SOURCE
52endif
53
54if MASTER_SIDE_CP_TARGET_LIST
55AM_CPPFLAGS += -DMASTER_SIDE_CP
56endif
57
58AM_CPPFLAGS += -I$(top_srcdir)/mm-video-v4l2/vidc/common/inc/
59AM_CPPFLAGS += -I$(top_srcdir)/mm-video-v4l2/vidc/venc/inc/
60AM_CPPFLAGS += -I$(top_srcdir)/libc2dcolorconvert/
61AM_CPPFLAGS += -I$(top_srcdir)/mm-core/inc/
62AM_CPPFLAGS += -I$(top_srcdir)/mm-core/src/common/
63AM_CPPFLAGS += -I$(top_srcdir)/libstagefrighthw/
64AM_CPPFLAGS += -I$(top_srcdir)/libplatformconfig/
65AM_CPPFLAGS += -I$(WORKSPACE)/graphics/libdrm/freedreno/kgsl/
66AM_CPPFLAGS += -I$(WORKSPACE)/display/display-hal/gralloc/
67AM_CPPFLAGS += -I$(WORKSPACE)/display/display-hal/libqdutils/
68AM_CPPFLAGS += -I$(WORKSPACE)/hardware/libhardware/include/
69AM_CPPFLAGS += -I${WORKSPACE}/frameworks/native/include/
70sources = src/omx_video_base.cpp
71sources += src/omx_video_encoder.cpp
72sources += src/video_encoder_device_v4l2.cpp
73sources += $(top_srcdir)/mm-video-v4l2/vidc/common/src/vidc_common.cpp
74sources += $(top_srcdir)/mm-video-v4l2/vidc/common/src/vidc_vendor_extensions.cpp
75
76lib_LTLIBRARIES = libOmxVenc.la
77libOmxVenc_la_SOURCES = $(sources)
78libOmxVenc_la_CFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) -fPIC
79libOmxVenc_la_LDFLAGS = -module -shared -avoid-version
80libOmxVenc_la_LDFLAGS += -lstdc++ -lpthread -llog -lutils -lcutils -lglib-2.0 -lbase -ldl -lpthread -lion
81
82libOmxVenc_la_LDFLAGS += -L$(top_builddir)/libc2dcolorconvert  -L$(top_builddir)/libplatformconfig
83libOmxVenc_la_LDFLAGS += -lc2dcolorconvert -lplatformconfig -larbitrarybytes
84