Chromium Code Reviews| 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/buildflag_header.gni") | |
| 5 import("//build/config/chrome_build.gni") | 6 import("//build/config/chrome_build.gni") |
| 6 import("//build/config/compiler/compiler.gni") | 7 import("//build/config/compiler/compiler.gni") |
| 7 import("//build/config/features.gni") | 8 import("//build/config/features.gni") |
| 8 import("//build/config/locales.gni") | 9 import("//build/config/locales.gni") |
| 9 import("//build/config/sanitizers/sanitizers.gni") | 10 import("//build/config/sanitizers/sanitizers.gni") |
| 10 import("//build/config/ui.gni") | 11 import("//build/config/ui.gni") |
| 11 import("//build/config/win/console_app.gni") | 12 import("//build/config/win/console_app.gni") |
| 12 import("//build/config/win/manifest.gni") | 13 import("//build/config/win/manifest.gni") |
| 13 import("//chrome/chrome_repack_locales.gni") | 14 import("//chrome/chrome_repack_locales.gni") |
| 15 import("//chrome/mash.gni") | |
| 14 import("//chrome/version.gni") | 16 import("//chrome/version.gni") |
| 15 | 17 |
| 16 declare_args() { | 18 declare_args() { |
| 17 # Specify the current PGO phase, only used for the Windows MSVS build. Here's | 19 # Specify the current PGO phase, only used for the Windows MSVS build. Here's |
| 18 # the different values that can be used: | 20 # the different values that can be used: |
| 19 # 0 : Means that PGO is turned off. | 21 # 0 : Means that PGO is turned off. |
| 20 # 1 : Used during the PGI (instrumentation) phase. | 22 # 1 : Used during the PGI (instrumentation) phase. |
| 21 # 2 : Used during the PGO (optimization) phase. | 23 # 2 : Used during the PGO (optimization) phase. |
| 22 # | 24 # |
| 23 # TODO(sebmarchand): Add support for the PGU (update) phase. | 25 # TODO(sebmarchand): Add support for the PGU (update) phase. |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 179 | 181 |
| 180 # Needed to use the master_preferences functions | 182 # Needed to use the master_preferences functions |
| 181 "//chrome/installer/util:with_no_strings", | 183 "//chrome/installer/util:with_no_strings", |
| 182 "//content/public/app:both", | 184 "//content/public/app:both", |
| 183 ] | 185 ] |
| 184 if (enable_plugins && enable_pdf) { | 186 if (enable_plugins && enable_pdf) { |
| 185 deps += [ "//pdf" ] | 187 deps += [ "//pdf" ] |
| 186 } | 188 } |
| 187 | 189 |
| 188 public_deps = [ | 190 public_deps = [ |
| 191 ":features", | |
| 189 ":xdg_mime", # Needs to be public for installer to consume files. | 192 ":xdg_mime", # Needs to be public for installer to consume files. |
| 190 ] | 193 ] |
| 191 | 194 |
| 192 # GYP has this in a 'profiling==0 and linux_disable_pie==0' condition. | 195 # GYP has this in a 'profiling==0 and linux_disable_pie==0' condition. |
| 193 # but GN doesn't have either of these flags. | 196 # but GN doesn't have either of these flags. |
| 194 ldflags = [ "-pie" ] | 197 ldflags = [ "-pie" ] |
| 195 | 198 |
| 196 if (use_pango || use_cairo) { | 199 if (use_pango || use_cairo) { |
| 197 # Needed for chrome_main.cc initialization of libraries. | 200 # Needed for chrome_main.cc initialization of libraries. |
| 198 configs += [ "//build/config/linux:pangocairo" ] | 201 configs += [ "//build/config/linux:pangocairo" ] |
| 199 } | 202 } |
| 200 | 203 |
| 201 if (use_x11) { | 204 if (use_x11) { |
| 202 configs += [ | 205 configs += [ |
| 203 "//build/config/linux:x11", | 206 "//build/config/linux:x11", |
| 204 "//build/config/linux:xext", | 207 "//build/config/linux:xext", |
| 205 ] | 208 ] |
| 206 } | 209 } |
| 210 | |
| 211 if (use_mash) { | |
|
Ben Goodger (Google)
2016/02/22 20:20:00
you should give this variable a name that implies
sky
2016/02/23 00:01:33
I went with the wordy enable_package_mash_services
| |
| 212 deps += [ "//chrome/app/mash" ] | |
| 213 } | |
| 207 } | 214 } |
| 208 | 215 |
| 209 if (is_mac) { | 216 if (is_mac) { |
| 210 sources += [ "app/chrome_exe_main_mac.c" ] | 217 sources += [ "app/chrome_exe_main_mac.c" ] |
| 211 deps += [ ":chrome_dll" ] | 218 deps += [ ":chrome_dll" ] |
| 212 | 219 |
| 213 # TODO(GYP) lots more stuff in the is_mac block. | 220 # TODO(GYP) lots more stuff in the is_mac block. |
| 214 } else { # Non-Mac. | 221 } else { # Non-Mac. |
| 215 # These files are used by the installer so we need a public dep. | 222 # These files are used by the installer so we need a public dep. |
| 216 public_deps += [ | 223 public_deps += [ |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 285 "app/chrome_main_delegate.cc", | 292 "app/chrome_main_delegate.cc", |
| 286 "app/chrome_main_delegate.h", | 293 "app/chrome_main_delegate.h", |
| 287 "app/chrome_main_mac.h", | 294 "app/chrome_main_mac.h", |
| 288 "app/chrome_main_mac.mm", | 295 "app/chrome_main_mac.mm", |
| 289 "app/delay_load_hook_win.cc", | 296 "app/delay_load_hook_win.cc", |
| 290 "app/delay_load_hook_win.h", | 297 "app/delay_load_hook_win.h", |
| 291 ] | 298 ] |
| 292 | 299 |
| 293 deps = [ | 300 deps = [ |
| 294 ":browser_dependencies", | 301 ":browser_dependencies", |
| 302 ":features", | |
| 295 "//build/config/sanitizers:deps", | 303 "//build/config/sanitizers:deps", |
| 296 ] | 304 ] |
| 297 if (is_win) { | 305 if (is_win) { |
| 298 output_name = "chrome" | 306 output_name = "chrome" |
| 299 | 307 |
| 300 deps += [ | 308 deps += [ |
| 301 ":chrome_dll_manifest", | 309 ":chrome_dll_manifest", |
| 302 ":chrome_dll_version", | 310 ":chrome_dll_version", |
| 303 "//base/trace_event/etw_manifest:chrome_events_win", | 311 "//base/trace_event/etw_manifest:chrome_events_win", |
| 304 "//chrome/app/theme:chrome_unscaled_resources", | 312 "//chrome/app/theme:chrome_unscaled_resources", |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 362 # Define the order of symbols within the framework. | 370 # Define the order of symbols within the framework. |
| 363 ldflags += [ | 371 ldflags += [ |
| 364 "-Wl,-order_file", | 372 "-Wl,-order_file", |
| 365 "-Wl," + rebase_path("app/framework.order", root_build_dir), | 373 "-Wl," + rebase_path("app/framework.order", root_build_dir), |
| 366 ] | 374 ] |
| 367 } | 375 } |
| 368 | 376 |
| 369 if (enable_plugins && enable_pdf && !is_multi_dll_chrome) { | 377 if (enable_plugins && enable_pdf && !is_multi_dll_chrome) { |
| 370 deps += [ "//pdf" ] | 378 deps += [ "//pdf" ] |
| 371 } | 379 } |
| 380 | |
| 381 if (use_mash) { | |
| 382 deps += [ "//chrome/app/mash" ] | |
| 383 } | |
| 372 } | 384 } |
| 373 | 385 |
| 374 if (is_multi_dll_chrome) { | 386 if (is_multi_dll_chrome) { |
| 375 # This manifest matches what GYP produces. It may not even be necessary. | 387 # This manifest matches what GYP produces. It may not even be necessary. |
| 376 windows_manifest("chrome_child_manifest") { | 388 windows_manifest("chrome_child_manifest") { |
| 377 sources = [ | 389 sources = [ |
| 378 as_invoker_manifest, | 390 as_invoker_manifest, |
| 379 ] | 391 ] |
| 380 type = "dll" | 392 type = "dll" |
| 381 } | 393 } |
| (...skipping 708 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1090 "//chrome/app/theme/$branding_path_component/product_logo_48.png", | 1102 "//chrome/app/theme/$branding_path_component/product_logo_48.png", |
| 1091 "//chrome/tools/build/linux/chrome-wrapper", | 1103 "//chrome/tools/build/linux/chrome-wrapper", |
| 1092 "//third_party/xdg-utils/scripts/xdg-mime", | 1104 "//third_party/xdg-utils/scripts/xdg-mime", |
| 1093 "//third_party/xdg-utils/scripts/xdg-settings", | 1105 "//third_party/xdg-utils/scripts/xdg-settings", |
| 1094 ] | 1106 ] |
| 1095 outputs = [ | 1107 outputs = [ |
| 1096 "$root_out_dir/{{source_file_part}}", | 1108 "$root_out_dir/{{source_file_part}}", |
| 1097 ] | 1109 ] |
| 1098 } | 1110 } |
| 1099 } | 1111 } |
| 1112 | |
| 1113 buildflag_header("features") { | |
| 1114 header = "chrome_features.h" | |
| 1115 flags = [ "USE_MASH=$use_mash" ] | |
| 1116 } | |
| OLD | NEW |