blob: 6274ded44aca322782725562a5b8c198f174f396 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
From a5a6050ed551972faaaa65ebc2b4e7e1958738a1 Mon Sep 17 00:00:00 2001
From: Stephan Hartmann <stha09@googlemail.com>
Date: Fri, 6 Nov 2020 16:17:30 +0000
Subject: [PATCH] fix building without Ozone
When building with use_x11=true and use_ozone=false build fails,
because features::IsUsingOzonePlatform() is not defined:
../../content/browser/gpu/gpu_internals_ui.cc: In function
'std::unique_ptr<base::ListValue>
content::{anonymous}::GpuMemoryBufferInfo(const gfx::GpuExtraInfo&)'
../../content/browser/gpu/gpu_internals_ui.cc:397:18: error:
'IsUsingOzonePlatform' is not a member of 'features'
397 | if (!features::IsUsingOzonePlatform()) {
| ^~~~~~~~~~~~~~~~~~~~
---
content/browser/gpu/gpu_internals_ui.cc | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/content/browser/gpu/gpu_internals_ui.cc b/content/browser/gpu/gpu_internals_ui.cc
index 4f07186..01dfcbf 100644
--- a/content/browser/gpu/gpu_internals_ui.cc
+++ b/content/browser/gpu/gpu_internals_ui.cc
@@ -394,7 +394,12 @@ std::unique_ptr<base::ListValue> GpuMemoryBufferInfo(
gpu::GpuMemoryBufferConfigurationSet native_config;
#if defined(USE_X11)
- if (!features::IsUsingOzonePlatform()) {
+#if defined(USE_OZONE)
+ const auto is_using_ozone_platform = features::IsUsingOzonePlatform();
+#else
+ const auto is_using_ozone_platform = false;
+#endif
+ if (!is_using_ozone_platform) {
for (const auto& config : gpu_extra_info.gpu_memory_buffer_support_x11) {
native_config.emplace(config);
}
--
2.26.2
|