| 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("//tools/grit/grit_rule.gni") | 5 import("//tools/grit/grit_rule.gni") |
| 6 | 6 |
| 7 gypi_values = exec_script( | 7 gypi_values = exec_script("//build/gypi_to_gn.py", |
| 8 "//build/gypi_to_gn.py", | 8 [ rebase_path("../chrome_common.gypi") ], |
| 9 [ rebase_path("../chrome_common.gypi") ], | 9 "scope", |
| 10 "scope", | 10 [ "../chrome_common.gypi" ]) |
| 11 [ "../chrome_common.gypi" ]) | |
| 12 | 11 |
| 13 # GYP version: chrome/chrome_resources.gyp:chrome_resources | 12 # GYP version: chrome/chrome_resources.gyp:chrome_resources |
| 14 # (generate_common_resources action) | 13 # (generate_common_resources action) |
| 15 grit("resources") { | 14 grit("resources") { |
| 16 source = "common_resources.grd" | 15 source = "common_resources.grd" |
| 17 output_dir = "$root_gen_dir/chrome" | 16 output_dir = "$root_gen_dir/chrome" |
| 18 output_name = "common_resources" | 17 output_name = "common_resources" |
| 19 outputs = [ | 18 outputs = [ |
| 20 "grit/common_resources.h", | 19 "grit/common_resources.h", |
| 21 "common_resources.pak", | 20 "common_resources.pak", |
| 22 ] | 21 ] |
| 23 } | 22 } |
| 24 | 23 |
| 25 # GYP version: chrome/chrome_resources.gyp:chrome_resources | 24 # GYP version: chrome/chrome_resources.gyp:chrome_resources |
| 26 # (generate_extensions_api_resources action) | 25 # (generate_extensions_api_resources action) |
| 27 if (enable_extensions) { | 26 if (enable_extensions) { |
| 28 | 27 grit("extensions_api_resources") { |
| 29 grit("extensions_api_resources") { | 28 source = "extensions_api_resources.grd" |
| 30 source = "extensions_api_resources.grd" | 29 output_dir = "$root_gen_dir/chrome" |
| 31 output_dir = "$root_gen_dir/chrome" | 30 outputs = [ |
| 32 outputs = [ | 31 "grit/extensions_api_resources.h", |
| 33 "grit/extensions_api_resources.h", | 32 "extensions_api_resources.pak", |
| 34 "extensions_api_resources.pak", | 33 ] |
| 35 ] | 34 } |
| 36 } | |
| 37 | |
| 38 } | 35 } |
| 39 | 36 |
| 40 # GYP version: chrome/chrome_common.gyp:common | 37 # GYP version: chrome/chrome_common.gyp:common |
| 41 static_library("common") { | 38 static_library("common") { |
| 42 sources = rebase_path(gypi_values.chrome_common_sources, ".", "//chrome") | 39 sources = rebase_path(gypi_values.chrome_common_sources, ".", "//chrome") |
| 43 defines = [] | 40 defines = [] |
| 44 | 41 |
| 45 configs += [ "//build/config/compiler:wexit_time_destructors" ] | 42 configs += [ "//build/config/compiler:wexit_time_destructors" ] |
| 46 | 43 |
| 47 deps = [ | 44 deps = [ |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 "//components/password_manager/core/common", | 90 "//components/password_manager/core/common", |
| 94 "//components/signin/core/common", | 91 "//components/signin/core/common", |
| 95 "//components/translate/content/common", | 92 "//components/translate/content/common", |
| 96 "//ipc", | 93 "//ipc", |
| 97 "//third_party/re2", | 94 "//third_party/re2", |
| 98 "//third_party/widevine/cdm:version_h", | 95 "//third_party/widevine/cdm:version_h", |
| 99 ] | 96 ] |
| 100 } | 97 } |
| 101 | 98 |
| 102 if (enable_extensions) { | 99 if (enable_extensions) { |
| 103 sources += rebase_path( | 100 sources += rebase_path(gypi_values.chrome_common_extensions_sources, |
| 104 gypi_values.chrome_common_extensions_sources, | 101 ".", |
| 105 ".", "//chrome") | 102 "//chrome") |
| 106 deps += [ | 103 deps += [ |
| 107 "//device/usb", | 104 "//device/usb", |
| 108 "//chrome/common/extensions/api", | 105 "//chrome/common/extensions/api", |
| 109 "//extensions/common", | 106 "//extensions/common", |
| 110 "//extensions/common/api", | 107 "//extensions/common/api", |
| 111 "//extensions:extensions_resources", | 108 "//extensions:extensions_resources", |
| 112 "//extensions/strings", | 109 "//extensions/strings", |
| 113 ] | 110 ] |
| 114 } | 111 } |
| 115 | 112 |
| 116 if (is_win || is_mac) { | 113 if (is_win || is_mac) { |
| 117 sources += rebase_path( | 114 sources += |
| 118 gypi_values.chrome_common_win_mac_sources, | 115 rebase_path(gypi_values.chrome_common_win_mac_sources, ".", "//chrome") |
| 119 ".", "//chrome") | |
| 120 if (use_openssl) { | 116 if (use_openssl) { |
| 121 sources -= [ | 117 sources -= [ "extensions/api/networking_private/networking_private_crypto_
nss.cc" ] |
| 122 "extensions/api/networking_private/networking_private_crypto_nss.cc", | 118 |
| 123 ] | |
| 124 # networking_private_crypto_openssl.cc depends on boringssl. | 119 # networking_private_crypto_openssl.cc depends on boringssl. |
| 125 deps += [ | 120 deps += [ "//third_party/boringssl" ] |
| 126 "//third_party/boringssl", | |
| 127 ] | |
| 128 } else { | 121 } else { |
| 129 sources -= [ | 122 sources -= [ "extensions/api/networking_private/networking_private_crypto_
openssl.cc" ] |
| 130 "extensions/api/networking_private/networking_private_crypto_openssl.cc"
, | |
| 131 ] | |
| 132 } | 123 } |
| 133 deps += [ "//breakpad:client" ] | 124 deps += [ "//breakpad:client" ] |
| 134 } | 125 } |
| 135 if (is_mac) { | 126 if (is_mac) { |
| 136 sources += rebase_path( | 127 sources += |
| 137 gypi_values.chrome_common_mac_sources, | 128 rebase_path(gypi_values.chrome_common_mac_sources, ".", "//chrome") |
| 138 ".", "//chrome") | |
| 139 } | 129 } |
| 140 | 130 |
| 141 if (enable_nacl) { | 131 if (enable_nacl) { |
| 142 deps += [ | 132 deps += [ |
| 143 #'<(DEPTH)/components/nacl.gyp:nacl_common', TODO(GYP) | 133 #'<(DEPTH)/components/nacl.gyp:nacl_common', TODO(GYP) |
| 144 ] | 134 ] |
| 145 } | 135 } |
| 146 | 136 |
| 147 # Printing. | 137 # Printing. |
| 148 if (!enable_basic_printing && !enable_print_preview) { | 138 if (!enable_basic_printing && !enable_print_preview) { |
| 149 sources -= [ | 139 sources -= [ |
| 150 "print_messages.cc", | 140 "print_messages.cc", |
| 151 "print_messages.h", | 141 "print_messages.h", |
| 152 ] | 142 ] |
| 153 } else { | 143 } else { |
| 154 deps += [ "//printing" ] | 144 deps += [ "//printing" ] |
| 155 if (enable_print_preview) { | 145 if (enable_print_preview) { |
| 156 # Full printing support. | 146 # Full printing support. |
| 157 sources += rebase_path( | 147 sources += rebase_path(gypi_values.chrome_common_service_process_sources, |
| 158 gypi_values.chrome_common_service_process_sources, | 148 ".", |
| 159 ".", "//chrome") | 149 "//chrome") |
| 160 } | 150 } |
| 161 } | 151 } |
| 162 | 152 |
| 163 if (enable_service_discovery) { | 153 if (enable_service_discovery) { |
| 164 sources += [ | 154 sources += [ |
| 165 "local_discovery/service_discovery_client.cc", | 155 "local_discovery/service_discovery_client.cc", |
| 166 "local_discovery/service_discovery_client.h", | 156 "local_discovery/service_discovery_client.h", |
| 167 ] | 157 ] |
| 168 } | 158 } |
| 169 if (enable_mdns) { | 159 if (enable_mdns) { |
| 170 sources += [ | 160 sources += [ |
| 171 "local_discovery/service_discovery_client_impl.cc", | 161 "local_discovery/service_discovery_client_impl.cc", |
| 172 "local_discovery/service_discovery_client_impl.h", | 162 "local_discovery/service_discovery_client_impl.h", |
| 173 ] | 163 ] |
| 174 } | 164 } |
| 175 | 165 |
| 176 if (is_android) { | 166 if (is_android) { |
| 177 sources -= [ | 167 sources -= [ |
| 178 "badge_util.cc", | 168 "badge_util.cc", |
| 179 "chrome_version_info_posix.cc", | 169 "chrome_version_info_posix.cc", |
| 180 "icon_with_badge_image_source.cc", | 170 "icon_with_badge_image_source.cc", |
| 181 "media_galleries/metadata_types.h", | 171 "media_galleries/metadata_types.h", |
| 182 "spellcheck_common.cc", | 172 "spellcheck_common.cc", |
| 183 ] | 173 ] |
| 184 } else { | 174 } else { |
| 185 # Non-Android. | 175 # Non-Android. |
| 186 sources += rebase_path( | 176 sources += |
| 187 gypi_values.chrome_common_importer_sources, | 177 rebase_path(gypi_values.chrome_common_importer_sources, ".", "//chrome") |
| 188 ".", "//chrome") | |
| 189 } | 178 } |
| 190 | 179 |
| 191 if (is_chromeos) { | 180 if (is_chromeos) { |
| 192 sources -= [ "chrome_version_info_posix.cc" ] | 181 sources -= [ "chrome_version_info_posix.cc" ] |
| 193 } | 182 } |
| 194 | 183 |
| 195 if (is_win) { | 184 if (is_win) { |
| 196 deps += [ "//third_party/wtl" ] | 185 deps += [ "//third_party/wtl" ] |
| 197 } | 186 } |
| 198 | 187 |
| 199 if (enable_mdns) { | 188 if (enable_mdns) { |
| 200 sources += [ "local_discovery/local_discovery_messages.h" ] | 189 sources += [ "local_discovery/local_discovery_messages.h" ] |
| 201 } | 190 } |
| 202 | 191 |
| 203 if (is_mac) { | 192 if (is_mac) { |
| 204 sources -= [ | 193 sources -= [ "chrome_version_info_posix.cc" ] |
| 205 "chrome_version_info_posix.cc", | |
| 206 ] | |
| 207 deps += [ | 194 deps += [ |
| 208 "//third_party/mach_override", | 195 "//third_party/mach_override", |
| 209 "//third_party/google_toolbox_for_mac", | 196 "//third_party/google_toolbox_for_mac", |
| 210 ] | 197 ] |
| 211 } | 198 } |
| 212 | 199 |
| 213 if (enable_remoting) { | 200 if (enable_remoting) { |
| 214 deps += [ "//remoting/client/plugin" ] | 201 deps += [ "//remoting/client/plugin" ] |
| 215 } | 202 } |
| 216 if (enable_plugins) { | 203 if (enable_plugins) { |
| 217 sources += [ | 204 sources += [ |
| 218 "pepper_flash.cc", | 205 "pepper_flash.cc", |
| 219 "pepper_flash.h", | 206 "pepper_flash.h", |
| 220 "pepper_permission_util.cc", | 207 "pepper_permission_util.cc", |
| 221 "pepper_permission_util.h", | 208 "pepper_permission_util.h", |
| 222 ] | 209 ] |
| 223 deps += [ | 210 deps += [ "//third_party/adobe/flash:flapper_version_h" ] |
| 224 "//third_party/adobe/flash:flapper_version_h", | |
| 225 ] | |
| 226 } | 211 } |
| 227 if (!enable_webrtc) { | 212 if (!enable_webrtc) { |
| 228 sources -= [ "media/webrtc_logging_messages.h" ] | 213 sources -= [ "media/webrtc_logging_messages.h" ] |
| 229 } | 214 } |
| 230 if (enable_configuration_policy) { | 215 if (enable_configuration_policy) { |
| 231 deps += [ "//components/policy" ] | 216 deps += [ "//components/policy" ] |
| 232 } | 217 } |
| 233 | 218 |
| 234 if (safe_browsing_mode == 1) { | 219 if (safe_browsing_mode == 1) { |
| 235 defines += [ "FULL_SAFE_BROWSING" ] | 220 defines += [ "FULL_SAFE_BROWSING" ] |
| 236 sources += rebase_path( | 221 sources += rebase_path(gypi_values.chrome_common_full_safe_browsing_sources, |
| 237 gypi_values.chrome_common_full_safe_browsing_sources, | 222 ".", |
| 238 ".", "//chrome") | 223 "//chrome") |
| 239 } | 224 } |
| 240 if (safe_browsing_mode == 2) { | 225 if (safe_browsing_mode == 2) { |
| 241 defines += [ "MOBILE_SAFE_BROWSING" ] | 226 defines += [ "MOBILE_SAFE_BROWSING" ] |
| 242 } | 227 } |
| 243 } | 228 } |
| 244 | 229 |
| 245 import("//chrome/version.gni") | 230 import("//chrome/version.gni") |
| 246 process_version("version") { | 231 process_version("version") { |
| 247 visibility = [ ":common" ] | 232 visibility = [ ":common" ] |
| 248 source = "chrome_version_info_values.h.version" | 233 source = "chrome_version_info_values.h.version" |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 deps += [ | 273 deps += [ |
| 289 #'../components/nacl.gyp:nacl_switches', TODO(GYP) | 274 #'../components/nacl.gyp:nacl_switches', TODO(GYP) |
| 290 ] | 275 ] |
| 291 } | 276 } |
| 292 } | 277 } |
| 293 | 278 |
| 294 source_set("test_support") { | 279 source_set("test_support") { |
| 295 testonly = true | 280 testonly = true |
| 296 visibility = [ "//chrome/test:test_support" ] | 281 visibility = [ "//chrome/test:test_support" ] |
| 297 | 282 |
| 298 sources = [ | 283 sources = [] |
| 299 ] | |
| 300 | 284 |
| 301 deps = [ | 285 deps = [ |
| 302 ":common", | 286 ":common", |
| 303 "//base", | 287 "//base", |
| 304 "//testing/gtest", | 288 "//testing/gtest", |
| 305 ] | 289 ] |
| 306 | 290 |
| 307 if (is_win || is_mac) { | 291 if (is_win || is_mac) { |
| 308 sources += [ | 292 sources += [ |
| 309 "media_galleries/picasa_test_util.cc", | 293 "media_galleries/picasa_test_util.cc", |
| 310 "media_galleries/picasa_test_util.h", | 294 "media_galleries/picasa_test_util.h", |
| 311 "media_galleries/pmp_test_util.cc", | 295 "media_galleries/pmp_test_util.cc", |
| 312 "media_galleries/pmp_test_util.h", | 296 "media_galleries/pmp_test_util.h", |
| 313 ] | 297 ] |
| 314 } | 298 } |
| 315 | 299 |
| 316 if (enable_extensions) { | 300 if (enable_extensions) { |
| 317 sources += [ | 301 sources += [ |
| 318 "extensions/extension_test_util.cc", | 302 "extensions/extension_test_util.cc", |
| 319 "extensions/extension_test_util.h", | 303 "extensions/extension_test_util.h", |
| 320 ] | 304 ] |
| 321 } | 305 } |
| 322 | |
| 323 } | 306 } |
| OLD | NEW |