Roll src/third_party/WebKit d9c6159:8139f33 (svn 201974:201975)
[chromium-blink-merge.git] / chromecast / BUILD.gn
blob1862bf195abaf02818a7b4f4d651ba61c96a962f
1 # Copyright 2015 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.
5 import("//chromecast/chromecast.gni")
6 import("//build/config/features.gni")
7 import("//build/config/ui.gni")
8 import("//testing/test.gni")
9 import("//tools/grit/repack.gni")
10 import("//ui/ozone/ozone.gni")
12 # TODO(slan): This target is being used far too broadly. We should reduce the
13 # uses of this config to targets that actually need it. (b/23814594)
14 config("config") {
15   defines = []
17   if (use_playready) {
18     defines += [ "PLAYREADY_CDM_AVAILABLE" ]
19   }
22 component("chromecast") {
23   deps = [
24     "//chromecast/base",
25     "//chromecast/base/metrics",
26     "//chromecast/crash",
27     "//chromecast/media",
28   ]
31 group("chromecast_unittests") {
32   testonly = true
34   deps = [
35     # TODO(slan): Get this target building and comment it in.
36     # "//chromecast/app:cast_shell_unittests",
37     "//chromecast/base:cast_base_unittests",
38     "//chromecast/crypto:cast_crypto_unittests",
39     "//chromecast/crash:cast_crash_unittests",
40     "//chromecast/media:cast_media_unittests",
41   ]
44 source_set("cast_shell_common") {
45   deps = [
46     # TODO(slan): add ":cast_locales_pak" (b/22959691)
47     ":cast_shell_pak",
48     "//chromecast/app",
49     "//chromecast/browser",
50     "//chromecast/common",
51     "//chromecast/common/media",
52     "//chromecast/renderer",
53   ]
56 source_set("cast_shell_media") {
57   deps = [
58     "//chromecast/browser/media",
59     "//chromecast/common/media",
60     "//chromecast/renderer/media",
61   ]
64 executable("cast_shell") {
65   sources = [
66     "app/cast_main.cc",
67   ]
69   deps = [
70     ":cast_shell_common",
71     ":cast_shell_media",
72     "//build/config/sanitizers:deps",
73     "//chromecast/app",
74     "//content/public/app:both",
75   ]
77   if (ozone_platform_egltest) {
78     deps += [ "//ui/ozone/platform/egltest:eglplatform_shim_x11" ]
79   }
82 repack("cast_shell_pak") {
83   sources = [
84     "$root_gen_dir/blink/public/resources/blink_image_resources_100_percent.pak",
85     "$root_gen_dir/blink/public/resources/blink_resources.pak",
86     "$root_gen_dir/chromecast/app/shell_resources.pak",
87     "$root_gen_dir/content/app/resources/content_resources_100_percent.pak",
88     "$root_gen_dir/content/app/strings/content_strings_en-US.pak",
89     "$root_gen_dir/content/content_resources.pak",
90     "$root_gen_dir/net/net_resources.pak",
91     "$root_gen_dir/ui/resources/ui_resources_100_percent.pak",
92     "$root_gen_dir/ui/resources/webui_resources.pak",
93     "$root_gen_dir/ui/strings/app_locale_settings_en-US.pak",
94     "$root_gen_dir/ui/strings/ui_strings_en-US.pak",
95   ]
97   if (chromecast_branding != "public" && use_chromecast_webui) {
98     sources += [
99       # TODO(slan): Update these paths to be accurate for internal builds.
100     ]
101   }
103   output = "$root_out_dir/assets/cast_shell.pak"
105   deps = [
106     "//chromecast/app:resources",
107     "//content:resources",
108     "//content/app/resources",
109     "//content/app/strings",
110     "//net:net_resources",
111     "//third_party/WebKit/public:resources",
112     "//third_party/WebKit/public:image_resources_grit",
113     "//ui/resources",
114     "//ui/strings",
115   ]
117   if (chromecast_branding != "public" && use_chromecast_webui) {
118     deps += [
119       # TODO(slan): Update these paths to be accurate for internal builds.
120     ]
121   }