OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/config/chromecast_build.gni") | 5 import("//build/config/chromecast_build.gni") |
6 import("//build/config/ui.gni") | 6 import("//build/config/ui.gni") |
7 | 7 |
8 declare_args() { | 8 declare_args() { |
9 # Select platforms automatically. Turn this off for manual control. | 9 # Select platforms automatically. Turn this off for manual control. |
10 ozone_auto_platforms = use_ozone | 10 ozone_auto_platforms = use_ozone |
(...skipping 15 matching lines...) Expand all Loading... |
26 ozone_platform_gbm = false | 26 ozone_platform_gbm = false |
27 ozone_platform_headless = false | 27 ozone_platform_headless = false |
28 ozone_platform_x11 = false | 28 ozone_platform_x11 = false |
29 ozone_platform_wayland = false | 29 ozone_platform_wayland = false |
30 | 30 |
31 if (ozone_auto_platforms) { | 31 if (ozone_auto_platforms) { |
32 # Use headless as the default platform. | 32 # Use headless as the default platform. |
33 ozone_platform = "headless" | 33 ozone_platform = "headless" |
34 ozone_platform_headless = true | 34 ozone_platform_headless = true |
35 | 35 |
36 if (is_chromecast) { | 36 if (is_cast_audio_only) { |
| 37 # Just use headless for audio-only Cast platforms. |
| 38 } else if (is_chromecast) { |
37 # Enable the Cast ozone platform on all A/V Cast builds. | 39 # Enable the Cast ozone platform on all A/V Cast builds. |
38 ozone_platform_cast = true | 40 ozone_platform_cast = true |
39 | 41 |
40 # For visual desktop Chromecast builds, override the default "headless" | 42 # For visual desktop Chromecast builds, override the default "headless" |
41 # platform with --ozone-platform=x11. | 43 # platform with --ozone-platform=x11. |
42 # TODO(halliwell): Create a libcast_graphics implementation for desktop | 44 # TODO(halliwell): Create a libcast_graphics implementation for desktop |
43 # using X11, and disable this platform. | 45 # using X11, and disable this platform. |
44 if (is_cast_desktop_build && !is_cast_audio_only) { | 46 if (is_cast_desktop_build && !is_cast_audio_only) { |
45 ozone_platform_x11 = true | 47 ozone_platform_x11 = true |
46 } else { | 48 } else { |
47 ozone_platform = "cast" | 49 ozone_platform = "cast" |
48 } | 50 } |
49 } else if (is_chromeos) { | 51 } else if (is_chromeos) { |
50 ozone_platform_gbm = true | 52 ozone_platform_gbm = true |
51 ozone_platform_x11 = true | 53 ozone_platform_x11 = true |
52 ozone_platform_wayland = true | 54 ozone_platform_wayland = true |
53 } else if (is_desktop_linux) { | 55 } else if (is_desktop_linux) { |
54 ozone_platform_wayland = true | 56 ozone_platform_wayland = true |
55 ozone_platform_x11 = true | 57 ozone_platform_x11 = true |
56 } | 58 } |
57 } | 59 } |
58 } | 60 } |
59 | 61 |
60 assert(use_ozone || !(ozone_platform_cast || ozone_platform_gbm || | 62 assert(use_ozone || !(ozone_platform_cast || ozone_platform_gbm || |
61 ozone_platform_headless || ozone_platform_x11 || | 63 ozone_platform_headless || ozone_platform_x11 || |
62 ozone_platform_wayland), | 64 ozone_platform_wayland), |
63 "Must set use_ozone to select ozone platforms") | 65 "Must set use_ozone to select ozone platforms") |
OLD | NEW |