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

Side by Side Diff: third_party/WebKit/Source/platform/BUILD.gn

Issue 2702363002: Share precompiled header setup for blink between Windows and Mac. (Closed)
Patch Set: Share precompiled header setup for blink between Windows and Mac. Created 3 years, 9 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
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/features.gni") 5 import("//build/config/features.gni")
6 import("//build/config/ui.gni") 6 import("//build/config/ui.gni")
7 import("//testing/libfuzzer/fuzzer_test.gni") 7 import("//testing/libfuzzer/fuzzer_test.gni")
8 import("//testing/test.gni") 8 import("//testing/test.gni")
9 import("//third_party/WebKit/public/public_features.gni") 9 import("//third_party/WebKit/public/public_features.gni")
10 import("//third_party/WebKit/Source/build/scripts/scripts.gni") 10 import("//third_party/WebKit/Source/build/scripts/scripts.gni")
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 } 162 }
163 163
164 import("//build/config/pch.gni") 164 import("//build/config/pch.gni")
165 165
166 config("blink_platform_pch") { 166 config("blink_platform_pch") {
167 if (enable_precompiled_headers) { 167 if (enable_precompiled_headers) {
168 if (is_win) { 168 if (is_win) {
169 # This is a string rather than a file GN knows about. It has to match 169 # This is a string rather than a file GN knows about. It has to match
170 # exactly what's in the /FI flag below, and what might appear in the 170 # exactly what's in the /FI flag below, and what might appear in the
171 # source code in quotes for an #include directive. 171 # source code in quotes for an #include directive.
172 precompiled_header = 172 precompiled_header = rebase_path("Precompile-platform.h", root_build_dir)
173 rebase_path("win/Precompile-platform.h", root_build_dir)
174 173
175 # This is a file that GN will compile with the above header. It will be 174 # This is a file that GN will compile with the above header. It will be
176 # implicitly added to the sources (potentially multiple times, with one 175 # implicitly added to the sources (potentially multiple times, with one
177 # variant for each language used in the target). 176 # variant for each language used in the target).
178 precompiled_source = 177 precompiled_source =
179 "//third_party/WebKit/Source/platform/win/Precompile-platform.cpp" 178 "//third_party/WebKit/Source/platform/Precompile-platform.cpp"
180 179
181 # Force include the header. 180 # Force include the header.
182 cflags = [ "/FI$precompiled_header" ] 181 cflags = [ "/FI$precompiled_header" ]
182 } else if (is_mac) {
183 precompiled_header = rebase_path("Precompile-platform.h", root_build_dir)
Nico 2017/03/03 16:04:35 likewise
184 precompiled_source =
185 "//third_party/WebKit/Source/platform/Precompile-platform.h"
183 } 186 }
184 } 187 }
185 } 188 }
186 189
187 component("platform") { 190 component("platform") {
188 visibility = [] # Allow re-assignment of list. 191 visibility = [] # Allow re-assignment of list.
189 visibility = [ 192 visibility = [
190 "//third_party/WebKit/*", 193 "//third_party/WebKit/*",
191 "//url/mojo:url_mojom_origin_blink", 194 "//url/mojo:url_mojom_origin_blink",
192 "//url/mojo:url_mojom_gurl_blink", 195 "//url/mojo:url_mojom_gurl_blink",
(...skipping 1260 matching lines...) Expand 10 before | Expand all | Expand 10 after
1453 "KillRingNone.cpp", 1456 "KillRingNone.cpp",
1454 "fonts/skia/FontCacheSkia.cpp", 1457 "fonts/skia/FontCacheSkia.cpp",
1455 "scroll/ScrollAnimator.cpp", 1458 "scroll/ScrollAnimator.cpp",
1456 "scroll/ScrollAnimator.h", 1459 "scroll/ScrollAnimator.h",
1457 1460
1458 # Uses LocaleMac instead. 1461 # Uses LocaleMac instead.
1459 "text/LocaleICU.cpp", 1462 "text/LocaleICU.cpp",
1460 "text/LocaleICU.h", 1463 "text/LocaleICU.h",
1461 ] 1464 ]
1462 1465
1463 configs += [ "//third_party/WebKit/Source:mac_precompiled_headers" ]
1464 libs = [ 1466 libs = [
1465 "AppKit.framework", 1467 "AppKit.framework",
1466 "Accelerate.framework", 1468 "Accelerate.framework",
1467 "Carbon.framework", 1469 "Carbon.framework",
1468 "Foundation.framework", 1470 "Foundation.framework",
1469 ] 1471 ]
1470 } else { 1472 } else {
1471 sources -= [ 1473 sources -= [
1472 "geometry/cg/FloatPointCG.cpp", 1474 "geometry/cg/FloatPointCG.cpp",
1473 "geometry/cg/FloatRectCG.cpp", 1475 "geometry/cg/FloatRectCG.cpp",
(...skipping 597 matching lines...) Expand 10 before | Expand all | Expand 10 after
2071 "//third_party/WebKit/Source:config", 2073 "//third_party/WebKit/Source:config",
2072 "//third_party/WebKit/Source:inside_blink", 2074 "//third_party/WebKit/Source:inside_blink",
2073 ] 2075 ]
2074 2076
2075 deps = [ 2077 deps = [
2076 ":test_support", 2078 ":test_support",
2077 "//testing/gmock", 2079 "//testing/gmock",
2078 "//testing/gtest", 2080 "//testing/gtest",
2079 ] 2081 ]
2080 } 2082 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698