btolsch | 762c4da | 2018-03-19 12:27:00 -0700 | [diff] [blame] | 1 | # Copyright 2018 The Chromium Authors. All rights reserved. |
| 2 | # Use of this source code is governed by a BSD-style license that can be |
| 3 | # found in the LICENSE file. |
| 4 | |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 5 | import("//build_overrides/build.gni") |
mark a. foltz | 115345f | 2019-05-02 14:17:16 -0700 | [diff] [blame] | 6 | import("osp/build/config/services.gni") |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 7 | |
mark a. foltz | c28ca40 | 2018-07-19 16:11:32 -0700 | [diff] [blame] | 8 | # All compilable non-test targets in the repository (both executables and |
| 9 | # source_sets). |
btolsch | 9d6900c | 2018-05-30 18:22:53 -0700 | [diff] [blame] | 10 | group("gn_all") { |
mark a. foltz | c28ca40 | 2018-07-19 16:11:32 -0700 | [diff] [blame] | 11 | deps = [ |
mark a. foltz | eeef1da | 2019-11-06 13:40:18 -0800 | [diff] [blame] | 12 | "cast/common:certificate", |
| 13 | "cast/common:channel", |
btolsch | 9931e7a | 2020-02-26 15:50:20 -0800 | [diff] [blame] | 14 | "cast/common:public", |
btolsch | 3fb8481 | 2019-12-17 18:23:10 -0800 | [diff] [blame] | 15 | "cast/receiver:channel", |
mark a. foltz | eeef1da | 2019-11-06 13:40:18 -0800 | [diff] [blame] | 16 | "cast/sender:channel", |
Yuri Wiitala | 7d2583a | 2019-11-22 15:04:27 -0800 | [diff] [blame] | 17 | "cast/streaming:receiver", |
| 18 | "cast/streaming:sender", |
Ryan Keane | cdda2f6 | 2020-01-30 12:03:25 -0800 | [diff] [blame] | 19 | "discovery:common", |
Ryan Keane | bd5d0f0 | 2019-10-21 16:46:56 -0700 | [diff] [blame] | 20 | "discovery:dnssd", |
mark a. foltz | c2291e5 | 2019-11-05 15:59:33 -0800 | [diff] [blame] | 21 | "discovery:mdns", |
Ryan Keane | 697863a | 2019-12-26 10:31:20 -0800 | [diff] [blame] | 22 | "discovery:public", |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 23 | "platform", |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 24 | "third_party/abseil", |
mark a. foltz | 3fe4617 | 2019-09-18 05:50:30 -0700 | [diff] [blame] | 25 | "third_party/boringssl", |
| 26 | "third_party/jsoncpp", |
btolsch | e060aaf | 2020-02-20 14:55:18 -0800 | [diff] [blame] | 27 | "third_party/mozilla", |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 28 | "third_party/tinycbor", |
btolsch | 2666dd9 | 2020-01-10 15:07:49 -0800 | [diff] [blame] | 29 | "tools/cddl($host_toolchain)", |
Jordan Bayles | a26582d | 2019-07-10 14:44:58 -0700 | [diff] [blame] | 30 | "util", |
mark a. foltz | c28ca40 | 2018-07-19 16:11:32 -0700 | [diff] [blame] | 31 | ] |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 32 | |
Jordan Bayles | 64dcdb6 | 2020-09-25 15:43:30 -0700 | [diff] [blame] | 33 | # Mac OS X 10.15 is incompatible with the current version of QUIC. |
| 34 | if (!is_mac) { |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 35 | deps += [ |
Jordan Bayles | 64dcdb6 | 2020-09-25 15:43:30 -0700 | [diff] [blame] | 36 | "osp", |
| 37 | "osp/msgs", |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 38 | ] |
mark a. foltz | 3fe4617 | 2019-09-18 05:50:30 -0700 | [diff] [blame] | 39 | |
Jordan Bayles | 64dcdb6 | 2020-09-25 15:43:30 -0700 | [diff] [blame] | 40 | if (use_mdns_responder) { |
| 41 | deps += [ "osp/impl/discovery/mdns:mdns_demo" ] |
| 42 | } |
| 43 | |
| 44 | if (use_chromium_quic) { |
| 45 | deps += [ |
| 46 | "third_party/chromium_quic", |
| 47 | "third_party/chromium_quic:quic_demo_server", |
| 48 | "third_party/chromium_quic:quic_streaming_playback_controller", |
| 49 | ] |
| 50 | } |
| 51 | |
| 52 | if (use_chromium_quic && use_mdns_responder) { |
| 53 | deps += [ "osp:osp_demo" ] |
| 54 | } |
mark a. foltz | 3fe4617 | 2019-09-18 05:50:30 -0700 | [diff] [blame] | 55 | } |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 56 | |
| 57 | if (!build_with_chromium) { |
| 58 | deps += [ |
Jordan Bayles | ee059e9 | 2020-09-21 16:38:51 -0700 | [diff] [blame] | 59 | "cast/standalone_receiver:cast_receiver", |
| 60 | "cast/standalone_sender:cast_sender", |
btolsch | 2666dd9 | 2020-01-10 15:07:49 -0800 | [diff] [blame] | 61 | "third_party/protobuf:protoc($host_toolchain)", |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 62 | "third_party/zlib", |
| 63 | ] |
| 64 | } |
mark a. foltz | c28ca40 | 2018-07-19 16:11:32 -0700 | [diff] [blame] | 65 | } |
btolsch | b4893e6 | 2018-05-28 22:03:07 -0700 | [diff] [blame] | 66 | |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 67 | source_set("openscreen_unittests_all") { |
mark a. foltz | c28ca40 | 2018-07-19 16:11:32 -0700 | [diff] [blame] | 68 | testonly = true |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 69 | public_deps = [ |
mark a. foltz | eeef1da | 2019-11-06 13:40:18 -0800 | [diff] [blame] | 70 | "cast/common:unittests", |
btolsch | 3fb8481 | 2019-12-17 18:23:10 -0800 | [diff] [blame] | 71 | "cast/receiver:unittests", |
mark a. foltz | eeef1da | 2019-11-06 13:40:18 -0800 | [diff] [blame] | 72 | "cast/sender:unittests", |
Yuri Wiitala | 7d2583a | 2019-11-22 15:04:27 -0800 | [diff] [blame] | 73 | "cast/streaming:unittests", |
btolsch | 3fb8481 | 2019-12-17 18:23:10 -0800 | [diff] [blame] | 74 | "cast/test:unittests", |
mark a. foltz | 3fe4617 | 2019-09-18 05:50:30 -0700 | [diff] [blame] | 75 | "platform:unittests", |
btolsch | 2f2e7fa | 2019-03-29 16:48:49 -0700 | [diff] [blame] | 76 | "third_party/abseil", |
mark a. foltz | 3fe4617 | 2019-09-18 05:50:30 -0700 | [diff] [blame] | 77 | "util:unittests", |
btolsch | 762c4da | 2018-03-19 12:27:00 -0700 | [diff] [blame] | 78 | ] |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 79 | |
Ryan Keane | 3c39611 | 2020-04-28 14:24:43 -0700 | [diff] [blame] | 80 | if (!build_with_chromium && is_posix) { |
Jordan Bayles | 53a6a13 | 2020-09-26 15:36:18 -0700 | [diff] [blame^] | 81 | public_deps += [ |
| 82 | "cast/test:make_crl_tests($host_toolchain)", |
| 83 | |
| 84 | # TODO(crbug.com/1132604): Discovery unittests fail in Chrome. |
| 85 | "discovery:unittests", |
| 86 | ] |
Ryan Keane | 3c39611 | 2020-04-28 14:24:43 -0700 | [diff] [blame] | 87 | } |
| 88 | |
Jordan Bayles | 64dcdb6 | 2020-09-25 15:43:30 -0700 | [diff] [blame] | 89 | if (!is_mac) { |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 90 | public_deps += [ |
Jordan Bayles | 64dcdb6 | 2020-09-25 15:43:30 -0700 | [diff] [blame] | 91 | "osp:unittests", |
| 92 | "osp/msgs:unittests", |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 93 | ] |
Jordan Bayles | 64dcdb6 | 2020-09-25 15:43:30 -0700 | [diff] [blame] | 94 | |
| 95 | if (use_mdns_responder) { |
| 96 | public_deps += [ |
| 97 | "osp/impl/discovery/mdns:unittests", |
| 98 | |
| 99 | # Currently this target only includes mDNS tests. |
| 100 | "osp/impl/testing:unittests", |
| 101 | ] |
| 102 | } |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 103 | } |
| 104 | } |
| 105 | |
| 106 | if (!build_with_chromium) { |
| 107 | executable("openscreen_unittests") { |
| 108 | testonly = true |
Jordan Bayles | f318b72 | 2020-06-23 15:32:13 -0700 | [diff] [blame] | 109 | deps = [ |
| 110 | ":openscreen_unittests_all", |
| 111 | "test:test_main", |
| 112 | ] |
Jordan Bayles | 21b5adc | 2019-10-25 12:01:20 -0700 | [diff] [blame] | 113 | } |
btolsch | 762c4da | 2018-03-19 12:27:00 -0700 | [diff] [blame] | 114 | } |
Ryan Keane | 809e0df | 2020-02-10 12:33:44 -0800 | [diff] [blame] | 115 | |
| 116 | if (!build_with_chromium && is_posix) { |
Jordan Bayles | 6b138fb | 2020-02-11 15:15:38 -0800 | [diff] [blame] | 117 | source_set("e2e_tests_all") { |
| 118 | testonly = true |
| 119 | public_deps = [ |
| 120 | "cast/common:discovery_e2e_test", |
Jordan Bayles | 3275593 | 2020-04-27 12:02:29 -0700 | [diff] [blame] | 121 | "cast/standalone_receiver:e2e_tests", |
btolsch | 1aa8826 | 2020-03-16 18:06:20 -0700 | [diff] [blame] | 122 | "cast/test:e2e_tests", |
Ryan Keane | 3c39611 | 2020-04-28 14:24:43 -0700 | [diff] [blame] | 123 | "cast/test:make_crl_tests($host_toolchain)", |
Jordan Bayles | 6b138fb | 2020-02-11 15:15:38 -0800 | [diff] [blame] | 124 | ] |
| 125 | } |
| 126 | |
Ryan Keane | 809e0df | 2020-02-10 12:33:44 -0800 | [diff] [blame] | 127 | executable("e2e_tests") { |
| 128 | testonly = true |
Jordan Bayles | f318b72 | 2020-06-23 15:32:13 -0700 | [diff] [blame] | 129 | deps = [ |
| 130 | ":e2e_tests_all", |
| 131 | "test:test_main", |
| 132 | ] |
Ryan Keane | 809e0df | 2020-02-10 12:33:44 -0800 | [diff] [blame] | 133 | } |
| 134 | } |