andrew@webrtc.org | b9d7d93 | 2012-01-25 19:21:13 +0000 | [diff] [blame] | 1 | # Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 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 | |
| 9 | { |
andrew@webrtc.org | b073010 | 2013-11-11 17:20:27 +0000 | [diff] [blame] | 10 | 'variables': { |
| 11 | 'audio_processing_dependencies': [ |
| 12 | '<(webrtc_root)/common_audio/common_audio.gyp:common_audio', |
| 13 | '<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers', |
| 14 | ], |
michaelbai@google.com | 82ebb46 | 2014-02-11 04:48:27 +0000 | [diff] [blame] | 15 | 'shared_generated_dir': '<(SHARED_INTERMEDIATE_DIR)/audio_processing/asm_offsets', |
andrew@webrtc.org | b073010 | 2013-11-11 17:20:27 +0000 | [diff] [blame] | 16 | }, |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 17 | 'targets': [ |
| 18 | { |
| 19 | 'target_name': 'audio_processing', |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 20 | 'type': 'static_library', |
| 21 | 'variables': { |
| 22 | # Outputs some low-level debug files. |
| 23 | 'aec_debug_dump%': 0, |
andrew@webrtc.org | 1760a17 | 2013-09-25 23:17:38 +0000 | [diff] [blame] | 24 | |
| 25 | # Disables the usual mode where we trust the reported system delay |
| 26 | # values the AEC receives. The corresponding define is set appropriately |
| 27 | # in the code, but it can be force-enabled here for testing. |
| 28 | 'aec_untrusted_delay_for_testing%': 0, |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 29 | }, |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 30 | 'dependencies': [ |
andrew@webrtc.org | b073010 | 2013-11-11 17:20:27 +0000 | [diff] [blame] | 31 | '<@(audio_processing_dependencies)', |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 32 | ], |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 33 | 'sources': [ |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 34 | 'aec/include/echo_cancellation.h', |
| 35 | 'aec/echo_cancellation.c', |
| 36 | 'aec/echo_cancellation_internal.h', |
| 37 | 'aec/aec_core.h', |
| 38 | 'aec/aec_core.c', |
bjornv@webrtc.org | 56a9ec3 | 2013-02-20 22:38:47 +0000 | [diff] [blame] | 39 | 'aec/aec_core_internal.h', |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 40 | 'aec/aec_rdft.h', |
| 41 | 'aec/aec_rdft.c', |
| 42 | 'aec/aec_resampler.h', |
| 43 | 'aec/aec_resampler.c', |
| 44 | 'aecm/include/echo_control_mobile.h', |
| 45 | 'aecm/echo_control_mobile.c', |
| 46 | 'aecm/aecm_core.c', |
| 47 | 'aecm/aecm_core.h', |
| 48 | 'agc/include/gain_control.h', |
| 49 | 'agc/analog_agc.c', |
| 50 | 'agc/analog_agc.h', |
| 51 | 'agc/digital_agc.c', |
| 52 | 'agc/digital_agc.h', |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 53 | 'audio_buffer.cc', |
| 54 | 'audio_buffer.h', |
| 55 | 'audio_processing_impl.cc', |
| 56 | 'audio_processing_impl.h', |
andrew@webrtc.org | ddbb8a2 | 2014-04-22 21:00:04 +0000 | [diff] [blame] | 57 | 'common.h', |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 58 | 'echo_cancellation_impl.cc', |
| 59 | 'echo_cancellation_impl.h', |
| 60 | 'echo_control_mobile_impl.cc', |
| 61 | 'echo_control_mobile_impl.h', |
| 62 | 'gain_control_impl.cc', |
| 63 | 'gain_control_impl.h', |
| 64 | 'high_pass_filter_impl.cc', |
| 65 | 'high_pass_filter_impl.h', |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 66 | 'include/audio_processing.h', |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 67 | 'level_estimator_impl.cc', |
| 68 | 'level_estimator_impl.h', |
| 69 | 'noise_suppression_impl.cc', |
| 70 | 'noise_suppression_impl.h', |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 71 | 'processing_component.cc', |
| 72 | 'processing_component.h', |
andrew@webrtc.org | 382c0c2 | 2014-05-05 18:22:21 +0000 | [diff] [blame] | 73 | 'rms_level.cc', |
| 74 | 'rms_level.h', |
henrikg@webrtc.org | c693704 | 2014-01-30 09:50:46 +0000 | [diff] [blame] | 75 | 'typing_detection.cc', |
| 76 | 'typing_detection.h', |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 77 | 'utility/delay_estimator.c', |
| 78 | 'utility/delay_estimator.h', |
| 79 | 'utility/delay_estimator_internal.h', |
| 80 | 'utility/delay_estimator_wrapper.c', |
| 81 | 'utility/delay_estimator_wrapper.h', |
| 82 | 'utility/fft4g.c', |
| 83 | 'utility/fft4g.h', |
| 84 | 'utility/ring_buffer.c', |
| 85 | 'utility/ring_buffer.h', |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 86 | 'voice_detection_impl.cc', |
| 87 | 'voice_detection_impl.h', |
| 88 | ], |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 89 | 'conditions': [ |
| 90 | ['aec_debug_dump==1', { |
| 91 | 'defines': ['WEBRTC_AEC_DEBUG_DUMP',], |
| 92 | }], |
andrew@webrtc.org | 1760a17 | 2013-09-25 23:17:38 +0000 | [diff] [blame] | 93 | ['aec_untrusted_delay_for_testing==1', { |
| 94 | 'defines': ['WEBRTC_UNTRUSTED_DELAY',], |
| 95 | }], |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 96 | ['enable_protobuf==1', { |
| 97 | 'dependencies': ['audioproc_debug_proto'], |
| 98 | 'defines': ['WEBRTC_AUDIOPROC_DEBUG_DUMP'], |
| 99 | }], |
| 100 | ['prefer_fixed_point==1', { |
| 101 | 'defines': ['WEBRTC_NS_FIXED'], |
| 102 | 'sources': [ |
| 103 | 'ns/include/noise_suppression_x.h', |
| 104 | 'ns/noise_suppression_x.c', |
| 105 | 'ns/nsx_core.c', |
| 106 | 'ns/nsx_core.h', |
| 107 | 'ns/nsx_defines.h', |
| 108 | ], |
andrew@webrtc.org | ea9392d | 2014-01-16 07:22:01 +0000 | [diff] [blame] | 109 | 'conditions': [ |
| 110 | ['target_arch=="mipsel"', { |
| 111 | 'sources': [ |
| 112 | 'ns/nsx_core_mips.c', |
| 113 | ], |
| 114 | }, { |
| 115 | 'sources': [ |
| 116 | 'ns/nsx_core_c.c', |
| 117 | ], |
| 118 | }], |
| 119 | ], |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 120 | }, { |
| 121 | 'defines': ['WEBRTC_NS_FLOAT'], |
| 122 | 'sources': [ |
| 123 | 'ns/defines.h', |
| 124 | 'ns/include/noise_suppression.h', |
| 125 | 'ns/noise_suppression.c', |
| 126 | 'ns/ns_core.c', |
| 127 | 'ns/ns_core.h', |
| 128 | 'ns/windows_private.h', |
| 129 | ], |
| 130 | }], |
| 131 | ['target_arch=="ia32" or target_arch=="x64"', { |
| 132 | 'dependencies': ['audio_processing_sse2',], |
| 133 | }], |
kjellander@webrtc.org | 917306d | 2013-12-10 09:26:07 +0000 | [diff] [blame] | 134 | ['(target_arch=="arm" and arm_version==7) or target_arch=="armv7"', { |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 135 | 'dependencies': ['audio_processing_neon',], |
| 136 | }], |
andrew@webrtc.org | e03cafa | 2013-11-11 20:10:01 +0000 | [diff] [blame] | 137 | ['target_arch=="mipsel"', { |
| 138 | 'sources': [ |
| 139 | 'aecm/aecm_core_mips.c', |
| 140 | ], |
andrew@webrtc.org | c0907ef | 2014-02-21 00:13:31 +0000 | [diff] [blame] | 141 | 'conditions': [ |
| 142 | ['mips_fpu==1', { |
| 143 | 'sources': [ |
| 144 | 'aec/aec_core_mips.c', |
| 145 | 'aec/aec_rdft_mips.c', |
| 146 | ], |
| 147 | }], |
| 148 | ], |
andrew@webrtc.org | e03cafa | 2013-11-11 20:10:01 +0000 | [diff] [blame] | 149 | }, { |
| 150 | 'sources': [ |
| 151 | 'aecm/aecm_core_c.c', |
| 152 | ], |
| 153 | }], |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 154 | ], |
andrew@webrtc.org | 63e0964 | 2013-01-29 06:45:22 +0000 | [diff] [blame] | 155 | # TODO(jschuh): Bug 1348: fix size_t to int truncations. |
| 156 | 'msvs_disabled_warnings': [ 4267, ], |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 157 | }, |
andrew@webrtc.org | 7bf2646 | 2011-12-03 00:03:31 +0000 | [diff] [blame] | 158 | ], |
| 159 | 'conditions': [ |
| 160 | ['enable_protobuf==1', { |
| 161 | 'targets': [ |
| 162 | { |
| 163 | 'target_name': 'audioproc_debug_proto', |
| 164 | 'type': 'static_library', |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 165 | 'sources': ['debug.proto',], |
andrew@webrtc.org | 7bf2646 | 2011-12-03 00:03:31 +0000 | [diff] [blame] | 166 | 'variables': { |
| 167 | 'proto_in_dir': '.', |
| 168 | # Workaround to protect against gyp's pathname relativization when |
| 169 | # this file is included by modules.gyp. |
| 170 | 'proto_out_protected': 'webrtc/audio_processing', |
| 171 | 'proto_out_dir': '<(proto_out_protected)', |
| 172 | }, |
andrew@webrtc.org | 8c4696c | 2012-09-08 19:27:24 +0000 | [diff] [blame] | 173 | 'includes': ['../../build/protoc.gypi',], |
| 174 | }, |
| 175 | ], |
| 176 | }], |
| 177 | ['target_arch=="ia32" or target_arch=="x64"', { |
| 178 | 'targets': [ |
| 179 | { |
| 180 | 'target_name': 'audio_processing_sse2', |
| 181 | 'type': 'static_library', |
| 182 | 'sources': [ |
| 183 | 'aec/aec_core_sse2.c', |
| 184 | 'aec/aec_rdft_sse2.c', |
| 185 | ], |
| 186 | 'cflags': ['-msse2',], |
| 187 | 'xcode_settings': { |
| 188 | 'OTHER_CFLAGS': ['-msse2',], |
| 189 | }, |
| 190 | }, |
| 191 | ], |
| 192 | }], |
kjellander@webrtc.org | 917306d | 2013-12-10 09:26:07 +0000 | [diff] [blame] | 193 | ['(target_arch=="arm" and arm_version==7) or target_arch=="armv7"', { |
kma@webrtc.org | 1245402 | 2012-11-07 22:34:31 +0000 | [diff] [blame] | 194 | 'targets': [{ |
| 195 | 'target_name': 'audio_processing_neon', |
| 196 | 'type': 'static_library', |
| 197 | 'includes': ['../../build/arm_neon.gypi',], |
| 198 | 'dependencies': [ |
andrew@webrtc.org | 3423537 | 2013-04-30 23:43:26 +0000 | [diff] [blame] | 199 | '<(webrtc_root)/common_audio/common_audio.gyp:common_audio', |
kma@webrtc.org | 1245402 | 2012-11-07 22:34:31 +0000 | [diff] [blame] | 200 | ], |
| 201 | 'sources': [ |
| 202 | 'aecm/aecm_core_neon.c', |
| 203 | 'ns/nsx_core_neon.c', |
| 204 | ], |
| 205 | 'conditions': [ |
kma@webrtc.org | 2f9bd24 | 2013-02-23 04:16:59 +0000 | [diff] [blame] | 206 | ['OS=="android" or OS=="ios"', { |
kma@webrtc.org | 1245402 | 2012-11-07 22:34:31 +0000 | [diff] [blame] | 207 | 'dependencies': [ |
michaelbai@google.com | 82ebb46 | 2014-02-11 04:48:27 +0000 | [diff] [blame] | 208 | '<(gen_core_neon_offsets_gyp):*', |
kma@webrtc.org | 1245402 | 2012-11-07 22:34:31 +0000 | [diff] [blame] | 209 | ], |
kma@webrtc.org | 1245402 | 2012-11-07 22:34:31 +0000 | [diff] [blame] | 210 | 'sources': [ |
| 211 | 'aecm/aecm_core_neon.S', |
| 212 | 'ns/nsx_core_neon.S', |
| 213 | ], |
michaelbai@google.com | 82ebb46 | 2014-02-11 04:48:27 +0000 | [diff] [blame] | 214 | 'include_dirs': [ |
| 215 | '<(shared_generated_dir)', |
| 216 | ], |
kma@webrtc.org | 1245402 | 2012-11-07 22:34:31 +0000 | [diff] [blame] | 217 | 'sources!': [ |
| 218 | 'aecm/aecm_core_neon.c', |
| 219 | 'ns/nsx_core_neon.c', |
| 220 | ], |
| 221 | 'includes!': ['../../build/arm_neon.gypi',], |
| 222 | }], |
| 223 | ], |
| 224 | }], |
andrew@webrtc.org | 7bf2646 | 2011-12-03 00:03:31 +0000 | [diff] [blame] | 225 | }], |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 226 | ], |
| 227 | } |