1# This file is generated by gyp; do not edit.
2
3include $(CLEAR_VARS)
4
5LOCAL_MODULE_CLASS := STATIC_LIBRARIES
6LOCAL_MODULE := third_party_opus_opus_gyp
7LOCAL_MODULE_SUFFIX := .a
8LOCAL_MODULE_TARGET_ARCH := $(TARGET_$(GYP_VAR_PREFIX)ARCH)
9gyp_intermediate_dir := $(call local-intermediates-dir,,$(GYP_VAR_PREFIX))
10gyp_shared_intermediate_dir := $(call intermediates-dir-for,GYP,shared,,,$(GYP_VAR_PREFIX))
11
12# Make sure our deps are built first.
13GYP_TARGET_DEPENDENCIES :=
14
15GYP_GENERATED_OUTPUTS :=
16
17# Make sure our deps and generated files are built first.
18LOCAL_ADDITIONAL_DEPENDENCIES := $(GYP_TARGET_DEPENDENCIES) $(GYP_GENERATED_OUTPUTS)
19
20LOCAL_GENERATED_SOURCES :=
21
22GYP_COPIED_SOURCE_ORIGIN_DIRS :=
23
24LOCAL_SRC_FILES := \
25	third_party/opus/src/celt/bands.c \
26	third_party/opus/src/celt/celt.c \
27	third_party/opus/src/celt/celt_decoder.c \
28	third_party/opus/src/celt/celt_encoder.c \
29	third_party/opus/src/celt/celt_lpc.c \
30	third_party/opus/src/celt/cwrs.c \
31	third_party/opus/src/celt/entcode.c \
32	third_party/opus/src/celt/entdec.c \
33	third_party/opus/src/celt/entenc.c \
34	third_party/opus/src/celt/kiss_fft.c \
35	third_party/opus/src/celt/laplace.c \
36	third_party/opus/src/celt/mathops.c \
37	third_party/opus/src/celt/mdct.c \
38	third_party/opus/src/celt/modes.c \
39	third_party/opus/src/celt/pitch.c \
40	third_party/opus/src/celt/quant_bands.c \
41	third_party/opus/src/celt/rate.c \
42	third_party/opus/src/celt/vq.c \
43	third_party/opus/src/silk/A2NLSF.c \
44	third_party/opus/src/silk/ana_filt_bank_1.c \
45	third_party/opus/src/silk/biquad_alt.c \
46	third_party/opus/src/silk/bwexpander.c \
47	third_party/opus/src/silk/bwexpander_32.c \
48	third_party/opus/src/silk/check_control_input.c \
49	third_party/opus/src/silk/CNG.c \
50	third_party/opus/src/silk/code_signs.c \
51	third_party/opus/src/silk/control_audio_bandwidth.c \
52	third_party/opus/src/silk/control_codec.c \
53	third_party/opus/src/silk/control_SNR.c \
54	third_party/opus/src/silk/debug.c \
55	third_party/opus/src/silk/dec_API.c \
56	third_party/opus/src/silk/decode_core.c \
57	third_party/opus/src/silk/decode_frame.c \
58	third_party/opus/src/silk/decode_indices.c \
59	third_party/opus/src/silk/decode_parameters.c \
60	third_party/opus/src/silk/decode_pitch.c \
61	third_party/opus/src/silk/decode_pulses.c \
62	third_party/opus/src/silk/decoder_set_fs.c \
63	third_party/opus/src/silk/enc_API.c \
64	third_party/opus/src/silk/encode_indices.c \
65	third_party/opus/src/silk/encode_pulses.c \
66	third_party/opus/src/silk/gain_quant.c \
67	third_party/opus/src/silk/HP_variable_cutoff.c \
68	third_party/opus/src/silk/init_decoder.c \
69	third_party/opus/src/silk/init_encoder.c \
70	third_party/opus/src/silk/inner_prod_aligned.c \
71	third_party/opus/src/silk/interpolate.c \
72	third_party/opus/src/silk/lin2log.c \
73	third_party/opus/src/silk/log2lin.c \
74	third_party/opus/src/silk/LP_variable_cutoff.c \
75	third_party/opus/src/silk/LPC_analysis_filter.c \
76	third_party/opus/src/silk/LPC_inv_pred_gain.c \
77	third_party/opus/src/silk/NLSF2A.c \
78	third_party/opus/src/silk/NLSF_decode.c \
79	third_party/opus/src/silk/NLSF_del_dec_quant.c \
80	third_party/opus/src/silk/NLSF_encode.c \
81	third_party/opus/src/silk/NLSF_stabilize.c \
82	third_party/opus/src/silk/NLSF_unpack.c \
83	third_party/opus/src/silk/NLSF_VQ.c \
84	third_party/opus/src/silk/NLSF_VQ_weights_laroia.c \
85	third_party/opus/src/silk/NSQ.c \
86	third_party/opus/src/silk/NSQ_del_dec.c \
87	third_party/opus/src/silk/pitch_est_tables.c \
88	third_party/opus/src/silk/PLC.c \
89	third_party/opus/src/silk/process_NLSFs.c \
90	third_party/opus/src/silk/quant_LTP_gains.c \
91	third_party/opus/src/silk/resampler.c \
92	third_party/opus/src/silk/resampler_down2.c \
93	third_party/opus/src/silk/resampler_down2_3.c \
94	third_party/opus/src/silk/resampler_private_AR2.c \
95	third_party/opus/src/silk/resampler_private_down_FIR.c \
96	third_party/opus/src/silk/resampler_private_IIR_FIR.c \
97	third_party/opus/src/silk/resampler_private_up2_HQ.c \
98	third_party/opus/src/silk/resampler_rom.c \
99	third_party/opus/src/silk/shell_coder.c \
100	third_party/opus/src/silk/sigm_Q15.c \
101	third_party/opus/src/silk/sort.c \
102	third_party/opus/src/silk/stereo_decode_pred.c \
103	third_party/opus/src/silk/stereo_encode_pred.c \
104	third_party/opus/src/silk/stereo_find_predictor.c \
105	third_party/opus/src/silk/stereo_LR_to_MS.c \
106	third_party/opus/src/silk/stereo_MS_to_LR.c \
107	third_party/opus/src/silk/stereo_quant_pred.c \
108	third_party/opus/src/silk/sum_sqr_shift.c \
109	third_party/opus/src/silk/table_LSF_cos.c \
110	third_party/opus/src/silk/tables_gain.c \
111	third_party/opus/src/silk/tables_LTP.c \
112	third_party/opus/src/silk/tables_NLSF_CB_NB_MB.c \
113	third_party/opus/src/silk/tables_NLSF_CB_WB.c \
114	third_party/opus/src/silk/tables_other.c \
115	third_party/opus/src/silk/tables_pitch_lag.c \
116	third_party/opus/src/silk/tables_pulses_per_block.c \
117	third_party/opus/src/silk/VAD.c \
118	third_party/opus/src/silk/VQ_WMat_EC.c \
119	third_party/opus/src/src/analysis.c \
120	third_party/opus/src/src/mlp.c \
121	third_party/opus/src/src/mlp_data.c \
122	third_party/opus/src/src/opus.c \
123	third_party/opus/src/src/opus_decoder.c \
124	third_party/opus/src/src/opus_encoder.c \
125	third_party/opus/src/src/opus_multistream.c \
126	third_party/opus/src/src/opus_multistream_decoder.c \
127	third_party/opus/src/src/opus_multistream_encoder.c \
128	third_party/opus/src/src/repacketizer.c \
129	third_party/opus/src/silk/fixed/apply_sine_window_FIX.c \
130	third_party/opus/src/silk/fixed/autocorr_FIX.c \
131	third_party/opus/src/silk/fixed/burg_modified_FIX.c \
132	third_party/opus/src/silk/fixed/corrMatrix_FIX.c \
133	third_party/opus/src/silk/fixed/encode_frame_FIX.c \
134	third_party/opus/src/silk/fixed/find_LPC_FIX.c \
135	third_party/opus/src/silk/fixed/find_LTP_FIX.c \
136	third_party/opus/src/silk/fixed/find_pitch_lags_FIX.c \
137	third_party/opus/src/silk/fixed/find_pred_coefs_FIX.c \
138	third_party/opus/src/silk/fixed/k2a_FIX.c \
139	third_party/opus/src/silk/fixed/k2a_Q16_FIX.c \
140	third_party/opus/src/silk/fixed/LTP_analysis_filter_FIX.c \
141	third_party/opus/src/silk/fixed/LTP_scale_ctrl_FIX.c \
142	third_party/opus/src/silk/fixed/noise_shape_analysis_FIX.c \
143	third_party/opus/src/silk/fixed/pitch_analysis_core_FIX.c \
144	third_party/opus/src/silk/fixed/prefilter_FIX.c \
145	third_party/opus/src/silk/fixed/process_gains_FIX.c \
146	third_party/opus/src/silk/fixed/regularize_correlations_FIX.c \
147	third_party/opus/src/silk/fixed/residual_energy16_FIX.c \
148	third_party/opus/src/silk/fixed/residual_energy_FIX.c \
149	third_party/opus/src/silk/fixed/schur64_FIX.c \
150	third_party/opus/src/silk/fixed/schur_FIX.c \
151	third_party/opus/src/silk/fixed/solve_LS_FIX.c \
152	third_party/opus/src/silk/fixed/vector_ops_FIX.c \
153	third_party/opus/src/silk/fixed/warped_autocorrelation_FIX.c
154
155
156# Flags passed to both C and C++ files.
157MY_CFLAGS_Debug := \
158	--param=ssp-buffer-size=4 \
159	-fno-strict-aliasing \
160	-Wno-unused-parameter \
161	-Wno-missing-field-initializers \
162	-fvisibility=hidden \
163	-pipe \
164	-fPIC \
165	-Wno-unused-local-typedefs \
166	-O3 \
167	-Wno-format \
168	-ffunction-sections \
169	-funwind-tables \
170	-g \
171	-fno-short-enums \
172	-finline-limit=64 \
173	-Wa,--noexecstack \
174	-U_FORTIFY_SOURCE \
175	-Wno-extra \
176	-Wno-ignored-qualifiers \
177	-Wno-type-limits \
178	-Wno-unused-but-set-variable \
179	-Wno-address \
180	-Wno-format-security \
181	-Wno-return-type \
182	-Wno-sequence-point \
183	-g \
184	-gdwarf-4 \
185	-fdata-sections \
186	-ffunction-sections \
187	-funwind-tables
188
189MY_DEFS_Debug := \
190	'-DV8_DEPRECATION_WARNINGS' \
191	'-D_FILE_OFFSET_BITS=64' \
192	'-DNO_TCMALLOC' \
193	'-DDISABLE_NACL' \
194	'-DCHROMIUM_BUILD' \
195	'-DUSE_LIBJPEG_TURBO=1' \
196	'-DENABLE_WEBRTC=1' \
197	'-DUSE_PROPRIETARY_CODECS' \
198	'-DENABLE_BROWSER_CDMS' \
199	'-DENABLE_CONFIGURATION_POLICY' \
200	'-DDISCARDABLE_MEMORY_ALWAYS_SUPPORTED_NATIVELY' \
201	'-DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE' \
202	'-DENABLE_EGLIMAGE=1' \
203	'-DCLD_VERSION=1' \
204	'-DENABLE_PRINTING=1' \
205	'-DENABLE_MANAGED_USERS=1' \
206	'-DDATA_REDUCTION_FALLBACK_HOST="http://compress.googlezip.net:80/"' \
207	'-DDATA_REDUCTION_DEV_HOST="https://proxy-dev.googlezip.net:443/"' \
208	'-DDATA_REDUCTION_DEV_FALLBACK_HOST="http://proxy-dev.googlezip.net:80/"' \
209	'-DSPDY_PROXY_AUTH_ORIGIN="https://proxy.googlezip.net:443/"' \
210	'-DDATA_REDUCTION_PROXY_PROBE_URL="http://check.googlezip.net/connect"' \
211	'-DDATA_REDUCTION_PROXY_WARMUP_URL="http://www.gstatic.com/generate_204"' \
212	'-DVIDEO_HOLE=1' \
213	'-DENABLE_LOAD_COMPLETION_HACKS=1' \
214	'-DOPUS_BUILD' \
215	'-DOPUS_EXPORT=' \
216	'-DHAVE_LRINT' \
217	'-DHAVE_LRINTF' \
218	'-DVAR_ARRAYS' \
219	'-DFIXED_POINT' \
220	'-DUSE_OPENSSL=1' \
221	'-DUSE_OPENSSL_CERTS=1' \
222	'-DANDROID' \
223	'-D__GNU_SOURCE=1' \
224	'-DUSE_STLPORT=1' \
225	'-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
226	'-DCHROME_BUILD_ID=""' \
227	'-DDYNAMIC_ANNOTATIONS_ENABLED=1' \
228	'-DWTF_USE_DYNAMIC_ANNOTATIONS=1' \
229	'-D_DEBUG'
230
231
232# Include paths placed before CFLAGS/CPPFLAGS
233LOCAL_C_INCLUDES_Debug := \
234	$(gyp_shared_intermediate_dir) \
235	$(LOCAL_PATH)/third_party/opus/src/celt \
236	$(LOCAL_PATH)/third_party/opus/src/include \
237	$(LOCAL_PATH)/third_party/opus/src/silk \
238	$(LOCAL_PATH)/third_party/opus/src/silk/fixed \
239	$(PWD)/frameworks/wilhelm/include \
240	$(PWD)/bionic \
241	$(PWD)/external/stlport/stlport
242
243
244# Flags passed to only C++ (and not C) files.
245LOCAL_CPPFLAGS_Debug := \
246	-fno-exceptions \
247	-fno-rtti \
248	-fno-threadsafe-statics \
249	-fvisibility-inlines-hidden \
250	-Wno-deprecated \
251	-std=gnu++11 \
252	-Wno-narrowing \
253	-Wno-literal-suffix \
254	-Wno-non-virtual-dtor \
255	-Wno-sign-promo \
256	-Wno-non-virtual-dtor
257
258
259# Flags passed to both C and C++ files.
260MY_CFLAGS_Release := \
261	--param=ssp-buffer-size=4 \
262	-fno-strict-aliasing \
263	-Wno-unused-parameter \
264	-Wno-missing-field-initializers \
265	-fvisibility=hidden \
266	-pipe \
267	-fPIC \
268	-Wno-unused-local-typedefs \
269	-O3 \
270	-Wno-format \
271	-ffunction-sections \
272	-funwind-tables \
273	-g \
274	-fno-short-enums \
275	-finline-limit=64 \
276	-Wa,--noexecstack \
277	-U_FORTIFY_SOURCE \
278	-Wno-extra \
279	-Wno-ignored-qualifiers \
280	-Wno-type-limits \
281	-Wno-unused-but-set-variable \
282	-Wno-address \
283	-Wno-format-security \
284	-Wno-return-type \
285	-Wno-sequence-point \
286	-fno-ident \
287	-fdata-sections \
288	-ffunction-sections \
289	-funwind-tables
290
291MY_DEFS_Release := \
292	'-DV8_DEPRECATION_WARNINGS' \
293	'-D_FILE_OFFSET_BITS=64' \
294	'-DNO_TCMALLOC' \
295	'-DDISABLE_NACL' \
296	'-DCHROMIUM_BUILD' \
297	'-DUSE_LIBJPEG_TURBO=1' \
298	'-DENABLE_WEBRTC=1' \
299	'-DUSE_PROPRIETARY_CODECS' \
300	'-DENABLE_BROWSER_CDMS' \
301	'-DENABLE_CONFIGURATION_POLICY' \
302	'-DDISCARDABLE_MEMORY_ALWAYS_SUPPORTED_NATIVELY' \
303	'-DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE' \
304	'-DENABLE_EGLIMAGE=1' \
305	'-DCLD_VERSION=1' \
306	'-DENABLE_PRINTING=1' \
307	'-DENABLE_MANAGED_USERS=1' \
308	'-DDATA_REDUCTION_FALLBACK_HOST="http://compress.googlezip.net:80/"' \
309	'-DDATA_REDUCTION_DEV_HOST="https://proxy-dev.googlezip.net:443/"' \
310	'-DDATA_REDUCTION_DEV_FALLBACK_HOST="http://proxy-dev.googlezip.net:80/"' \
311	'-DSPDY_PROXY_AUTH_ORIGIN="https://proxy.googlezip.net:443/"' \
312	'-DDATA_REDUCTION_PROXY_PROBE_URL="http://check.googlezip.net/connect"' \
313	'-DDATA_REDUCTION_PROXY_WARMUP_URL="http://www.gstatic.com/generate_204"' \
314	'-DVIDEO_HOLE=1' \
315	'-DENABLE_LOAD_COMPLETION_HACKS=1' \
316	'-DOPUS_BUILD' \
317	'-DOPUS_EXPORT=' \
318	'-DHAVE_LRINT' \
319	'-DHAVE_LRINTF' \
320	'-DVAR_ARRAYS' \
321	'-DFIXED_POINT' \
322	'-DUSE_OPENSSL=1' \
323	'-DUSE_OPENSSL_CERTS=1' \
324	'-DANDROID' \
325	'-D__GNU_SOURCE=1' \
326	'-DUSE_STLPORT=1' \
327	'-D_STLP_USE_PTR_SPECIALIZATIONS=1' \
328	'-DCHROME_BUILD_ID=""' \
329	'-DNDEBUG' \
330	'-DNVALGRIND' \
331	'-DDYNAMIC_ANNOTATIONS_ENABLED=0'
332
333
334# Include paths placed before CFLAGS/CPPFLAGS
335LOCAL_C_INCLUDES_Release := \
336	$(gyp_shared_intermediate_dir) \
337	$(LOCAL_PATH)/third_party/opus/src/celt \
338	$(LOCAL_PATH)/third_party/opus/src/include \
339	$(LOCAL_PATH)/third_party/opus/src/silk \
340	$(LOCAL_PATH)/third_party/opus/src/silk/fixed \
341	$(PWD)/frameworks/wilhelm/include \
342	$(PWD)/bionic \
343	$(PWD)/external/stlport/stlport
344
345
346# Flags passed to only C++ (and not C) files.
347LOCAL_CPPFLAGS_Release := \
348	-fno-exceptions \
349	-fno-rtti \
350	-fno-threadsafe-statics \
351	-fvisibility-inlines-hidden \
352	-Wno-deprecated \
353	-std=gnu++11 \
354	-Wno-narrowing \
355	-Wno-literal-suffix \
356	-Wno-non-virtual-dtor \
357	-Wno-sign-promo \
358	-Wno-non-virtual-dtor
359
360
361LOCAL_CFLAGS := $(MY_CFLAGS_$(GYP_CONFIGURATION)) $(MY_DEFS_$(GYP_CONFIGURATION))
362LOCAL_C_INCLUDES := $(GYP_COPIED_SOURCE_ORIGIN_DIRS) $(LOCAL_C_INCLUDES_$(GYP_CONFIGURATION))
363LOCAL_CPPFLAGS := $(LOCAL_CPPFLAGS_$(GYP_CONFIGURATION))
364LOCAL_ASFLAGS := $(LOCAL_CFLAGS)
365### Rules for final target.
366
367LOCAL_SHARED_LIBRARIES := \
368	libstlport \
369	libdl
370
371# Add target alias to "gyp_all_modules" target.
372.PHONY: gyp_all_modules
373gyp_all_modules: third_party_opus_opus_gyp
374
375# Alias gyp target name.
376.PHONY: opus
377opus: third_party_opus_opus_gyp
378
379include $(BUILD_STATIC_LIBRARY)
380