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/ui.gni") | 5 import("//build/config/ui.gni") |
6 | 6 |
| 7 declare_args() { |
| 8 # Use the PCI lib to collect GPU information on Linux. |
| 9 use_libpci = true |
| 10 } |
| 11 |
7 source_set("config") { | 12 source_set("config") { |
8 sources = [ | 13 sources = [ |
9 "dx_diag_node.cc", | 14 "dx_diag_node.cc", |
10 "dx_diag_node.h", | 15 "dx_diag_node.h", |
11 "gpu_blacklist.cc", | 16 "gpu_blacklist.cc", |
12 "gpu_blacklist.h", | 17 "gpu_blacklist.h", |
13 "gpu_control_list_jsons.h", | 18 "gpu_control_list_jsons.h", |
14 "gpu_control_list.cc", | 19 "gpu_control_list.cc", |
15 "gpu_control_list.h", | 20 "gpu_control_list.h", |
16 "gpu_driver_bug_list_json.cc", | 21 "gpu_driver_bug_list_json.cc", |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
55 deps += [ "//third_party/libxml" ] | 60 deps += [ "//third_party/libxml" ] |
56 libs = [ "dxguid.lib", "setupapi.lib" ] | 61 libs = [ "dxguid.lib", "setupapi.lib" ] |
57 | 62 |
58 if (is_chrome_branded && is_official_build) { | 63 if (is_chrome_branded && is_official_build) { |
59 sources += [ | 64 sources += [ |
60 "//third_party/amd/AmdCfxPxExt.h", | 65 "//third_party/amd/AmdCfxPxExt.h", |
61 "//third_party/amd/amd_videocard_info_win.cc", | 66 "//third_party/amd/amd_videocard_info_win.cc", |
62 ] | 67 ] |
63 } | 68 } |
64 } | 69 } |
65 if (is_linux && (use_x11 || use_ozone)) { | 70 if (use_libpci) { |
| 71 defines += [ "USE_LIBPCI=1" ] |
| 72 } |
| 73 if (is_linux && use_libpci && (use_x11 || use_ozone)) { |
66 deps += [ | 74 deps += [ |
67 "//build/config/linux:libpci", | 75 "//build/config/linux:libpci", |
68 ] | 76 ] |
69 } | 77 } |
70 if (is_linux && use_x11) { | 78 if (is_linux && use_x11) { |
71 configs += [ | 79 configs += [ |
72 "//build/config/linux:x11", | 80 "//build/config/linux:x11", |
73 "//build/config/linux:xext", | 81 "//build/config/linux:xext", |
74 ] | 82 ] |
75 deps += [ | 83 deps += [ |
76 "//third_party/libXNVCtrl", | 84 "//third_party/libXNVCtrl", |
77 ] | 85 ] |
78 } else { | 86 } else { |
79 sources -= [ "gpu_info_collector_x11.cc" ] | 87 sources -= [ "gpu_info_collector_x11.cc" ] |
80 } | 88 } |
81 if (!use_ozone) { | 89 if (!use_ozone) { |
82 sources -= [ "gpu_info_collector_ozone.cc" ] | 90 sources -= [ "gpu_info_collector_ozone.cc" ] |
83 } | 91 } |
84 } | 92 } |
85 | 93 |
OLD | NEW |