Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(41)

Side by Side Diff: chrome/browser/BUILD.gn

Issue 2060983002: Default components to static libraries in GN build (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: typo Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « build/config/chrome_build.gni ('k') | chrome/browser/ui/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/chrome_build.gni") 5 import("//build/config/chrome_build.gni")
6 import("//build/config/crypto.gni") 6 import("//build/config/crypto.gni")
7 import("//build/config/features.gni") 7 import("//build/config/features.gni")
8 import("//build/config/ui.gni") 8 import("//build/config/ui.gni")
9 import("//chrome/common/features.gni") 9 import("//chrome/common/features.gni")
10 import("//media/media_options.gni") 10 import("//media/media_options.gni")
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 # If you want to link gnome-keyring directly (use only for unit tests) 71 # If you want to link gnome-keyring directly (use only for unit tests)
72 # ADDITIONALLY add this config on top of ":gnome_keyring". pkg-config is a 72 # ADDITIONALLY add this config on top of ":gnome_keyring". pkg-config is a
73 # bit slow, so prefer not to run it again. In practice, gnome-keyring's libs 73 # bit slow, so prefer not to run it again. In practice, gnome-keyring's libs
74 # are just itself and common gnome ones we link already, so we can get away 74 # are just itself and common gnome ones we link already, so we can get away
75 # with additionally just coding the library name here. 75 # with additionally just coding the library name here.
76 config("gnome_keyring_direct") { 76 config("gnome_keyring_direct") {
77 libs = [ "gnome-keyring" ] 77 libs = [ "gnome-keyring" ]
78 } 78 }
79 } 79 }
80 80
81 source_set("browser") { 81 # Use a static library here because many test binaries depend on this but don't
82 # require many files from it. This makes linking more efficient. However, on
83 # x64 official builds the static library will be too large (> 32-bits) so use
84 # source sets in that case.
85 if (is_mac || (current_cpu == "x64" && is_official_build)) {
86 # TODO(brettw) bug 618797: Remove the mac condition. On Mac making this
87 # target a static_library causes a crash on startup and the browser_tests all
88 # fail. My guess is this is due to a required static initializer not being
89 # brought in.
90 chrome_browser_target_type = "source_set"
91 } else {
92 chrome_browser_target_type = "static_library"
93 }
94 target(chrome_browser_target_type, "browser") {
82 configs += [ 95 configs += [
83 "//build/config/compiler:wexit_time_destructors", 96 "//build/config/compiler:wexit_time_destructors",
84 "//build/config:precompiled_headers", 97 "//build/config:precompiled_headers",
85 "//third_party/WebKit/public:debug_devtools", 98 "//third_party/WebKit/public:debug_devtools",
86 ] 99 ]
87 defines = [] 100 defines = []
88 sources = [] 101 sources = []
89 libs = [] 102 libs = []
90 ldflags = [] 103 ldflags = []
91 104
(...skipping 954 matching lines...) Expand 10 before | Expand all | Expand 10 after
1046 args = rebase_path(sources, root_build_dir) + 1059 args = rebase_path(sources, root_build_dir) +
1047 rebase_path(outputs, root_build_dir) 1060 rebase_path(outputs, root_build_dir)
1048 } 1061 }
1049 } else { 1062 } else {
1050 group("chrome_internal_resources_gen") { 1063 group("chrome_internal_resources_gen") {
1051 # Empty placeholder. 1064 # Empty placeholder.
1052 } 1065 }
1053 } 1066 }
1054 1067
1055 # In GYP this is part of test_support_common. 1068 # In GYP this is part of test_support_common.
1056 source_set("test_support") { 1069 #
1070 # Use a static library here because many test binaries depend on this but don't
1071 # require many files from it. This makes linking more efficient.
1072 static_library("test_support") {
1057 testonly = true 1073 testonly = true
1058 1074
1059 # Always include this via the main test support target. 1075 # Always include this via the main test support target.
1060 visibility = [ "//chrome/test:test_support" ] 1076 visibility = [ "//chrome/test:test_support" ]
1061 1077
1062 sources = [ 1078 sources = [
1063 "browsing_data/mock_browsing_data_appcache_helper.cc", 1079 "browsing_data/mock_browsing_data_appcache_helper.cc",
1064 "browsing_data/mock_browsing_data_appcache_helper.h", 1080 "browsing_data/mock_browsing_data_appcache_helper.h",
1065 "browsing_data/mock_browsing_data_cache_storage_helper.cc", 1081 "browsing_data/mock_browsing_data_cache_storage_helper.cc",
1066 "browsing_data/mock_browsing_data_cache_storage_helper.h", 1082 "browsing_data/mock_browsing_data_cache_storage_helper.h",
(...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after
1353 # linking all of the test support. 1369 # linking all of the test support.
1354 source_set("pepper_cdm_test_constants") { 1370 source_set("pepper_cdm_test_constants") {
1355 testonly = true 1371 testonly = true
1356 visibility = [ "//chrome/*" ] 1372 visibility = [ "//chrome/*" ]
1357 sources = [ 1373 sources = [
1358 "media/pepper_cdm_test_constants.cc", 1374 "media/pepper_cdm_test_constants.cc",
1359 "media/pepper_cdm_test_constants.h", 1375 "media/pepper_cdm_test_constants.h",
1360 ] 1376 ]
1361 } 1377 }
1362 } 1378 }
OLDNEW
« no previous file with comments | « build/config/chrome_build.gni ('k') | chrome/browser/ui/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698