blob: d680d6f025d4633276b36a70b1769a5489d99787 [file] [log] [blame]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +00001# Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
2#
3# Use of this source code is governed by a BSD-style license
4# that can be found in the LICENSE file in the root of the source
5# tree. An additional intellectual property rights grant can be found
6# in the file PATENTS. All contributing project authors may
7# be found in the AUTHORS file in the root of the source tree.
8
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +00009import("//build/config/arm.gni")
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000010import("../../build/webrtc.gni")
11
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +000012config("audio_coding_config") {
13 include_dirs = [
14 "main/interface",
15 "../interface",
16 ]
17}
18
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000019source_set("audio_coding") {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +000020 sources = [
21 "main/acm2/acm_amr.cc",
22 "main/acm2/acm_amr.h",
23 "main/acm2/acm_amrwb.cc",
24 "main/acm2/acm_amrwb.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +000025 "main/acm2/acm_cng.cc",
26 "main/acm2/acm_cng.h",
27 "main/acm2/acm_codec_database.cc",
28 "main/acm2/acm_codec_database.h",
29 "main/acm2/acm_common_defs.h",
30 "main/acm2/acm_dtmf_playout.cc",
31 "main/acm2/acm_dtmf_playout.h",
32 "main/acm2/acm_g722.cc",
33 "main/acm2/acm_g722.h",
34 "main/acm2/acm_g7221.cc",
35 "main/acm2/acm_g7221.h",
36 "main/acm2/acm_g7221c.cc",
37 "main/acm2/acm_g7221c.h",
38 "main/acm2/acm_g729.cc",
39 "main/acm2/acm_g729.h",
40 "main/acm2/acm_g7291.cc",
41 "main/acm2/acm_g7291.h",
42 "main/acm2/acm_generic_codec.cc",
43 "main/acm2/acm_generic_codec.h",
44 "main/acm2/acm_gsmfr.cc",
45 "main/acm2/acm_gsmfr.h",
46 "main/acm2/acm_ilbc.cc",
47 "main/acm2/acm_ilbc.h",
48 "main/acm2/acm_isac.cc",
49 "main/acm2/acm_isac.h",
50 "main/acm2/acm_isac_macros.h",
51 "main/acm2/acm_opus.cc",
52 "main/acm2/acm_opus.h",
53 "main/acm2/acm_speex.cc",
54 "main/acm2/acm_speex.h",
55 "main/acm2/acm_pcm16b.cc",
56 "main/acm2/acm_pcm16b.h",
57 "main/acm2/acm_pcma.cc",
58 "main/acm2/acm_pcma.h",
59 "main/acm2/acm_pcmu.cc",
60 "main/acm2/acm_pcmu.h",
61 "main/acm2/acm_red.cc",
62 "main/acm2/acm_red.h",
63 "main/acm2/acm_receiver.cc",
64 "main/acm2/acm_receiver.h",
65 "main/acm2/acm_resampler.cc",
66 "main/acm2/acm_resampler.h",
67 "main/acm2/audio_coding_module.cc",
68 "main/acm2/audio_coding_module_impl.cc",
69 "main/acm2/audio_coding_module_impl.h",
70 "main/acm2/call_statistics.cc",
71 "main/acm2/call_statistics.h",
72 "main/acm2/initial_delay_manager.cc",
73 "main/acm2/initial_delay_manager.h",
74 "main/acm2/nack.cc",
75 "main/acm2/nack.h",
76 "main/interface/audio_coding_module.h",
77 "main/interface/audio_coding_module_typedefs.h",
78 ]
79
80 defines = []
81
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +000082 configs += [ "../..:common_config" ]
83
84 public_configs = [
85 "../..:common_inherited_config",
86 ":audio_coding_config",
87 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +000088
89 if (is_clang) {
90 # Suppress warnings from Chrome's Clang plugins.
91 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
92 configs -= [ "//build/config/clang:find_bad_constructs" ]
93 }
94
95 deps = [
96 ":cng",
97 ":g711",
98 ":g722",
99 ":ilbc",
100 ":isac",
101 ":isacfix",
102 ":neteq",
103 ":pcm16b",
104 "../../common_audio",
105 "../../system_wrappers",
106 ]
107
kjellander@webrtc.org6d08ca62014-09-07 17:36:10 +0000108 if (rtc_include_opus) {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000109 defines += [ "WEBRTC_CODEC_OPUS" ]
110 deps += [ ":webrtc_opus" ]
111 }
112}
113
kwiberg@webrtc.orge04a93b2014-12-09 10:12:53 +0000114source_set("audio_decoder_interface") {
115 sources = [
116 "codecs/audio_decoder.cc",
117 "codecs/audio_decoder.h",
118 ]
119 configs += [ "../..:common_config" ]
120 public_configs = [ "../..:common_inherited_config" ]
121}
122
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000123config("cng_config") {
124 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000125 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000126 "codecs/cng/include",
127 ]
128}
129
130source_set("cng") {
131 sources = [
henrik.lundin@webrtc.orgff1a3e32014-12-10 07:29:08 +0000132 "codecs/cng/audio_encoder_cng.cc",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000133 "codecs/cng/cng_helpfuns.c",
134 "codecs/cng/cng_helpfuns.h",
henrik.lundin@webrtc.orgff1a3e32014-12-10 07:29:08 +0000135 "codecs/cng/include/audio_encoder_cng.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000136 "codecs/cng/include/webrtc_cng.h",
137 "codecs/cng/webrtc_cng.c",
138 ]
139
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000140 configs += [ "../..:common_config" ]
141
142 public_configs = [
143 "../..:common_inherited_config",
144 ":cng_config",
145 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000146
147 deps = [ "../../common_audio" ]
148}
149
150config("g711_config") {
151 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000152 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000153 "codecs/g711/include",
154 ]
155}
156
157source_set("g711") {
158 sources = [
henrik.lundin@webrtc.orgdef1e972014-10-21 12:48:29 +0000159 "codecs/g711/include/audio_encoder_pcm.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000160 "codecs/g711/include/g711_interface.h",
henrik.lundin@webrtc.orgdef1e972014-10-21 12:48:29 +0000161 "codecs/g711/audio_encoder_pcm.cc",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000162 "codecs/g711/g711_interface.c",
163 "codecs/g711/g711.c",
164 "codecs/g711/g711.h",
165 ]
166
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000167 configs += [ "../..:common_config" ]
168
169 public_configs = [
170 "../..:common_inherited_config",
171 ":g711_config",
172 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000173}
174
175config("g722_config") {
176 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000177 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000178 "codecs/g722/include",
179 ]
180}
181
182source_set("g722") {
183 sources = [
kwiberg@webrtc.org0cd55582014-12-02 11:45:51 +0000184 "codecs/g722/audio_encoder_g722.cc",
185 "codecs/g722/include/audio_encoder_g722.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000186 "codecs/g722/include/g722_interface.h",
187 "codecs/g722/g722_interface.c",
188 "codecs/g722/g722_encode.c",
189 "codecs/g722/g722_decode.c",
190 "codecs/g722/g722_enc_dec.h",
191 ]
192
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000193 configs += [ "../..:common_config" ]
194
195 public_configs = [
196 "../..:common_inherited_config",
197 ":g722_config",
198 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000199}
200
201config("ilbc_config") {
202 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000203 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000204 "codecs/ilbc/interface",
205 ]
206}
207
208source_set("ilbc") {
209 sources = [
kwiberg@webrtc.orgcb858ba2014-12-08 17:11:44 +0000210 "codecs/ilbc/audio_encoder_ilbc.cc",
211 "codecs/ilbc/include/audio_encoder_ilbc.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000212 "codecs/ilbc/abs_quant.c",
213 "codecs/ilbc/abs_quant.h",
214 "codecs/ilbc/abs_quant_loop.c",
215 "codecs/ilbc/abs_quant_loop.h",
216 "codecs/ilbc/augmented_cb_corr.c",
217 "codecs/ilbc/augmented_cb_corr.h",
218 "codecs/ilbc/bw_expand.c",
219 "codecs/ilbc/bw_expand.h",
220 "codecs/ilbc/cb_construct.c",
221 "codecs/ilbc/cb_construct.h",
222 "codecs/ilbc/cb_mem_energy_augmentation.c",
223 "codecs/ilbc/cb_mem_energy_augmentation.h",
224 "codecs/ilbc/cb_mem_energy.c",
225 "codecs/ilbc/cb_mem_energy_calc.c",
226 "codecs/ilbc/cb_mem_energy_calc.h",
227 "codecs/ilbc/cb_mem_energy.h",
228 "codecs/ilbc/cb_search.c",
229 "codecs/ilbc/cb_search_core.c",
230 "codecs/ilbc/cb_search_core.h",
231 "codecs/ilbc/cb_search.h",
232 "codecs/ilbc/cb_update_best_index.c",
233 "codecs/ilbc/cb_update_best_index.h",
234 "codecs/ilbc/chebyshev.c",
235 "codecs/ilbc/chebyshev.h",
236 "codecs/ilbc/comp_corr.c",
237 "codecs/ilbc/comp_corr.h",
238 "codecs/ilbc/constants.c",
239 "codecs/ilbc/constants.h",
240 "codecs/ilbc/create_augmented_vec.c",
241 "codecs/ilbc/create_augmented_vec.h",
242 "codecs/ilbc/decode.c",
243 "codecs/ilbc/decode.h",
244 "codecs/ilbc/decode_residual.c",
245 "codecs/ilbc/decode_residual.h",
246 "codecs/ilbc/decoder_interpolate_lsf.c",
247 "codecs/ilbc/decoder_interpolate_lsf.h",
248 "codecs/ilbc/defines.h",
249 "codecs/ilbc/do_plc.c",
250 "codecs/ilbc/do_plc.h",
251 "codecs/ilbc/encode.c",
252 "codecs/ilbc/encode.h",
253 "codecs/ilbc/energy_inverse.c",
254 "codecs/ilbc/energy_inverse.h",
255 "codecs/ilbc/enhancer.c",
256 "codecs/ilbc/enhancer.h",
257 "codecs/ilbc/enhancer_interface.c",
258 "codecs/ilbc/enhancer_interface.h",
259 "codecs/ilbc/enh_upsample.c",
260 "codecs/ilbc/enh_upsample.h",
261 "codecs/ilbc/filtered_cb_vecs.c",
262 "codecs/ilbc/filtered_cb_vecs.h",
263 "codecs/ilbc/frame_classify.c",
264 "codecs/ilbc/frame_classify.h",
265 "codecs/ilbc/gain_dequant.c",
266 "codecs/ilbc/gain_dequant.h",
267 "codecs/ilbc/gain_quant.c",
268 "codecs/ilbc/gain_quant.h",
269 "codecs/ilbc/get_cd_vec.c",
270 "codecs/ilbc/get_cd_vec.h",
271 "codecs/ilbc/get_lsp_poly.c",
272 "codecs/ilbc/get_lsp_poly.h",
273 "codecs/ilbc/get_sync_seq.c",
274 "codecs/ilbc/get_sync_seq.h",
275 "codecs/ilbc/hp_input.c",
276 "codecs/ilbc/hp_input.h",
277 "codecs/ilbc/hp_output.c",
278 "codecs/ilbc/hp_output.h",
279 "codecs/ilbc/ilbc.c",
280 "codecs/ilbc/index_conv_dec.c",
281 "codecs/ilbc/index_conv_dec.h",
282 "codecs/ilbc/index_conv_enc.c",
283 "codecs/ilbc/index_conv_enc.h",
284 "codecs/ilbc/init_decode.c",
285 "codecs/ilbc/init_decode.h",
286 "codecs/ilbc/init_encode.c",
287 "codecs/ilbc/init_encode.h",
288 "codecs/ilbc/interface/ilbc.h",
289 "codecs/ilbc/interpolate.c",
290 "codecs/ilbc/interpolate.h",
291 "codecs/ilbc/interpolate_samples.c",
292 "codecs/ilbc/interpolate_samples.h",
293 "codecs/ilbc/lpc_encode.c",
294 "codecs/ilbc/lpc_encode.h",
295 "codecs/ilbc/lsf_check.c",
296 "codecs/ilbc/lsf_check.h",
297 "codecs/ilbc/lsf_interpolate_to_poly_dec.c",
298 "codecs/ilbc/lsf_interpolate_to_poly_dec.h",
299 "codecs/ilbc/lsf_interpolate_to_poly_enc.c",
300 "codecs/ilbc/lsf_interpolate_to_poly_enc.h",
301 "codecs/ilbc/lsf_to_lsp.c",
302 "codecs/ilbc/lsf_to_lsp.h",
303 "codecs/ilbc/lsf_to_poly.c",
304 "codecs/ilbc/lsf_to_poly.h",
305 "codecs/ilbc/lsp_to_lsf.c",
306 "codecs/ilbc/lsp_to_lsf.h",
307 "codecs/ilbc/my_corr.c",
308 "codecs/ilbc/my_corr.h",
309 "codecs/ilbc/nearest_neighbor.c",
310 "codecs/ilbc/nearest_neighbor.h",
311 "codecs/ilbc/pack_bits.c",
312 "codecs/ilbc/pack_bits.h",
313 "codecs/ilbc/poly_to_lsf.c",
314 "codecs/ilbc/poly_to_lsf.h",
315 "codecs/ilbc/poly_to_lsp.c",
316 "codecs/ilbc/poly_to_lsp.h",
317 "codecs/ilbc/refiner.c",
318 "codecs/ilbc/refiner.h",
319 "codecs/ilbc/simple_interpolate_lsf.c",
320 "codecs/ilbc/simple_interpolate_lsf.h",
321 "codecs/ilbc/simple_lpc_analysis.c",
322 "codecs/ilbc/simple_lpc_analysis.h",
323 "codecs/ilbc/simple_lsf_dequant.c",
324 "codecs/ilbc/simple_lsf_dequant.h",
325 "codecs/ilbc/simple_lsf_quant.c",
326 "codecs/ilbc/simple_lsf_quant.h",
327 "codecs/ilbc/smooth.c",
328 "codecs/ilbc/smooth.h",
329 "codecs/ilbc/smooth_out_data.c",
330 "codecs/ilbc/smooth_out_data.h",
331 "codecs/ilbc/sort_sq.c",
332 "codecs/ilbc/sort_sq.h",
333 "codecs/ilbc/split_vq.c",
334 "codecs/ilbc/split_vq.h",
335 "codecs/ilbc/state_construct.c",
336 "codecs/ilbc/state_construct.h",
337 "codecs/ilbc/state_search.c",
338 "codecs/ilbc/state_search.h",
339 "codecs/ilbc/swap_bytes.c",
340 "codecs/ilbc/swap_bytes.h",
341 "codecs/ilbc/unpack_bits.c",
342 "codecs/ilbc/unpack_bits.h",
343 "codecs/ilbc/vq3.c",
344 "codecs/ilbc/vq3.h",
345 "codecs/ilbc/vq4.c",
346 "codecs/ilbc/vq4.h",
347 "codecs/ilbc/window32_w32.c",
348 "codecs/ilbc/window32_w32.h",
349 "codecs/ilbc/xcorr_coef.c",
350 "codecs/ilbc/xcorr_coef.h",
351 ]
352
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000353 configs += [ "../..:common_config" ]
354
355 public_configs = [
356 "../..:common_inherited_config",
357 ":ilbc_config",
358 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000359
360 deps = [ "../../common_audio" ]
361}
362
363config("isac_config") {
364 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000365 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000366 "codecs/isac/main/interface",
367 ]
368}
369
370source_set("isac") {
371 sources = [
372 "codecs/isac/main/interface/isac.h",
373 "codecs/isac/main/source/arith_routines.c",
374 "codecs/isac/main/source/arith_routines.h",
375 "codecs/isac/main/source/arith_routines_hist.c",
376 "codecs/isac/main/source/arith_routines_logist.c",
377 "codecs/isac/main/source/bandwidth_estimator.c",
378 "codecs/isac/main/source/bandwidth_estimator.h",
379 "codecs/isac/main/source/codec.h",
380 "codecs/isac/main/source/crc.c",
381 "codecs/isac/main/source/crc.h",
382 "codecs/isac/main/source/decode_bwe.c",
383 "codecs/isac/main/source/decode.c",
384 "codecs/isac/main/source/encode.c",
385 "codecs/isac/main/source/encode_lpc_swb.c",
386 "codecs/isac/main/source/encode_lpc_swb.h",
387 "codecs/isac/main/source/entropy_coding.c",
388 "codecs/isac/main/source/entropy_coding.h",
389 "codecs/isac/main/source/fft.c",
390 "codecs/isac/main/source/fft.h",
391 "codecs/isac/main/source/filterbanks.c",
392 "codecs/isac/main/source/filterbank_tables.c",
393 "codecs/isac/main/source/filterbank_tables.h",
394 "codecs/isac/main/source/filter_functions.c",
395 "codecs/isac/main/source/intialize.c",
396 "codecs/isac/main/source/isac.c",
397 "codecs/isac/main/source/lattice.c",
398 "codecs/isac/main/source/lpc_analysis.c",
399 "codecs/isac/main/source/lpc_analysis.h",
400 "codecs/isac/main/source/lpc_gain_swb_tables.c",
401 "codecs/isac/main/source/lpc_gain_swb_tables.h",
402 "codecs/isac/main/source/lpc_shape_swb12_tables.c",
403 "codecs/isac/main/source/lpc_shape_swb12_tables.h",
404 "codecs/isac/main/source/lpc_shape_swb16_tables.c",
405 "codecs/isac/main/source/lpc_shape_swb16_tables.h",
406 "codecs/isac/main/source/lpc_tables.c",
407 "codecs/isac/main/source/lpc_tables.h",
408 "codecs/isac/main/source/os_specific_inline.h",
409 "codecs/isac/main/source/pitch_estimator.c",
410 "codecs/isac/main/source/pitch_estimator.h",
411 "codecs/isac/main/source/pitch_filter.c",
412 "codecs/isac/main/source/pitch_gain_tables.c",
413 "codecs/isac/main/source/pitch_gain_tables.h",
414 "codecs/isac/main/source/pitch_lag_tables.c",
415 "codecs/isac/main/source/pitch_lag_tables.h",
416 "codecs/isac/main/source/settings.h",
417 "codecs/isac/main/source/spectrum_ar_model_tables.c",
418 "codecs/isac/main/source/spectrum_ar_model_tables.h",
419 "codecs/isac/main/source/structs.h",
420 "codecs/isac/main/source/transform.c",
421 ]
422
423 if (is_linux) {
424 libs = [ "m" ]
425 }
426
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000427 configs += [ "../..:common_config" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000428
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000429 public_configs = [
430 "../..:common_inherited_config",
431 ":isac_config",
432 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000433
434 deps = [ "../../common_audio" ]
435}
436
437config("isac_fix_config") {
438 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000439 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000440 "codecs/isac/fix/interface",
441 ]
442}
443
444source_set("isacfix") {
445 sources = [
446 "codecs/isac/fix/interface/isacfix.h",
447 "codecs/isac/fix/source/arith_routines.c",
448 "codecs/isac/fix/source/arith_routines_hist.c",
449 "codecs/isac/fix/source/arith_routines_logist.c",
450 "codecs/isac/fix/source/arith_routins.h",
451 "codecs/isac/fix/source/bandwidth_estimator.c",
452 "codecs/isac/fix/source/bandwidth_estimator.h",
453 "codecs/isac/fix/source/codec.h",
454 "codecs/isac/fix/source/decode_bwe.c",
455 "codecs/isac/fix/source/decode.c",
456 "codecs/isac/fix/source/decode_plc.c",
457 "codecs/isac/fix/source/encode.c",
458 "codecs/isac/fix/source/entropy_coding.c",
459 "codecs/isac/fix/source/entropy_coding.h",
460 "codecs/isac/fix/source/fft.c",
461 "codecs/isac/fix/source/fft.h",
462 "codecs/isac/fix/source/filterbanks.c",
463 "codecs/isac/fix/source/filterbank_tables.c",
464 "codecs/isac/fix/source/filterbank_tables.h",
465 "codecs/isac/fix/source/filters.c",
466 "codecs/isac/fix/source/initialize.c",
467 "codecs/isac/fix/source/isacfix.c",
468 "codecs/isac/fix/source/lattice.c",
469 "codecs/isac/fix/source/lpc_masking_model.c",
470 "codecs/isac/fix/source/lpc_masking_model.h",
471 "codecs/isac/fix/source/lpc_tables.c",
472 "codecs/isac/fix/source/lpc_tables.h",
473 "codecs/isac/fix/source/pitch_estimator.c",
474 "codecs/isac/fix/source/pitch_estimator.h",
475 "codecs/isac/fix/source/pitch_filter.c",
476 "codecs/isac/fix/source/pitch_gain_tables.c",
477 "codecs/isac/fix/source/pitch_gain_tables.h",
478 "codecs/isac/fix/source/pitch_lag_tables.c",
479 "codecs/isac/fix/source/pitch_lag_tables.h",
480 "codecs/isac/fix/source/settings.h",
481 "codecs/isac/fix/source/spectrum_ar_model_tables.c",
482 "codecs/isac/fix/source/spectrum_ar_model_tables.h",
483 "codecs/isac/fix/source/structs.h",
484 "codecs/isac/fix/source/transform.c",
485 "codecs/isac/fix/source/transform_tables.c",
486 ]
487
488 if (!is_win) {
489 defines = [ "WEBRTC_LINUX" ]
490 }
491
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000492 configs += [ "../..:common_config" ]
493
494 public_configs = [
495 "../..:common_inherited_config",
496 ":isac_fix_config",
497 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000498
499 deps = [
500 "../../common_audio",
501 "../../system_wrappers",
502 ]
503
kjellander@webrtc.org6d08ca62014-09-07 17:36:10 +0000504 if (rtc_build_armv7_neon) {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000505 deps += [ ":isac_neon" ]
506
507 # Enable compilation for the ARM v7 Neon instruction set. This is needed
508 # since //build/config/arm.gni only enables Neon for iOS, not Android.
509 # This provides the same functionality as webrtc/build/arm_neon.gypi.
510 # TODO(kjellander): Investigate if this can be moved into webrtc.gni or
511 # //build/config/arm.gni instead, to reduce code duplication.
512 # Remove the -mfpu=vfpv3-d16 cflag.
513 configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
514 cflags = [
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000515 "-mfpu=neon",
516 ]
517
518 sources += [
519 "codecs/isac/fix/source/lattice_armv7.S",
520 "codecs/isac/fix/source/pitch_filter_armv6.S",
521 ]
522 } else {
523 sources += [ "codecs/isac/fix/source/pitch_filter_c.c" ]
524 }
525
526 if (cpu_arch == "mipsel") {
527 sources += [
528 "codecs/isac/fix/source/entropy_coding_mips.c",
529 "codecs/isac/fix/source/filters_mips.c",
530 "codecs/isac/fix/source/lattice_mips.c",
531 "codecs/isac/fix/source/pitch_estimator_mips.c",
532 "codecs/isac/fix/source/transform_mips.c",
533 ]
534 if (mips_dsp_rev > 0) {
535 sources += [ "codecs/isac/fix/source/filterbanks_mips.c" ]
536 }
537 if (mips_dsp_rev > 1) {
538 sources += [
539 "codecs/isac/fix/source/lpc_masking_model_mips.c",
540 "codecs/isac/fix/source/pitch_filter_mips.c",
541 ]
542 } else {
543 sources += [ "codecs/isac/fix/source/pitch_filter_c.c" ]
544 }
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000545 } else {
546 sources += [ "codecs/isac/fix/source/pitch_estimator_c.c" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000547 }
548
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000549 if (!rtc_build_armv7_neon && cpu_arch != "mipsel") {
550 sources += [ "codecs/isac/fix/source/lattice_c.c" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000551 }
552}
553
kjellander@webrtc.org6d08ca62014-09-07 17:36:10 +0000554if (rtc_build_armv7_neon) {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000555 source_set("isac_neon") {
556 sources = [
557 "codecs/isac/fix/source/entropy_coding_neon.c",
558 "codecs/isac/fix/source/filterbanks_neon.S",
559 "codecs/isac/fix/source/filters_neon.S",
560 "codecs/isac/fix/source/lattice_neon.S",
561 "codecs/isac/fix/source/lpc_masking_model_neon.S",
562 "codecs/isac/fix/source/transform_neon.S",
563 ]
564
565 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000566 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000567 ]
568
569 # Disable LTO in audio_processing_neon target due to compiler bug.
kjellander@webrtc.org6d08ca62014-09-07 17:36:10 +0000570 if (rtc_use_lto) {
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000571 cflags -= [
572 "-flto",
573 "-ffat-lto-objects",
574 ]
575 }
576
577 # Enable compilation for the ARM v7 Neon instruction set. This is needed
578 # since //build/config/arm.gni only enables Neon for iOS, not Android.
579 # This provides the same functionality as webrtc/build/arm_neon.gypi.
580 # TODO(kjellander): Investigate if this can be moved into webrtc.gni or
581 # //build/config/arm.gni instead, to reduce code duplication.
582 # Remove the -mfpu=vfpv3-d16 cflag.
583 configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
584 cflags = [
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000585 "-mfpu=neon",
586 ]
587
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000588 configs += [ "../..:common_config" ]
589 public_configs = [ "../..:common_inherited_config" ]
590
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000591 deps = [ "../../common_audio" ]
592 }
593}
594
595config("pcm16b_config") {
596 include_dirs = [
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000597 "../../..",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000598 "codecs/pcm16b/include",
599 ]
600}
601
602source_set("pcm16b") {
603 sources = [
604 "codecs/pcm16b/include/pcm16b.h",
605 "codecs/pcm16b/pcm16b.c",
606 ]
607
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000608 configs += [ "../..:common_config" ]
609
610 public_configs = [
611 "../..:common_inherited_config",
612 ":pcm16b_config",
613 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000614}
615
616config("opus_config") {
andresp@webrtc.org262e6762014-09-04 13:28:48 +0000617 include_dirs = [ "../../.." ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000618}
619
620source_set("webrtc_opus") {
621 sources = [
kwiberg@webrtc.org663fdd02014-10-29 07:28:36 +0000622 "codecs/opus/audio_encoder_opus.cc",
623 "codecs/opus/interface/audio_encoder_opus.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000624 "codecs/opus/interface/opus_interface.h",
625 "codecs/opus/opus_inst.h",
626 "codecs/opus/opus_interface.c",
627 ]
628 if (build_with_mozilla) {
629 include_dirs = [ getenv("DIST") + "/include/opus" ]
630 } else {
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000631 configs += [ "../..:common_config" ]
632 public_configs = [ "../..:common_inherited_config" ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000633
634 deps = [ "//third_party/opus" ]
635 }
636}
637
638config("neteq_config") {
639 include_dirs = [
640 # Need Opus header files for the audio classifier.
641 "//third_party/opus/src/celt",
642 "//third_party/opus/src/src",
643 ]
644}
645
646source_set("neteq") {
647 sources = [
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000648 "neteq/interface/neteq.h",
649 "neteq/accelerate.cc",
650 "neteq/accelerate.h",
651 "neteq/audio_classifier.cc",
652 "neteq/audio_classifier.h",
653 "neteq/audio_decoder_impl.cc",
654 "neteq/audio_decoder_impl.h",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000655 "neteq/audio_multi_vector.cc",
656 "neteq/audio_multi_vector.h",
657 "neteq/audio_vector.cc",
658 "neteq/audio_vector.h",
659 "neteq/background_noise.cc",
660 "neteq/background_noise.h",
661 "neteq/buffer_level_filter.cc",
662 "neteq/buffer_level_filter.h",
663 "neteq/comfort_noise.cc",
664 "neteq/comfort_noise.h",
665 "neteq/decision_logic.cc",
666 "neteq/decision_logic.h",
667 "neteq/decision_logic_fax.cc",
668 "neteq/decision_logic_fax.h",
669 "neteq/decision_logic_normal.cc",
670 "neteq/decision_logic_normal.h",
671 "neteq/decoder_database.cc",
672 "neteq/decoder_database.h",
673 "neteq/defines.h",
674 "neteq/delay_manager.cc",
675 "neteq/delay_manager.h",
676 "neteq/delay_peak_detector.cc",
677 "neteq/delay_peak_detector.h",
678 "neteq/dsp_helper.cc",
679 "neteq/dsp_helper.h",
680 "neteq/dtmf_buffer.cc",
681 "neteq/dtmf_buffer.h",
682 "neteq/dtmf_tone_generator.cc",
683 "neteq/dtmf_tone_generator.h",
684 "neteq/expand.cc",
685 "neteq/expand.h",
686 "neteq/merge.cc",
687 "neteq/merge.h",
688 "neteq/neteq_impl.cc",
689 "neteq/neteq_impl.h",
690 "neteq/neteq.cc",
691 "neteq/statistics_calculator.cc",
692 "neteq/statistics_calculator.h",
693 "neteq/normal.cc",
694 "neteq/normal.h",
695 "neteq/packet_buffer.cc",
696 "neteq/packet_buffer.h",
697 "neteq/payload_splitter.cc",
698 "neteq/payload_splitter.h",
699 "neteq/post_decode_vad.cc",
700 "neteq/post_decode_vad.h",
701 "neteq/preemptive_expand.cc",
702 "neteq/preemptive_expand.h",
703 "neteq/random_vector.cc",
704 "neteq/random_vector.h",
705 "neteq/rtcp.cc",
706 "neteq/rtcp.h",
707 "neteq/sync_buffer.cc",
708 "neteq/sync_buffer.h",
709 "neteq/timestamp_scaler.cc",
710 "neteq/timestamp_scaler.h",
711 "neteq/time_stretch.cc",
712 "neteq/time_stretch.h",
713 ]
714
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +0000715 configs += [ "../..:common_config" ]
716
717 public_configs = [
718 "../..:common_inherited_config",
719 ":neteq_config",
720 ]
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000721
722 forward_dependent_configs_from = [ "//third_party/opus" ]
723
724 if (is_clang) {
725 # Suppress warnings from Chrome's Clang plugins.
726 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
727 configs -= [ "//build/config/clang:find_bad_constructs" ]
728 }
729
730 deps = [
kwiberg@webrtc.orge04a93b2014-12-09 10:12:53 +0000731 ":audio_decoder_interface",
kjellander@webrtc.org524b8f72014-08-31 20:32:53 +0000732 ":cng",
733 ":g711",
734 ":g722",
735 ":ilbc",
736 ":isac",
737 ":isacfix",
738 ":pcm16b",
739 "../../common_audio",
740 "../../system_wrappers",
741 "//third_party/opus",
742 ]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +0000743}