APM: Add build flag to allow building WebRTC without APM
This CL adds a build flag to allow building the non-test parts
of WebRTC without the audio processing module.
The CL also ensures that the WebRTC code correctly handles
the case when no APM is available.
Bug: webrtc:5298
Change-Id: I5c8b5d1f7115e5cce2af4c2b5ff701fa1c54e49e
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/171509
Commit-Queue: Per Åhgren <peah@webrtc.org>
Reviewed-by: Sam Zackrisson <saza@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31133}
diff --git a/BUILD.gn b/BUILD.gn
index 16ff697..85c428d 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -281,6 +281,10 @@
defines += [ "WEBRTC_EXCLUDE_TRANSIENT_SUPPRESSOR" ]
}
+ if (rtc_exclude_audio_processing_module) {
+ defines += [ "WEBRTC_EXCLUDE_AUDIO_PROCESSING_MODULE" ]
+ }
+
cflags = []
if (build_with_chromium) {