1LOCAL_PATH:= $(call my-dir)
2
3# b/31559947, Some files caused clang-analyzer-* checks to segmentation fault.
4common_local_tidy_checks := -clang-analyzer-*
5include $(CLEAR_VARS)
6
7LOCAL_TIDY_CHECKS := $(common_local_tidy_checks)
8LOCAL_MODULE := libcxcore
9LOCAL_MODULE_TAGS := optional
10
11LOCAL_C_INCLUDES := \
12        $(LOCAL_PATH)/cxcore/include
13LOCAL_CFLAGS := $(LOCAL_C_INCLUDES:%=-I%)
14
15LOCAL_CFLAGS += -Wno-unused-parameter
16
17# cxmathfuncs.cpp has implicit cast of int struct fields.
18LOCAL_CLANG_CFLAGS += -Wno-c++11-narrowing
19
20LOCAL_SRC_FILES := \
21        cxcore/src/cxalloc.cpp \
22        cxcore/src/cxarithm.cpp \
23        cxcore/src/cxarray.cpp \
24        cxcore/src/cxcmp.cpp \
25        cxcore/src/cxconvert.cpp \
26        cxcore/src/cxcopy.cpp \
27        cxcore/src/cxdatastructs.cpp \
28        cxcore/src/cxdrawing.cpp \
29        cxcore/src/cxdxt.cpp \
30        cxcore/src/cxerror.cpp \
31        cxcore/src/cximage.cpp \
32        cxcore/src/cxjacobieigens.cpp \
33        cxcore/src/cxlogic.cpp \
34        cxcore/src/cxlut.cpp \
35        cxcore/src/cxmathfuncs.cpp \
36        cxcore/src/cxmatmul.cpp \
37        cxcore/src/cxmatrix.cpp \
38        cxcore/src/cxmean.cpp \
39        cxcore/src/cxmeansdv.cpp \
40        cxcore/src/cxminmaxloc.cpp \
41        cxcore/src/cxnorm.cpp \
42        cxcore/src/cxouttext.cpp \
43        cxcore/src/cxpersistence.cpp \
44        cxcore/src/cxprecomp.cpp \
45        cxcore/src/cxrand.cpp \
46        cxcore/src/cxsumpixels.cpp \
47        cxcore/src/cxsvd.cpp \
48        cxcore/src/cxswitcher.cpp \
49        cxcore/src/cxtables.cpp \
50        cxcore/src/cxutils.cpp
51
52include $(BUILD_STATIC_LIBRARY)
53
54
55
56include $(CLEAR_VARS)
57
58LOCAL_MODULE    := libcv
59LOCAL_MODULE_TAGS := optional
60
61LOCAL_C_INCLUDES := \
62        $(LOCAL_PATH)/cxcore/include \
63        $(LOCAL_PATH)/cxcore/src \
64        $(LOCAL_PATH)/cv/include
65LOCAL_CFLAGS := $(LOCAL_C_INCLUDES:%=-I%)
66
67LOCAL_CFLAGS += -Wno-sizeof-pointer-memaccess \
68       -Wno-deprecated-register \
69       -Wno-sign-compare \
70       -Wno-parentheses-equality
71
72LOCAL_TIDY_CHECKS := $(common_local_tidy_checks)
73
74LOCAL_SRC_FILES := \
75        cv/src/cvaccum.cpp \
76        cv/src/cvadapthresh.cpp \
77        cv/src/cvapprox.cpp \
78        cv/src/cvcalccontrasthistogram.cpp \
79        cv/src/cvcalcimagehomography.cpp \
80        cv/src/cvcalibinit.cpp \
81        cv/src/cvcalibration.cpp \
82        cv/src/cvcamshift.cpp \
83        cv/src/cvcanny.cpp \
84        cv/src/cvcolor.cpp \
85        cv/src/cvcondens.cpp \
86        cv/src/cvcontours.cpp \
87        cv/src/cvcontourtree.cpp \
88        cv/src/cvconvhull.cpp \
89        cv/src/cvcorner.cpp \
90        cv/src/cvcornersubpix.cpp \
91        cv/src/cvderiv.cpp \
92        cv/src/cvdistransform.cpp \
93        cv/src/cvdominants.cpp \
94        cv/src/cvemd.cpp \
95        cv/src/cvfeatureselect.cpp \
96        cv/src/cvfilter.cpp \
97        cv/src/cvfloodfill.cpp \
98        cv/src/cvfundam.cpp \
99        cv/src/cvgeometry.cpp \
100        cv/src/cvhaar.cpp \
101        cv/src/cvhistogram.cpp \
102        cv/src/cvhough.cpp \
103        cv/src/cvimgwarp.cpp \
104        cv/src/cvinpaint.cpp \
105        cv/src/cvkalman.cpp \
106        cv/src/cvlinefit.cpp \
107        cv/src/cvlkpyramid.cpp \
108        cv/src/cvmatchcontours.cpp \
109        cv/src/cvmoments.cpp \
110        cv/src/cvmorph.cpp \
111        cv/src/cvmotempl.cpp \
112        cv/src/cvoptflowbm.cpp \
113        cv/src/cvoptflowhs.cpp \
114        cv/src/cvoptflowlk.cpp \
115        cv/src/cvpgh.cpp \
116        cv/src/cvposit.cpp \
117        cv/src/cvprecomp.cpp \
118        cv/src/cvpyramids.cpp \
119        cv/src/cvpyrsegmentation.cpp \
120        cv/src/cvrotcalipers.cpp \
121        cv/src/cvsamplers.cpp \
122        cv/src/cvsegmentation.cpp \
123        cv/src/cvshapedescr.cpp \
124        cv/src/cvsmooth.cpp \
125        cv/src/cvsnakes.cpp \
126        cv/src/cvstereobm.cpp \
127        cv/src/cvstereogc.cpp \
128        cv/src/cvsubdivision2d.cpp \
129        cv/src/cvsumpixels.cpp \
130        cv/src/cvsurf.cpp \
131        cv/src/cvswitcher.cpp \
132        cv/src/cvtables.cpp \
133        cv/src/cvtemplmatch.cpp \
134        cv/src/cvthresh.cpp \
135        cv/src/cvundistort.cpp \
136        cv/src/cvutils.cpp \
137        cv/src/mycvHaarDetectObjects.cpp
138#        cv/src/cvkdtree.cpp \
139
140include $(BUILD_STATIC_LIBRARY)
141
142
143
144include $(CLEAR_VARS)
145
146LOCAL_TIDY_CHECKS := $(common_local_tidy_checks)
147LOCAL_MODULE    := libcvaux
148LOCAL_MODULE_TAGS := optional
149LOCAL_C_INCLUDES := \
150        $(LOCAL_PATH)/cv/src \
151        $(LOCAL_PATH)/cv/include \
152        $(LOCAL_PATH)/cxcore/include \
153        $(LOCAL_PATH)/cvaux/include
154LOCAL_CFLAGS := $(LOCAL_C_INCLUDES:%=-I%)
155
156LOCAL_CFLAGS += -Wno-unused-parameter \
157        -Wno-logical-op-parentheses \
158        -Wno-dangling-else \
159        -Wno-missing-field-initializers \
160        -Wno-self-assign \
161        -Wno-sizeof-pointer-memaccess
162
163LOCAL_SRC_FILES := \
164        cvaux/src/camshift.cpp \
165        cvaux/src/cvaux.cpp \
166        cvaux/src/cvauxutils.cpp \
167        cvaux/src/cvbgfg_acmmm2003.cpp \
168        cvaux/src/cvbgfg_codebook.cpp \
169        cvaux/src/cvbgfg_common.cpp \
170        cvaux/src/cvbgfg_gaussmix.cpp \
171        cvaux/src/cvcalibfilter.cpp \
172        cvaux/src/cvclique.cpp \
173        cvaux/src/cvcorrespond.cpp \
174        cvaux/src/cvcorrimages.cpp \
175        cvaux/src/cvcreatehandmask.cpp \
176        cvaux/src/cvdpstereo.cpp \
177        cvaux/src/cveigenobjects.cpp \
178        cvaux/src/cvepilines.cpp \
179        cvaux/src/cvface.cpp \
180        cvaux/src/cvfacedetection.cpp \
181        cvaux/src/cvfacetemplate.cpp \
182        cvaux/src/cvfindface.cpp \
183        cvaux/src/cvfindhandregion.cpp \
184        cvaux/src/cvhmm.cpp \
185        cvaux/src/cvhmm1d.cpp \
186        cvaux/src/cvhmmobs.cpp \
187        cvaux/src/cvlcm.cpp \
188        cvaux/src/cvlee.cpp \
189        cvaux/src/cvlevmar.cpp \
190        cvaux/src/cvlevmarprojbandle.cpp \
191        cvaux/src/cvlevmartrif.cpp \
192        cvaux/src/cvlines.cpp \
193        cvaux/src/cvlmeds.cpp \
194        cvaux/src/cvmat.cpp \
195        cvaux/src/cvmorphcontours.cpp \
196        cvaux/src/cvmorphing.cpp \
197        cvaux/src/cvprewarp.cpp \
198        cvaux/src/cvscanlines.cpp \
199        cvaux/src/cvsegment.cpp \
200        cvaux/src/cvsubdiv2.cpp \
201        cvaux/src/cvtexture.cpp \
202        cvaux/src/cvtrifocal.cpp \
203        cvaux/src/cvvecfacetracking.cpp \
204        cvaux/src/cvvideo.cpp \
205        cvaux/src/decomppoly.cpp \
206        cvaux/src/enmin.cpp \
207        cvaux/src/extendededges.cpp \
208        cvaux/src/precomp.cpp
209#        cvaux/src/cv3dtracker.cpp \
210
211include $(BUILD_STATIC_LIBRARY)
212
213
214
215include $(CLEAR_VARS)
216
217LOCAL_TIDY_CHECKS := $(common_local_tidy_checks)
218LOCAL_MODULE    := libcvml
219LOCAL_MODULE_TAGS := optional
220LOCAL_C_INCLUDES := \
221        $(LOCAL_PATH)/cv/src \
222        $(LOCAL_PATH)/cv/include \
223        $(LOCAL_PATH)/cxcore/include \
224        $(LOCAL_PATH)/ml/include
225LOCAL_CFLAGS := $(LOCAL_C_INCLUDES:%=-I%)
226
227LOCAL_CFLAGS += -Wno-logical-op-parentheses \
228       -Wno-tautological-compare
229
230LOCAL_SRC_FILES := \
231        ml/src/ml.cpp \
232        ml/src/mlann_mlp.cpp \
233        ml/src/mlboost.cpp \
234        ml/src/mlcnn.cpp \
235        ml/src/mlem.cpp \
236        ml/src/mlestimate.cpp \
237        ml/src/mlknearest.cpp \
238        ml/src/mlnbayes.cpp \
239        ml/src/mlrtrees.cpp \
240        ml/src/mlsvm.cpp \
241        ml/src/mltestset.cpp \
242        ml/src/mltree.cpp \
243        ml/src/ml_inner_functions.cpp
244
245include $(BUILD_STATIC_LIBRARY)
246
247
248
249include $(CLEAR_VARS)
250
251LOCAL_TIDY_CHECKS := $(common_local_tidy_checks)
252LOCAL_MODULE    := libcvhighgui
253LOCAL_MODULE_TAGS := optional
254LOCAL_C_INCLUDES := \
255        $(LOCAL_PATH)/cv/src \
256        $(LOCAL_PATH)/cv/include \
257        $(LOCAL_PATH)/cxcore/include \
258        $(LOCAL_PATH)/otherlibs/highgui \
259        external/jpeg
260
261LOCAL_SHARED_LIBRARIES += libjpeg
262
263LOCAL_CFLAGS := $(LOCAL_C_INCLUDES:%=-I%) -DHAVE_JPEG
264
265LOCAL_CFLAGS += -Wno-unused-parameter -Wno-logical-op-parentheses
266
267# grfmt_tiff.cpp has implicit cast of int struct fields.
268LOCAL_CLANG_CFLAGS += -Wno-c++11-narrowing
269
270LOCAL_SRC_FILES := \
271        otherlibs/highgui/bitstrm.cpp \
272        otherlibs/highgui/grfmt_base.cpp \
273        otherlibs/highgui/grfmt_bmp.cpp \
274        otherlibs/highgui/grfmt_exr.cpp \
275        otherlibs/highgui/grfmt_imageio.cpp \
276        otherlibs/highgui/grfmt_jpeg.cpp \
277        otherlibs/highgui/grfmt_jpeg2000.cpp \
278        otherlibs/highgui/grfmt_png.cpp \
279        otherlibs/highgui/grfmt_pxm.cpp \
280        otherlibs/highgui/grfmt_sunras.cpp \
281        otherlibs/highgui/grfmt_tiff.cpp \
282        otherlibs/highgui/image.cpp \
283        otherlibs/highgui/loadsave.cpp \
284        otherlibs/highgui/precomp.cpp \
285        otherlibs/highgui/utils.cpp \
286        otherlibs/highgui/cvcap.cpp \
287        otherlibs/highgui/cvcap_socket.cpp
288
289include $(BUILD_STATIC_LIBRARY)
290
291include $(CLEAR_VARS)
292
293LOCAL_TIDY_CHECKS := $(common_local_tidy_checks)
294LOCAL_MODULE    := libopencv
295LOCAL_MODULE_TAGS := optional
296
297include $(LOCAL_PATH)/libopencv.mk
298
299LOCAL_CFLAGS := $(LOCAL_C_INCLUDES:%=-I%)
300
301
302LOCAL_SRC_FILES := \
303        WLNonFileByteStream.cpp
304
305
306LOCAL_STATIC_LIBRARIES := libcxcore libcv libcvaux libcvml libcvhighgui
307
308include $(BUILD_STATIC_LIBRARY)
309