From b1dc4e43f0acfa678b8c9ac0b5f9976382807704 Mon Sep 17 00:00:00 2001 From: Florent Castelli Date: Thu, 14 Apr 2022 13:20:12 +0200 Subject: [PATCH] Move timestamp_aligner out of rtc_base_approved Bug: webrtc:9838 Change-Id: I4ea34fd161e321f6506f300abfd27c4be6d785d7 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/258766 Reviewed-by: Harald Alvestrand Commit-Queue: Florent Castelli Cr-Commit-Position: refs/heads/main@{#36580} --- modules/audio_device/BUILD.gn | 1 + rtc_base/BUILD.gn | 25 +++++++++++++++++++++++-- sdk/BUILD.gn | 1 + sdk/android/BUILD.gn | 1 + 4 files changed, 26 insertions(+), 2 deletions(-) diff --git a/modules/audio_device/BUILD.gn b/modules/audio_device/BUILD.gn index b745c977bb..ad9b49ee53 100644 --- a/modules/audio_device/BUILD.gn +++ b/modules/audio_device/BUILD.gn @@ -77,6 +77,7 @@ rtc_library("audio_device_buffer") { "../../rtc_base:rtc_base_approved", "../../rtc_base:rtc_task_queue", "../../rtc_base:safe_conversions", + "../../rtc_base:timestamp_aligner", "../../rtc_base:timeutils", "../../rtc_base/synchronization:mutex", "../../system_wrappers", diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn index 20a864de03..1073d81dd8 100644 --- a/rtc_base/BUILD.gn +++ b/rtc_base/BUILD.gn @@ -95,6 +95,7 @@ rtc_library("rtc_base_approved") { ":safe_conversions", ":stringutils", ":strong_alias", + ":timestamp_aligner", ":timeutils", ":type_traits", "../api:array_view", @@ -143,8 +144,7 @@ rtc_library("rtc_base_approved") { "rate_tracker.h", "strong_alias.h", # Transitional, use :strong_alias "swap_queue.h", - "timestamp_aligner.cc", - "timestamp_aligner.h", + "timestamp_aligner.h", # Transitional, use :timestamp_aligner "trace_event.h", "zero_memory.cc", "zero_memory.h", @@ -180,6 +180,12 @@ rtc_library("rtc_base_approved") { if (is_android) { libs = [ "log" ] } + + if (build_with_chromium) { + # Remove when the dependency has been propagated to Chromium + public_deps += # no-presubmit-check TODO(webrtc:8603) + [ ":timestamp_aligner" ] + } } rtc_source_set("one_time_event") { @@ -223,6 +229,20 @@ rtc_library("random") { ] } +rtc_library("timestamp_aligner") { + visibility = [ "*" ] + sources = [ + "timestamp_aligner.cc", + "timestamp_aligner.h", + ] + deps = [ + ":checks", + ":logging", + ":timeutils", + "system:rtc_export", + ] +} + rtc_library("platform_thread_types") { sources = [ "platform_thread_types.cc", @@ -1473,6 +1493,7 @@ if (rtc_include_tests) { ":strong_alias", ":testclient", ":threading", + ":timestamp_aligner", ":timeutils", "../api:array_view", "../api:scoped_refptr", diff --git a/sdk/BUILD.gn b/sdk/BUILD.gn index 0f23dd9ca7..aac15cbfc8 100644 --- a/sdk/BUILD.gn +++ b/sdk/BUILD.gn @@ -1660,6 +1660,7 @@ if (is_ios || is_mac) { "../rtc_base", "../rtc_base:checks", "../rtc_base:logging", + "../rtc_base:timestamp_aligner", "../rtc_base:timeutils", ] } diff --git a/sdk/android/BUILD.gn b/sdk/android/BUILD.gn index 2cc5a8496e..8ff0f8aad7 100644 --- a/sdk/android/BUILD.gn +++ b/sdk/android/BUILD.gn @@ -699,6 +699,7 @@ if (current_os == "linux" || is_android) { "../../rtc_base:rtc_task_queue", "../../rtc_base:safe_conversions", "../../rtc_base:threading", + "../../rtc_base:timestamp_aligner", "../../rtc_base:timeutils", "../../rtc_base/synchronization:mutex", "../../rtc_base/task_utils:to_queued_task",