blob: ca9a14a324534f36e21d92a7c1550502d83bdff9 [file] [log] [blame]
Sebastian Janssonecb68972019-01-18 10:30:54 +01001# Copyright (c) 2019 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
9import("../../webrtc.gni")
10
Mirko Bonadei86d053c2019-10-17 21:32:04 +020011rtc_library("repeating_task") {
Sebastian Janssonecb68972019-01-18 10:30:54 +010012 sources = [
13 "repeating_task.cc",
14 "repeating_task.h",
15 ]
16 deps = [
Danil Chapovalov4423c362019-03-06 18:41:39 +010017 ":to_queued_task",
Sebastian Janssonecb68972019-01-18 10:30:54 +010018 "..:logging",
Sebastian Janssonecb68972019-01-18 10:30:54 +010019 "..:timeutils",
Artem Titovd15a5752021-02-10 14:31:24 +010020 "../../api:sequence_checker",
Danil Chapovalov4423c362019-03-06 18:41:39 +010021 "../../api/task_queue",
Sebastian Janssonecb68972019-01-18 10:30:54 +010022 "../../api/units:time_delta",
23 "../../api/units:timestamp",
Tommi532cac52020-05-18 14:53:42 +020024 "../../system_wrappers:system_wrappers",
Sebastian Janssonecb68972019-01-18 10:30:54 +010025 ]
Mirko Bonadei2dcf3482020-06-05 14:30:41 +020026 absl_deps = [ "//third_party/abseil-cpp/absl/memory" ]
Sebastian Janssonecb68972019-01-18 10:30:54 +010027}
28
Tommi3c9bcc12020-04-15 16:45:47 +020029rtc_library("pending_task_safety_flag") {
30 sources = [
31 "pending_task_safety_flag.cc",
32 "pending_task_safety_flag.h",
33 ]
34 deps = [
35 "..:checks",
Tommi86ee89f2021-04-20 16:58:01 +020036 "../../api:refcountedbase",
Tommi3c9bcc12020-04-15 16:45:47 +020037 "../../api:scoped_refptr",
Artem Titovd15a5752021-02-10 14:31:24 +010038 "../../api:sequence_checker",
Mirko Bonadei20e4c802020-11-23 11:07:42 +010039 "../system:no_unique_address",
Tommi3c9bcc12020-04-15 16:45:47 +020040 ]
41}
42
Danil Chapovalov3b548dd2019-03-01 14:58:44 +010043rtc_source_set("to_queued_task") {
Mirko Bonadeiccbe95f2020-01-21 12:10:10 +010044 sources = [ "to_queued_task.h" ]
Tommi3c5450e2020-05-03 22:48:13 +020045 deps = [
46 ":pending_task_safety_flag",
47 "../../api/task_queue",
48 ]
Danil Chapovalov3b548dd2019-03-01 14:58:44 +010049}
50
Sebastian Janssonecb68972019-01-18 10:30:54 +010051if (rtc_include_tests) {
Tommi3c9bcc12020-04-15 16:45:47 +020052 rtc_library("pending_task_safety_flag_unittests") {
53 testonly = true
54 sources = [ "pending_task_safety_flag_unittest.cc" ]
55 deps = [
56 ":pending_task_safety_flag",
57 ":to_queued_task",
58 "..:rtc_base_approved",
59 "..:rtc_task_queue",
60 "..:task_queue_for_test",
61 "../../test:test_support",
62 ]
63 }
64
Mirko Bonadei86d053c2019-10-17 21:32:04 +020065 rtc_library("repeating_task_unittests") {
Sebastian Janssonecb68972019-01-18 10:30:54 +010066 testonly = true
Mirko Bonadeiccbe95f2020-01-21 12:10:10 +010067 sources = [ "repeating_task_unittest.cc" ]
Sebastian Janssonecb68972019-01-18 10:30:54 +010068 deps = [
69 ":repeating_task",
70 "..:rtc_base_approved",
Danil Chapovalov4423c362019-03-06 18:41:39 +010071 "..:rtc_task_queue",
Danil Chapovalov07122bc2019-03-26 14:37:01 +010072 "..:task_queue_for_test",
Sebastian Janssonecb68972019-01-18 10:30:54 +010073 "../../test:test_support",
Sebastian Janssonecb68972019-01-18 10:30:54 +010074 ]
75 }
Danil Chapovalov3b548dd2019-03-01 14:58:44 +010076
Mirko Bonadei86d053c2019-10-17 21:32:04 +020077 rtc_library("to_queued_task_unittests") {
Danil Chapovalov3b548dd2019-03-01 14:58:44 +010078 testonly = true
Mirko Bonadeiccbe95f2020-01-21 12:10:10 +010079 sources = [ "to_queued_task_unittest.cc" ]
Danil Chapovalov3b548dd2019-03-01 14:58:44 +010080 deps = [
81 ":to_queued_task",
82 "../../api/task_queue",
83 "../../test:test_support",
Danil Chapovalov3b548dd2019-03-01 14:58:44 +010084 ]
Mirko Bonadei2dcf3482020-06-05 14:30:41 +020085 absl_deps = [ "//third_party/abseil-cpp/absl/memory" ]
Danil Chapovalov3b548dd2019-03-01 14:58:44 +010086 }
Sebastian Janssonecb68972019-01-18 10:30:54 +010087}