Commit ab4da6c8 authored by Takashi Toyoshima's avatar Takashi Toyoshima Committed by Commit Bot

Reland "Reland "Reland "Split WebKit platform build file"""

blobs.mojom-blink.h internally depends on url.mojom-blink.h.
So, we should have //url/mojo:url_mojom_gurl_blink__generator
dependency in blob:generator target on which other test_support
source_set depends.

confirmed that generated ninja files, i.e.
../obj/third_party/WebKit/Source/platform/loader/test_support.ninja
has a dependency to obj/url/mojo/url_mojom_gurl_blink_generator.stamp

This is a reland of 1cf9f36e
Original change's description:
> Reland "Reland "Split WebKit platform build file""
> 
> test_support of platform/loader and platform/network should
> depends on //storage/public/interfaces:interfaces_blink__generator
> because it indirectly includes generated mojo interface headers.
> 
> This is the root cause of the original issue, and it seems
> BUILD file splitting makes it happens more easily.
> 
> This is a reland of 997ce7ad
> Original change's description:
> > Reland "Split WebKit platform build file"
> > 
> > platform/network/BUILD.gn lacked mojo_bindings_blink dependency.
> > This caused a race on compiling.
> > 
> > This is a reland of 080c70a7
> > Original change's description:
> > > Split WebKit platform build file
> > > 
> > > A race condition was found in the build of //third_party/WebKit/Source/platform/loader.
> > > To resolve it necessary to extract targets  //third_party/WebKit/Source/platform/blob and //third_party/WebKit/Source/platform/network form //third_party/WebKit/Source/platform. And add correct dependencies where it is needed.
> > > All of these done in this CL.
> > > 
> > > Original author is apisarev@yandex-team.ru, and toyoshim@chromium.org takes over it
> > > to submit since it needs quick rebase works to catch up HEAD.
> > > 
> > > Bug: 754600
> > > Change-Id: I5f70348fac10f270df99b658608cf23685ed937e
> > > Test: gn check out/Release && ninja -C out/Release
> > > Reviewed-on: https://chromium-review.googlesource.com/612284
> > > Commit-Queue: Takashi Toyoshima <toyoshim@chromium.org>
> > > Reviewed-by: Daniel Bratell <bratell@opera.com>
> > > Reviewed-by: Takashi Toyoshima <toyoshim@chromium.org>
> > > Reviewed-by: Kinuko Yasuda <kinuko@chromium.org>
> > > Reviewed-by: Dimitri Glazkov <dglazkov@chromium.org>
> > > Cr-Commit-Position: refs/heads/master@{#508661}
> > 
> > TBR=engedy@chromium.org
> > 
> > Bug: 754600
> > Change-Id: I250e67581e61e1d36c32b01ccad3372b442c08bc
> > Reviewed-on: https://chromium-review.googlesource.com/718243
> > Commit-Queue: Takashi Toyoshima <toyoshim@chromium.org>
> > Reviewed-by: Takashi Toyoshima <toyoshim@chromium.org>
> > Cr-Commit-Position: refs/heads/master@{#508993}
> 
> TBR=engedy@chromium.org
> 
> Bug: 754600
> Change-Id: Ia1231a3ee2213bb44474bd8ffeacf67b86002bfd
> Reviewed-on: https://chromium-review.googlesource.com/720542
> Commit-Queue: Takashi Toyoshima <toyoshim@chromium.org>
> Reviewed-by: Emil A Eklund <eae@chromium.org>
> Reviewed-by: Takashi Toyoshima <toyoshim@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#509359}

TBR=jam@chromium.org

Bug: 754600
Change-Id: Ica01cdfc20e7cf26e1adf4c42a5fae7ac83a310e
Reviewed-on: https://chromium-review.googlesource.com/725139Reviewed-by: default avatarTakashi Toyoshima <toyoshim@chromium.org>
Commit-Queue: Takashi Toyoshima <toyoshim@chromium.org>
Cr-Commit-Position: refs/heads/master@{#509749}
parent ee8cceda
......@@ -27,11 +27,6 @@ make_names("font_family_names") {
output_dir = blink_platform_output_dir
}
make_names("http_names") {
in_files = [ "network/http_names.json5" ]
output_dir = blink_platform_output_dir
}
action("runtime_enabled_features") {
script = "../build/scripts/make_runtime_features.py"
......@@ -159,9 +154,9 @@ group("make_platform_generated") {
":character_data",
":color_data",
":font_family_names",
":http_names",
":instrumentation_probes",
":runtime_enabled_features",
"//third_party/WebKit/Source/platform/network:make_generated",
]
}
......@@ -528,14 +523,6 @@ jumbo_component("platform") {
"bindings/WrapperCreationSecurityCheck.h",
"bindings/WrapperTypeInfo.cpp",
"bindings/WrapperTypeInfo.h",
"blob/BlobBytesProvider.cpp",
"blob/BlobBytesProvider.h",
"blob/BlobData.cpp",
"blob/BlobData.h",
"blob/BlobRegistry.cpp",
"blob/BlobRegistry.h",
"blob/BlobURL.cpp",
"blob/BlobURL.h",
"clipboard/ClipboardMimeTypes.cpp",
"clipboard/ClipboardMimeTypes.h",
"clipboard/ClipboardUtilities.cpp",
......@@ -1244,45 +1231,6 @@ jumbo_component("platform") {
"mojo/CommonCustomTypesStructTraits.h",
"mojo/FetchAPIRequestStructTraits.cpp",
"mojo/MojoHelper.h",
"network/ContentSecurityPolicyParsers.cpp",
"network/ContentSecurityPolicyParsers.h",
"network/ContentSecurityPolicyResponseHeaders.cpp",
"network/ContentSecurityPolicyResponseHeaders.h",
"network/EncodedFormData.cpp",
"network/EncodedFormData.h",
"network/FormDataEncoder.cpp",
"network/FormDataEncoder.h",
"network/HTTPHeaderMap.cpp",
"network/HTTPHeaderMap.h",
"network/HTTPParsers.cpp",
"network/HTTPParsers.h",
"network/HeaderFieldTokenizer.cpp",
"network/HeaderFieldTokenizer.h",
"network/NetworkHints.cpp",
"network/NetworkHints.h",
"network/NetworkInstrumentation.cpp",
"network/NetworkInstrumentation.h",
"network/NetworkLog.h",
"network/NetworkStateNotifier.cpp",
"network/NetworkStateNotifier.h",
"network/NetworkUtils.cpp",
"network/NetworkUtils.h",
"network/ParsedContentDisposition.cpp",
"network/ParsedContentDisposition.h",
"network/ParsedContentHeaderFieldParameters.cpp",
"network/ParsedContentHeaderFieldParameters.h",
"network/ParsedContentType.cpp",
"network/ParsedContentType.h",
"network/WebSocketHandshakeRequest.cpp",
"network/WebSocketHandshakeRequest.h",
"network/WebSocketHandshakeResponse.cpp",
"network/WebSocketHandshakeResponse.h",
"network/mime/ContentType.cpp",
"network/mime/ContentType.h",
"network/mime/MIMETypeFromURL.cpp",
"network/mime/MIMETypeFromURL.h",
"network/mime/MIMETypeRegistry.cpp",
"network/mime/MIMETypeRegistry.h",
"peerconnection/RTCAnswerOptionsPlatform.h",
"peerconnection/RTCOfferOptionsPlatform.h",
"peerconnection/RTCSessionDescriptionRequest.h",
......@@ -1463,7 +1411,6 @@ jumbo_component("platform") {
sources += get_target_outputs(":character_data") +
get_target_outputs(":color_data") +
get_target_outputs(":font_family_names") +
get_target_outputs(":http_names") +
get_target_outputs(":instrumentation_probes") +
get_target_outputs(":runtime_enabled_features")
......@@ -1503,7 +1450,6 @@ jumbo_component("platform") {
"//services/resource_coordinator/public/cpp:resource_coordinator_cpp",
"//services/service_manager/public/interfaces:interfaces_blink",
"//skia",
"//storage/public/interfaces:interfaces_blink",
"//third_party:jpeg",
"//third_party/WebKit/Source/platform/wtf",
"//third_party/WebKit/common:blink_common",
......@@ -1523,12 +1469,13 @@ jumbo_component("platform") {
"//mojo/public/cpp/bindings:wtf_support",
"//services/service_manager/public/cpp",
"//third_party:freetype_harfbuzz",
"//third_party/WebKit/Source/platform/blob",
"//third_party/WebKit/Source/platform/heap",
"//third_party/WebKit/Source/platform/instrumentation",
"//third_party/WebKit/Source/platform/loader",
"//third_party/WebKit/Source/platform/media",
"//third_party/WebKit/Source/platform/network",
"//third_party/WebKit/Source/platform/scheduler",
"//third_party/WebKit/public:mojo_bindings_blink",
"//third_party/WebKit/public:offscreen_canvas_mojo_bindings_blink",
"//third_party/ced",
"//third_party/icu",
......@@ -1656,7 +1603,6 @@ jumbo_static_library("test_support") {
sources = [
"graphics/gpu/DrawingBufferTestHelpers.h",
"network/mime/MockMimeRegistry.h",
"scroll/ScrollbarTestSuite.h",
"testing/CompositorTest.cpp",
"testing/CompositorTest.h",
......@@ -1727,6 +1673,7 @@ jumbo_static_library("test_support") {
"//base/test:test_support",
"//mojo/edk/system",
"//third_party/WebKit/Source/platform/loader:test_support",
"//third_party/WebKit/Source/platform/network:test_support",
"//third_party/WebKit/Source/platform/scheduler:test_support",
]
......@@ -1775,8 +1722,6 @@ jumbo_source_set("blink_platform_unittests_sources") {
"animation/TimingFunctionTest.cpp",
"audio/PushPullFIFOTest.cpp",
"bindings/RuntimeCallStatsTest.cpp",
"blob/BlobBytesProviderTest.cpp",
"blob/BlobDataTest.cpp",
"exported/FilePathConversionTest.cpp",
"exported/WebCORSPreflightResultCacheTest.cpp",
"exported/WebCORSTest.cpp",
......@@ -1873,14 +1818,6 @@ jumbo_source_set("blink_platform_unittests_sources") {
"mojo/CommonCustomTypesStructTraitsTest.cpp",
"mojo/GeometryStructTraitsTest.cpp",
"mojo/KURLSecurityOriginTest.cpp",
"network/EncodedFormDataTest.cpp",
"network/HTTPParsersTest.cpp",
"network/NetworkStateNotifierTest.cpp",
"network/NetworkUtilsTest.cpp",
"network/ParsedContentDispositionTest.cpp",
"network/ParsedContentHeaderFieldParametersTest.cpp",
"network/ParsedContentTypeTest.cpp",
"network/mime/MIMETypeRegistryTest.cpp",
"scroll/ScrollableAreaTest.cpp",
"scroll/ScrollbarThemeOverlayTest.cpp",
"testing/ArenaTestHelpers.h",
......@@ -1956,8 +1893,10 @@ jumbo_source_set("blink_platform_unittests_sources") {
"//testing/gmock",
"//testing/gtest",
"//third_party:freetype_harfbuzz",
"//third_party/WebKit/Source/platform/blob:unit_tests",
"//third_party/WebKit/Source/platform/instrumentation:unit_tests",
"//third_party/WebKit/Source/platform/loader:unit_tests",
"//third_party/WebKit/Source/platform/network:unit_tests",
"//third_party/WebKit/Source/platform/scheduler:unit_tests",
"//third_party/WebKit/Source/platform/wtf",
"//ui/gfx",
......
# Copyright 2017 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/config/jumbo.gni")
jumbo_source_set("generator") {
public_deps = [
"//storage/public/interfaces:interfaces_blink__generator",
"//url/mojo:url_mojom_gurl_blink__generator",
]
}
jumbo_source_set("blob") {
visibility = [ "//third_party/WebKit/Source/*" ]
sources = [
"BlobBytesProvider.cpp",
"BlobBytesProvider.h",
"BlobData.cpp",
"BlobData.h",
"BlobRegistry.cpp",
"BlobRegistry.h",
"BlobURL.cpp",
"BlobURL.h",
]
configs += [
"//third_party/WebKit/Source:non_test_config",
"//third_party/WebKit/Source/platform:blink_platform_config",
"//third_party/WebKit/Source/platform:blink_platform_implementation",
]
public_deps = [
"//storage/public/interfaces:interfaces_blink",
]
}
jumbo_source_set("unit_tests") {
visibility = [ "//third_party/WebKit/Source/platform:*" ]
testonly = true
sources = [
"BlobBytesProviderTest.cpp",
"BlobDataTest.cpp",
]
configs += [ "//third_party/WebKit/Source/platform:blink_platform_config" ]
deps = [
"//base/test:test_support",
"//testing/gmock",
"//testing/gtest",
"//third_party/WebKit/Source/platform:platform",
]
}
......@@ -11,6 +11,8 @@ make_names("make_platform_loader_generated_fetch_initiator_type_names") {
output_dir = "$blink_platform_output_dir/loader/fetch"
}
# TODO(toyoshim): Consider to have a blink_core_sources-like template for
# BUILD.gn files under platform. See code review comments for details.
jumbo_source_set("loader") {
# This target is a logical part of the platform and only the platform target
# should depend on it.
......@@ -82,33 +84,20 @@ jumbo_source_set("loader") {
":make_platform_loader_generated_fetch_initiator_type_names")
configs += [
"//third_party/WebKit/Source:config",
"//third_party/WebKit/Source:non_test_config",
"//third_party/WebKit/Source:inside_blink",
"//third_party/WebKit/Source/platform:blink_platform_config",
"//third_party/WebKit/Source/platform:blink_platform_implementation",
# TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
"//build/config/compiler:no_size_t_to_int_warning",
]
deps = [
":make_platform_loader_generated_fetch_initiator_type_names",
"//components/link_header_util:link_header_util",
"//mojo/public/cpp/system:system",
# "//services/network/public/interfaces:interfaces_blink" is included in
# "//third_party/WebKit/Source/platform", which will contain this source set
"//storage/public/interfaces:interfaces_blink",
"//third_party/WebKit/Source/platform:make_platform_generated",
"//third_party/WebKit/common:blink_common",
"//third_party/WebKit/public:mojo_bindings_blink",
]
public_deps = [
"//base",
"//net",
"//third_party/icu",
"//v8",
"//third_party/WebKit/Source/platform/blob:blob",
"//third_party/WebKit/Source/platform/network:network",
"//third_party/WebKit/public:mojo_bindings_blink",
]
}
......@@ -136,17 +125,12 @@ jumbo_source_set("unit_tests") {
"fetch/ResourceTest.cpp",
]
defines = [ "INSIDE_BLINK" ]
configs += [
"//third_party/WebKit/Source/platform/wtf:wtf_config",
"//third_party/WebKit/Source:config",
]
configs += [ "//third_party/WebKit/Source/platform:blink_platform_config" ]
deps = [
"//testing/gmock",
"//testing/gtest",
"//third_party/WebKit/Source/platform",
"//third_party/WebKit/Source/platform:platform",
]
}
......@@ -169,14 +153,15 @@ jumbo_source_set("test_support") {
"testing/MockResourceClient.h",
]
defines = [ "INSIDE_BLINK" ]
configs += [
"//third_party/WebKit/Source/platform/wtf:wtf_config",
"//third_party/WebKit/Source:config",
"//third_party/WebKit/Source:non_test_config",
"//third_party/WebKit/Source/platform:blink_platform_config",
]
deps = [
"//third_party/WebKit/Source/platform",
public_deps = [
"//net",
"//skia",
"//third_party/WebKit/Source/platform/blob:generator",
"//third_party/icu",
]
}
# Copyright 2017 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/config/jumbo.gni")
import("//third_party/WebKit/Source/build/scripts/scripts.gni")
import("//third_party/WebKit/Source/platform/platform_generated.gni")
make_names("http_names") {
# TODO(toyoshim): Should be generated in the network directory.
in_files = [ "http_names.json5" ]
output_dir = blink_platform_output_dir
}
group("make_generated") {
visibility = [
":*",
"//third_party/WebKit/Source/platform:*",
]
public_deps = [
":http_names",
]
}
jumbo_source_set("network") {
visibility = [ "//third_party/WebKit/Source/platform/*" ]
sources = [
"ContentSecurityPolicyParsers.cpp",
"ContentSecurityPolicyParsers.h",
"ContentSecurityPolicyResponseHeaders.cpp",
"ContentSecurityPolicyResponseHeaders.h",
"EncodedFormData.cpp",
"EncodedFormData.h",
"FormDataEncoder.cpp",
"FormDataEncoder.h",
"HTTPHeaderMap.cpp",
"HTTPHeaderMap.h",
"HTTPParsers.cpp",
"HTTPParsers.h",
"HeaderFieldTokenizer.cpp",
"HeaderFieldTokenizer.h",
"NetworkHints.cpp",
"NetworkHints.h",
"NetworkInstrumentation.cpp",
"NetworkInstrumentation.h",
"NetworkLog.h",
"NetworkStateNotifier.cpp",
"NetworkStateNotifier.h",
"NetworkUtils.cpp",
"NetworkUtils.h",
"ParsedContentDisposition.cpp",
"ParsedContentDisposition.h",
"ParsedContentHeaderFieldParameters.cpp",
"ParsedContentHeaderFieldParameters.h",
"ParsedContentType.cpp",
"ParsedContentType.h",
"WebSocketHandshakeRequest.cpp",
"WebSocketHandshakeRequest.h",
"WebSocketHandshakeResponse.cpp",
"WebSocketHandshakeResponse.h",
"mime/ContentType.cpp",
"mime/ContentType.h",
"mime/MIMETypeFromURL.cpp",
"mime/MIMETypeFromURL.h",
"mime/MIMETypeRegistry.cpp",
"mime/MIMETypeRegistry.h",
]
sources += get_target_outputs(":http_names")
configs += [
"//third_party/WebKit/Source:non_test_config",
"//third_party/WebKit/Source/platform:blink_platform_config",
"//third_party/WebKit/Source/platform:blink_platform_implementation",
]
public_deps = [
":make_generated",
"//net",
"//third_party/WebKit/Source/platform/blob",
"//third_party/WebKit/common:blink_common",
"//third_party/WebKit/public:mojo_bindings_blink",
]
deps = [
"//media",
]
}
jumbo_source_set("unit_tests") {
visibility = [ "//third_party/WebKit/Source/platform:*" ]
testonly = true
sources = [
"EncodedFormDataTest.cpp",
"HTTPParsersTest.cpp",
"NetworkStateNotifierTest.cpp",
"NetworkUtilsTest.cpp",
"ParsedContentDispositionTest.cpp",
"ParsedContentHeaderFieldParametersTest.cpp",
"ParsedContentTypeTest.cpp",
"mime/MIMETypeRegistryTest.cpp",
]
configs += [ "//third_party/WebKit/Source/platform:blink_platform_config" ]
deps = [
"//testing/gtest",
"//third_party/WebKit/Source/platform:platform",
]
}
jumbo_source_set("test_support") {
visibility = [ "//third_party/WebKit/Source/platform:test_support" ]
testonly = true
sources = [
"mime/MockMimeRegistry.h",
]
configs += [
"//third_party/WebKit/Source:non_test_config",
"//third_party/WebKit/Source/platform:blink_platform_config",
]
public_deps = [
"//net",
"//third_party/WebKit/Source/platform/blob:generator",
]
}
......@@ -766,6 +766,7 @@ mojom("mojo_bindings") {
"//chrome/common:mojo_bindings_blink",
"//third_party/WebKit/Source/platform",
"//third_party/WebKit/Source/platform/loader",
"//third_party/WebKit/Source/platform/network",
]
sources = [
"platform/address_space.mojom",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment