blob: a44296af42ae0df322e48ef5f28c6eded4cb1fc8 [file] [log] [blame]
# Copyright 2014 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/ui.gni")
import("//third_party/WebKit/Source/bindings/bindings.gni")
import("//third_party/WebKit/Source/bindings/core/v8/generated.gni")
import("//third_party/WebKit/Source/bindings/modules/modules.gni")
import("//third_party/WebKit/Source/bindings/modules/v8/generated.gni")
import("//third_party/WebKit/Source/bindings/scripts/scripts.gni")
import("//third_party/WebKit/Source/config.gni")
import("//third_party/WebKit/Source/core/core.gni")
import("//third_party/WebKit/Source/build/scripts/scripts.gni")
import("//third_party/WebKit/Source/platform/platform_generated.gni")
visibility = "//third_party/WebKit/Source/*"
rel_blink_core_gen_dir = rebase_path(blink_core_output_dir, root_build_dir)
# Compute the optimization level. The GYP code sets "optimize: max" which sets
# speed-over-size optimization for official builds on Windows only. The GN's
# build optimize_max config applies this optimization on all platforms, so
# compute how to modify the config list to duplicate the GYP behavior.
if (is_debug) {
core_config_remove = [ "//build/config/compiler:no_optimize" ]
core_config_add = core_config_remove # NOP
} else {
core_config_remove = [ "//build/config/compiler:optimize" ]
if (is_win && is_official_build) {
core_config_add = [ "//build/config/compiler:optimize_max" ]
} else {
core_config_add = core_config_remove # NOP
}
}
# Core targets also get wexit time destructors.
core_config_add += [ "//build/config/compiler:wexit_time_destructors" ]
config("core_include_dirs") {
include_dirs = [
"..",
"../..",
# FIXME: Remove these once core scripts generates qualified
# includes correctly: http://crbug.com/358074
blink_core_output_dir,
blink_modules_output_dir,
bindings_core_v8_output_dir,
bindings_modules_v8_output_dir,
# FIXME: MediaQueryListListener.cpp includes
# "gen/blink/bindings/core/v8/V8MediaQueryList.h" relative to "gen/blink"
# which is busted. This file (and any other ones that do a similar thing)
# should be fixed and this can be removed.
"$root_gen_dir/blink",
]
if (is_android && use_openmax_dl_fft) {
include_dirs += [ "//third_party/openmax_dl" ]
}
}
# GYP version: WebKit/Source/core/core.gyp:webcore_generated
source_set("generated") {
deps = [
":make_core_generated",
":prerequisites",
"inspector:debugger_script_source",
"inspector:inspector_overlay_page",
"inspector:protocol_sources",
"inspector:injected_script_source",
"inspector:injected_canvas_script_source",
"inspector:instrumentation_sources",
"//gin",
"//skia",
"//third_party/iccjpeg",
"//third_party/libpng",
"//third_party/libwebp",
"//third_party/libxml",
"//third_party/libxslt",
"//third_party/npapi",
"//third_party/qcms",
"//third_party/sqlite",
"//third_party/WebKit/Source/bindings/core/v8:bindings_core_v8_generated",
# FIXME: don't depend on bindings/modules http://crbug.com/358074
"//third_party/WebKit/Source/bindings/modules:bindings_modules_generated",
"//third_party/WebKit/Source/bindings/modules/v8:bindings_modules_generated",
"//third_party/WebKit/Source/platform:make_platform_generated",
"//third_party/WebKit/Source/wtf",
"//url",
"//v8",
]
}
# GYP version: WebKit/Source/core/core.gyp:webcore_prerequisites
source_set("prerequisites") {
exported_deps = [
"//third_party/WebKit/Source/wtf",
"//gpu/command_buffer/client:gles2_c_lib",
"//skia",
"//third_party/angle:translator",
"//third_party/iccjpeg",
"//third_party/libpng",
"//third_party/libwebp",
"//third_party/libxml",
"//third_party/libxslt",
"//third_party/npapi",
"//third_party/ots",
"//third_party/qcms",
"//third_party/sqlite",
"//third_party/zlib",
"//url",
"//v8",
]
deps = [
":make_core_generated",
"inspector:debugger_script_source",
"inspector:injected_canvas_script_source",
"inspector:injected_script_source",
"inspector:inspector_overlay_page",
"inspector:protocol_sources",
"inspector:instrumentation_sources",
"//third_party/WebKit/Source/bindings/core/v8:bindings_core_v8_generated",
# FIXME: don't depend on bindings_modules http://crbug.com/358074
"//third_party/WebKit/Source/bindings/modules/v8:bindings_modules_generated",
"//third_party/WebKit/Source/platform",
] + exported_deps
forward_dependent_configs_from = exported_deps
direct_dependent_configs = [
":core_include_dirs",
"//third_party/WebKit/Source:config",
"//third_party/WebKit/Source:inside_blink",
]
}
# Note that this is a source set rather than a group, even though it has no
# sources. A group would implicitly forward all direct dependent configs
# through it, but we want to keep our internal targets'
# direct_dependent_configs private and only forward some of them.
#
# GYP version: WebKit/Source/core/core.gyp:webcore
source_set("core") {
visibility = "//third_party/WebKit/*"
exported_deps = [
":core_generated",
"//skia",
"//third_party/npapi",
"//third_party/qcms",
"//third_party/WebKit/Source/wtf",
"//url",
"//v8",
]
configs -= core_config_remove
configs += core_config_add
deps = [
":dom",
":html",
":remaining",
":rendering",
":svg",
] + exported_deps
forward_dependent_configs_from = exported_deps
direct_dependent_configs = [
":core_include_dirs",
]
# TODO(GYP) IPP libraries pkg-config. These seem to be experimental and used
# only on x86 Android. See also below. There should be one pkg-config call
# that creates a config used in both of these cases.
}
# GYP version: //third_party/WebKit/Source/core/core.gyp:webcore_dom
source_set("dom") {
sources = rebase_path(webcore_dom_files, ".", "//")
configs -= core_config_remove
configs += core_config_add
if (is_win) {
cflags = [ "/wd4267" ] # size_t to int truncation.
}
deps = [
":prerequisites",
]
}
# GYP version: //third_party/WebKit/Source/core/core.gyp:webcore_html
source_set("html") {
sources = rebase_path(webcore_html_files, ".", "//")
configs -= core_config_remove
configs += core_config_add
deps = [
":prerequisites",
]
# TODO(GYP)
# Shard this target into parts to work around linker limitations.
# on link time code generation builds.
#['OS=="win" and buildtype=="Official"', {
# 'msvs_shard': 5,
#}],
}
# GYP version: //third_party/WebKit/Source/core/core.gyp:webcore_svg
source_set("svg") {
sources = rebase_path(webcore_svg_files, ".", "//")
configs -= core_config_remove
configs += core_config_add
deps = [
":prerequisites",
]
# TODO(GYP)
# Shard this taret into parts to work around linker limitations.
# on link time code generation builds.
#['OS=="win" and buildtype=="Official"', {
# 'msvs_shard': 5,
#}],
}
# GYP version: //third_party/WebKit/Source/core/core.gyp:webcore_remaining
source_set("remaining") {
# This is currently a mashup of "webcore_rendering" and "webcore_remaining"
# in GYP. The file list variable is the same and then GYP filters on wether
# the path starts with "rendering/" or not. We should tweak the .gypis a bit
# to separate out the rendering files.
sources = rebase_path(webcore_files, ".", "//")
configs -= core_config_remove
configs += core_config_add
cflags = []
libs = []
deps = [
":prerequisites",
]
if (is_win) {
cflags += [
"/wd4267",
"/wd4334",
]
} else { # !is_win
sources -= [
"rendering/RenderThemeChromiumFontProviderWin.cpp",
]
}
if (!is_linux) {
sources -= [
"rendering/RenderThemeChromiumFontProviderLinux.cpp",
]
}
if (is_android) {
# Due to a bug in gcc 4.6 in android NDK, we got warnings about
# uninitialized variable.
# TODO: try removing now that we are on GCC 4.8.
cflags += [ "-Wno-uninitialized" ]
} else { # !is_android
sources -= [
"rendering/RenderThemeChromiumAndroid.cpp",
"rendering/RenderThemeChromiumAndroid.h",
]
}
if (is_mac) {
sources -= [
"rendering/RenderThemeChromiumFontProvider.cpp",
"rendering/RenderThemeChromiumFontProvider.h",
"rendering/RenderThemeChromiumSkia.cpp",
"rendering/RenderThemeChromiumSkia.h",
]
libs += [ "Carbon.framework" ]
} else { # !is_mac
sources -= [
"editing/SmartReplaceCF.cpp",
]
}
if (!use_default_render_theme) {
sources -= [
"rendering/RenderThemeChromiumDefault.cpp",
"rendering/RenderThemeChromiumDefault.h",
]
}
}
# GYP version: //third_party/WebKit/Source/core/core.gyp:webcore_rendering
source_set("rendering") {
# The files that go here are currently in "remaining".
}
# GYP version: //third_party/WebKit/Source/core/core.gyp:webcore_generated
source_set("core_generated") {
sources = bindings_v8_files
# These files include all the .cpp files generated from the .idl files
# in webcore_files.
sources += bindings_core_generated_aggregate_files
sources += [
# Additional .cpp files for HashTools.h
"$blink_core_output_dir/CSSPropertyNames.cpp",
"$blink_core_output_dir/CSSValueKeywords.cpp",
# Additional .cpp files from make_core_generated actions.
"$blink_core_output_dir/Event.cpp",
"$blink_core_output_dir/EventHeaders.h",
"$blink_core_output_dir/EventInterfaces.h",
"$blink_core_output_dir/EventNames.cpp",
"$blink_core_output_dir/EventNames.h",
"$blink_core_output_dir/EventTargetHeaders.h",
"$blink_core_output_dir/EventTargetInterfaces.h",
"$blink_core_output_dir/EventTargetNames.cpp",
"$blink_core_output_dir/EventTargetNames.h",
"$blink_core_output_dir/EventTypeNames.cpp",
"$blink_core_output_dir/EventTypeNames.h",
"$blink_core_output_dir/FetchInitiatorTypeNames.cpp",
"$blink_core_output_dir/HTMLElementFactory.cpp",
"$blink_core_output_dir/HTMLElementFactory.h",
"$blink_core_output_dir/HTMLElementLookupTrie.cpp",
"$blink_core_output_dir/HTMLElementLookupTrie.h",
"$blink_core_output_dir/HTMLNames.cpp",
"$blink_core_output_dir/HTMLTokenizerNames.cpp",
"$blink_core_output_dir/InputTypeNames.cpp",
"$blink_core_output_dir/MathMLNames.cpp",
"$blink_core_output_dir/SVGNames.cpp",
"$blink_core_output_dir/UserAgentStyleSheetsData.cpp",
"$blink_core_output_dir/V8HTMLElementWrapperFactory.cpp",
"$blink_core_output_dir/XLinkNames.cpp",
"$blink_core_output_dir/XMLNSNames.cpp",
"$blink_core_output_dir/XMLNames.cpp",
# Generated from HTMLEntityNames.in
"$blink_core_output_dir/HTMLEntityTable.cpp",
# Generated from MediaFeatureNames.in
"$blink_core_output_dir/MediaFeatureNames.cpp",
# Generated from MediaTypeNames.in
"$blink_core_output_dir/MediaTypeNames.cpp",
# Generated from CSSTokenizer-in.cpp
"$blink_core_output_dir/CSSTokenizer.cpp",
# Generated from BisonCSSParser-in.cpp
"$blink_core_output_dir/BisonCSSParser.cpp",
# Generated from HTMLMetaElement-in.cpp
"$blink_core_output_dir/HTMLMetaElement.cpp",
# Additional .cpp files from the make_core_generated rules.
"$blink_core_output_dir/CSSGrammar.cpp",
"$blink_core_output_dir/XPathGrammar.cpp",
# Additional .cpp files from the inspector_protocol_sources list.
"$blink_core_output_dir/InspectorFrontend.cpp",
"$blink_core_output_dir/InspectorBackendDispatcher.cpp",
"$blink_core_output_dir/InspectorTypeBuilder.cpp",
# Additional .cpp files from the inspector_instrumentation_sources list.
"$blink_core_output_dir/InspectorCanvasInstrumentationInl.h",
"$blink_core_output_dir/InspectorConsoleInstrumentationInl.h",
"$blink_core_output_dir/InspectorInstrumentationInl.h",
"$blink_core_output_dir/InspectorOverridesInl.h",
"$blink_core_output_dir/InstrumentingAgentsInl.h",
"$blink_core_output_dir/InspectorInstrumentationImpl.cpp",
# Additional .cpp files for SVG.
"$blink_core_output_dir/SVGElementFactory.cpp",
"$blink_core_output_dir/V8SVGElementWrapperFactory.cpp",
# Generated from make_style_shorthands.py
"$blink_core_output_dir/StylePropertyShorthand.cpp",
# Generated from make_style_builder.py
"$blink_core_output_dir/StyleBuilder.cpp",
"$blink_core_output_dir/StyleBuilderFunctions.cpp",
]
configs -= core_config_remove
configs += core_config_add
configs += [
"..:inside_blink",
]
deps = [
":make_core_generated",
":prerequisites",
"inspector:inspector_overlay_page",
"inspector:protocol_sources",
"inspector:instrumentation_sources",
"inspector:injected_canvas_script_source",
"inspector:injected_script_source",
"inspector:debugger_script_source",
"//gin",
"//skia",
"//third_party/iccjpeg",
"//third_party/libpng",
"//third_party/libwebp",
"//third_party/libxml",
"//third_party/libxslt",
"//third_party/npapi",
"//third_party/qcms",
"//third_party/sqlite",
"//third_party/WebKit/Source/bindings/core/v8:bindings_core_v8_generated",
# FIXME: don't depend on bindings/modules http://crbug.com/358074
"//third_party/WebKit/Source/bindings/modules:bindings_modules_generated",
"//third_party/WebKit/Source/bindings/modules/v8:bindings_modules_generated",
"//third_party/WebKit/Source/platform:make_platform_generated",
"//third_party/WebKit/Source/wtf",
"//url",
"//v8",
]
configs += [ ":core_include_dirs" ]
include_dirs = [
"$root_gen_dir/blink",
]
cflags = []
defines = []
if (is_win && component_mode == "shared_library") {
defines += [ "USING_V8_SHARED" ]
}
if (is_win) {
cflags += [
# In generated bindings code: "switch contains default but no case".
# Disable c4267 warnings until we fix size_t to int truncations.
# 4702 is disabled because of issues in Bison-generated
# XPathGrammar.cpp and CSSGrammar.cpp.
"/wd4065",
"/wd4267",
"/wd4702",
]
}
# TODO(GYP) More IPP libraries, see above.
#if ((is_linux || is_android) && use_webaudio_ipp)
# ["OS in ("linux", "android") and "WTF_USE_WEBAUDIO_IPP=1" in feature_defines", {
# "cflags": [
# "<!@(pkg-config --cflags-only-I ipp)",
# ],
# }],
#],
}
# core_bindings_generated ------------------------------------------------------
# GYP version: WebKit/Source/core/core_generated.gyp:core_event_interfaces
generate_event_interfaces("core_event_interfaces") {
sources = core_event_idl_files
output_file = "core/EventInterfaces.in"
}
# generated_testing_idls -------------------------------------------------------
# GYP version: WebKit/Source/core/core_generated.gyp:generated_testing_idls
group("generated_testing_idls") {
deps = [
":generated_testing_idls_settings",
":generated_testing_idls_internal_runtime_flags",
]
}
# "Settings" action in generated_testing_idls from GYP.
action("generated_testing_idls_settings") {
script = "../build/scripts/make_settings.py"
source_prereqs = scripts_for_in_files + [
"../build/scripts/make_settings.py",
"../build/scripts/templates/InternalSettingsGenerated.idl.tmpl",
"../build/scripts/templates/InternalSettingsGenerated.cpp.tmpl",
"../build/scripts/templates/InternalSettingsGenerated.h.tmpl",
"../build/scripts/templates/SettingsMacros.h.tmpl",
"frame/Settings.in",
]
outputs = [
"$blink_core_output_dir/SettingsMacros.h",
"$blink_core_output_dir/InternalSettingsGenerated.idl",
"$blink_core_output_dir/InternalSettingsGenerated.cpp",
"$blink_core_output_dir/InternalSettingsGenerated.h",
]
args = [
rebase_path("frame/Settings.in", root_build_dir),
"--output_dir", rel_blink_core_gen_dir,
]
}
# "InternalRuntimeFlags" action in generated_testing_idls from GYP.
action("generated_testing_idls_internal_runtime_flags") {
script = "../build/scripts/make_internal_runtime_flags.py"
source_prereqs = scripts_for_in_files + [
"../build/scripts/make_internal_runtime_flags.py",
"../platform/RuntimeEnabledFeatures.in",
"../build/scripts/templates/InternalRuntimeFlags.h.tmpl",
"../build/scripts/templates/InternalRuntimeFlags.idl.tmpl",
]
outputs = [
"$blink_core_output_dir/InternalRuntimeFlags.idl",
"$blink_core_output_dir/InternalRuntimeFlags.h",
]
args = [
rebase_path("../platform/RuntimeEnabledFeatures.in", root_build_dir),
"--output_dir", rel_blink_core_gen_dir,
]
}
# make_core_generated ----------------------------------------------------------
# GYP version: WebKit/Source/core/core_generated.gyp:make_core_generated
group("make_core_generated") {
deps = [
":make_core_generated_xml_viewer_css",
":make_core_generated_xml_viewer_js",
":make_core_generated_html_entity_table",
":make_core_generated_css_property_names",
":make_core_generated_media_feature_names",
":make_core_generated_media_features",
":make_core_generated_media_type_names",
":make_core_generated_media_query_tokenizer_codepoints",
":make_core_generated_style_property_shorthand",
":make_core_generated_style_builder",
":make_core_generated_css_value_keywords",
":make_core_generated_html_element_factory",
":make_core_generated_html_element_type_helpers",
":make_core_generated_svg_names",
":make_core_generated_svg_element_type_helpers",
":make_core_generated_event_factory",
":make_core_generated_event_names",
":make_core_generated_event_target_factory",
":make_core_generated_event_target_names",
":make_core_generated_math_ml_names",
":make_core_generated_user_agent_style_sheets",
":make_core_generated_fetch_initiator_type_names",
":make_core_generated_event_type_names",
":make_core_generated_html_tokenizer_names",
":make_core_generated_input_type_names",
":make_core_generated_xlink_names",
":make_core_generated_xml_ns_names",
":make_core_generated_xml_names",
":make_core_generated_make_token_matcher",
":make_core_generated_make_parser",
":make_core_generated_make_token_matcher_for_viewport",
":make_core_generated_html_element_lookup_trie",
":make_core_generated_bison",
]
}
# "CSSPropertyNames" in make_core_generated from GYP.
process_in_files("make_core_generated_css_property_names") {
script = "../build/scripts/make_css_property_names.py"
in_files = [
"css/CSSPropertyNames.in",
"css/SVGCSSPropertyNames.in",
]
outputs = [
"$blink_core_output_dir/CSSPropertyNames.cpp",
"$blink_core_output_dir/CSSPropertyNames.h",
]
other_args = [ "--defines", feature_defines_string ]
}
# "MediaFeatures" in make_core_generated from GYP.
process_in_files("make_core_generated_media_features") {
script = "../build/scripts/make_media_features.py"
in_files = [
"css/MediaFeatureNames.in",
]
other_inputs = [
"../build/scripts/make_media_features.py",
"../build/scripts/templates/MediaFeatures.h.tmpl",
]
outputs = [
"$blink_core_output_dir/MediaFeatures.h",
]
other_args = [ "--defines", feature_defines_string ]
}
# "StylePropertyShorthand" in make_core_generated from GYP.
process_in_files("make_core_generated_style_property_shorthand") {
script = "../build/scripts/make_style_shorthands.py"
in_files = [
"css/CSSShorthands.in",
]
other_inputs = [
"../build/scripts/templates/StylePropertyShorthand.cpp.tmpl",
"../build/scripts/templates/StylePropertyShorthand.h.tmpl",
]
outputs = [
"$blink_core_output_dir/StylePropertyShorthand.cpp",
"$blink_core_output_dir/StylePropertyShorthand.h",
]
}
# "StyleBuilder" in make_core_generated from GYP.
process_in_files("make_core_generated_style_builder") {
script = "../build/scripts/make_style_builder.py"
in_files = [
"css/CSSProperties.in",
]
other_inputs = [
"../build/scripts/templates/StyleBuilder.cpp.tmpl",
"../build/scripts/templates/StyleBuilderFunctions.cpp.tmpl",
"../build/scripts/templates/StyleBuilderFunctions.h.tmpl",
]
outputs = [
"$blink_core_output_dir/StyleBuilder.cpp",
"$blink_core_output_dir/StyleBuilderFunctions.h",
"$blink_core_output_dir/StyleBuilderFunctions.cpp",
]
}
# "CSSValueKeywords" in make_core_generated from GYP.
process_in_files("make_core_generated_css_value_keywords") {
script = "../build/scripts/make_css_value_keywords.py"
in_files = [
"css/CSSValueKeywords.in",
"css/SVGCSSValueKeywords.in",
]
outputs = [
"$blink_core_output_dir/CSSValueKeywords.cpp",
"$blink_core_output_dir/CSSValueKeywords.h",
]
other_args = [
"--gperf", gperf_exe,
"--defines", feature_defines_string
]
}
# "HTMLElementFactory" in make_core_generated from GYP.
process_in_files("make_core_generated_html_element_factory") {
script = "../build/scripts/make_element_factory.py"
in_files = [
"html/HTMLTagNames.in",
"html/HTMLAttributeNames.in",
]
other_inputs = make_element_factory_files
outputs = [
"$blink_core_output_dir/HTMLElementFactory.cpp",
"$blink_core_output_dir/HTMLElementFactory.h",
"$blink_core_output_dir/HTMLNames.cpp",
"$blink_core_output_dir/HTMLNames.h",
"$blink_core_output_dir/V8HTMLElementWrapperFactory.cpp",
"$blink_core_output_dir/V8HTMLElementWrapperFactory.h",
]
}
# "HTMLElementTypeHelpers" in make_core_generated from GYP.
process_in_files("make_core_generated_html_element_type_helpers") {
script = "../build/scripts/make_element_type_helpers.py"
in_files = [
"html/HTMLTagNames.in",
]
other_inputs = make_element_type_helpers_files
outputs = [
"$blink_core_output_dir/HTMLElementTypeHelpers.h",
]
}
# "SVGNames" in make_core_generated from GYP.
process_in_files("make_core_generated_svg_names") {
script = "../build/scripts/make_element_factory.py"
in_files = [
"svg/SVGTagNames.in",
"svg/SVGAttributeNames.in",
]
other_inputs = make_element_factory_files
outputs = [
"$blink_core_output_dir/SVGElementFactory.cpp",
"$blink_core_output_dir/SVGElementFactory.h",
"$blink_core_output_dir/SVGNames.cpp",
"$blink_core_output_dir/SVGNames.h",
"$blink_core_output_dir/V8SVGElementWrapperFactory.cpp",
"$blink_core_output_dir/V8SVGElementWrapperFactory.h",
]
}
# "SVGElementTypeHelpers" in make_core_generated from GYP.
process_in_files("make_core_generated_svg_element_type_helpers") {
script = "../build/scripts/make_element_type_helpers.py"
in_files = [
"svg/SVGTagNames.in",
]
other_inputs = make_element_type_helpers_files
outputs = [
"$blink_core_output_dir/SVGElementTypeHelpers.h",
]
}
# "EventFactory" in make_core_generated from GYP.
process_in_files("make_core_generated_event_factory") {
script = "../build/scripts/make_event_factory.py"
in_files = [
"$blink_core_output_dir/EventInterfaces.in",
"events/EventAliases.in",
]
other_inputs = make_event_factory_files
outputs = [
"$blink_core_output_dir/Event.cpp",
"$blink_core_output_dir/EventHeaders.h",
"$blink_core_output_dir/EventInterfaces.h",
]
}
# make_event_factory -----------------------------------------------------------
# "EventTargetFactory" in make_core_generated from GYP.
make_event_factory("make_core_generated_event_target_factory") {
in_files = [
"events/EventTargetFactory.in",
]
outputs = [
"$blink_core_output_dir/EventTargetHeaders.h",
"$blink_core_output_dir/EventTargetInterfaces.h",
]
}
# "MediaFeatureNames" in make_core_generated from GYP.
process_in_files("make_core_generated_media_feature_names") {
script = "../build/scripts/make_media_feature_names.py"
in_files = [
"css/MediaFeatureNames.in",
]
other_inputs = make_names_files
outputs = [
"$blink_core_output_dir/MediaFeatureNames.cpp",
"$blink_core_output_dir/MediaFeatureNames.h",
]
other_args = [ "--defines", feature_defines_string ]
}
# make_names -------------------------------------------------------------------
# "MediaTypeNames" in make_core_generated from GYP.
make_names("make_core_generated_media_type_names") {
in_files = [
"css/MediaTypeNames.in",
]
outputs = [
"$blink_core_output_dir/MediaTypeNames.cpp",
"$blink_core_output_dir/MediaTypeNames.h",
]
}
# "EventNames" in make_core_generated from GYP.
make_names("make_core_generated_event_names") {
in_files = [
"$blink_core_output_dir/EventInterfaces.in",
]
outputs = [
"$blink_core_output_dir/EventNames.cpp",
"$blink_core_output_dir/EventNames.h",
]
}
# "EventTargetNames" in make_core_generated from GYP.
make_names("make_core_generated_event_target_names") {
in_files = [
"events/EventTargetFactory.in",
]
outputs = [
"$blink_core_output_dir/EventTargetNames.cpp",
"$blink_core_output_dir/EventTargetNames.h",
]
}
# "FetchInitiatorTypeNames" in make_core_generated from GYP.
make_names("make_core_generated_fetch_initiator_type_names") {
in_files = [
"fetch/FetchInitiatorTypeNames.in",
]
outputs = [
"$blink_core_output_dir/FetchInitiatorTypeNames.cpp",
"$blink_core_output_dir/FetchInitiatorTypeNames.h",
]
}
# "EventTypeNames" in make_core_generated from GYP.
make_names("make_core_generated_event_type_names") {
in_files = [
"events/EventTypeNames.in",
]
outputs = [
"$blink_core_output_dir/EventTypeNames.cpp",
"$blink_core_output_dir/EventTypeNames.h",
]
}
# "HTMLTokenizerNames" in make_core_generated from GYP.
make_names("make_core_generated_html_tokenizer_names") {
in_files = [
"html/parser/HTMLTokenizerNames.in",
]
outputs = [
"$blink_core_output_dir/HTMLTokenizerNames.cpp",
"$blink_core_output_dir/HTMLTokenizerNames.h",
]
}
# "InputTypeNames" in make_core_generated from GYP.
make_names("make_core_generated_input_type_names") {
in_files = [
"html/forms/InputTypeNames.in",
]
outputs = [
"$blink_core_output_dir/InputTypeNames.cpp",
"$blink_core_output_dir/InputTypeNames.h",
]
}
# make_qualified_names ---------------------------------------------------------
# "MathMLNames" in make_core_generated from GYP.
make_qualified_names("make_core_generated_math_ml_names") {
in_files = [
"html/parser/MathMLTagNames.in",
"html/parser/MathMLAttributeNames.in",
]
outputs = [
"$blink_core_output_dir/MathMLNames.cpp",
"$blink_core_output_dir/MathMLNames.h",
]
}
# "XLinkNames" in make_core_generated from GYP.
make_qualified_names("make_core_generated_xlink_names") {
in_files = [
"svg/xlinkattrs.in",
]
outputs = [
"$blink_core_output_dir/XLinkNames.cpp",
"$blink_core_output_dir/XLinkNames.h",
]
}
# "XMLNSNames" in make_core_generated from GYP.
make_qualified_names("make_core_generated_xml_ns_names") {
in_files = [
"xml/xmlnsattrs.in",
]
outputs = [
"$blink_core_output_dir/XMLNSNames.cpp",
"$blink_core_output_dir/XMLNSNames.h",
]
}
# "XMLNames" in make_core_generated from GYP.
make_qualified_names("make_core_generated_xml_names") {
in_files = [
"xml/xmlattrs.in",
]
outputs = [
"$blink_core_output_dir/XMLNames.cpp",
"$blink_core_output_dir/XMLNames.h",
]
}
# make_token_matcher -----------------------------------------------------------
# "MakeTokenMatcher" in make_core_generated from GYP.
make_token_matcher("make_core_generated_make_token_matcher") {
input_file = "css/CSSTokenizer-in.cpp"
output_file = "$blink_core_output_dir/CSSTokenizer.cpp"
}
# "MakeParser" in make_core_generated from GYP.
make_token_matcher("make_core_generated_make_parser") {
input_file = "css/parser/BisonCSSParser-in.cpp"
output_file = "$blink_core_output_dir/BisonCSSParser.cpp"
}
# "MakeTokenMatcherForViewport" in make_core_generated from GYP.
make_token_matcher("make_core_generated_make_token_matcher_for_viewport") {
input_file = "html/HTMLMetaElement-in.cpp"
output_file = "$blink_core_output_dir/HTMLMetaElement.cpp"
}
# One-off scripts --------------------------------------------------------------
# "generateXMLViewerCSS" in make_core_generated from GYP.
action("make_core_generated_xml_viewer_css") {
visibility = ":make_core_generated"
script = "../build/scripts/xxd.py"
source_prereqs = [
"xml/XMLViewer.css",
]
outputs = [
"$blink_core_output_dir/XMLViewerCSS.h",
]
args = [
"XMLViewer_css",
rebase_path(source_prereqs[0], root_build_dir),
rebase_path(outputs[0], root_build_dir),
]
deps = make_core_generated_deps
}
# "generateXMLViewerJS" in make_core_generated from GYP.
action("make_core_generated_xml_viewer_js") {
visibility = ":make_core_generated"
script = "../build/scripts/xxd.py"
source_prereqs = [
"xml/XMLViewer.js",
]
outputs = [
"$blink_core_output_dir/XMLViewerJS.h",
]
args = [
"XMLViewer_js",
rebase_path(source_prereqs[0], root_build_dir),
rebase_path(outputs[0], root_build_dir),
]
deps = make_core_generated_deps
}
# "HTMLEntityTable" in make_core_generated from GYP.
action("make_core_generated_html_entity_table") {
visibility = ":make_core_generated"
script = "html/parser/create-html-entity-table"
source_prereqs = [
"html/parser/HTMLEntityNames.in",
]
outputs = [
"$blink_core_output_dir/HTMLEntityTable.cpp",
]
args = [ "-o" ] + rebase_path(outputs, root_build_dir)
args += rebase_path(source_prereqs, root_build_dir)
deps = make_core_generated_deps
}
# "MediaQueryTokenizerCodepoints" in make_core_generated from GYP.
action("make_core_generated_media_query_tokenizer_codepoints") {
visibility = ":make_core_generated"
script = "../build/scripts/make_mediaquery_tokenizer_codepoints.py"
outputs = [
"$blink_core_output_dir/MediaQueryTokenizerCodepoints.cpp",
]
args = [
"--output_dir", rel_blink_core_gen_dir,
"--defines", feature_defines_string
]
deps = make_core_generated_deps
}
# "UserAgentStyleSheets" in make_core_generated from GYP.
action("make_core_generated_user_agent_style_sheets") {
visibility = ":make_core_generated"
script = "../build/scripts/action_useragentstylesheets.py"
scripts = [
"css/make-css-file-arrays.pl",
"../build/scripts/preprocessor.pm",
]
stylesheets = [
"css/html.css",
"css/quirks.css",
"css/view-source.css",
"css/themeChromium.css",
"css/themeChromiumAndroid.css",
"css/themeChromiumLinux.css",
"css/themeChromiumSkia.css",
"css/themeMac.css",
"css/themeWin.css",
"css/themeWinQuirks.css",
"css/svg.css",
"css/navigationTransitions.css",
"css/mathml.css",
"css/mediaControls.css",
"css/mediaControlsAndroid.css",
"css/fullscreen.css",
"css/xhtmlmp.css",
"css/viewportAndroid.css",
]
source_prereqs = scripts + stylesheets
outputs = [
"$blink_core_output_dir/UserAgentStyleSheets.h",
"$blink_core_output_dir/UserAgentStyleSheetsData.cpp",
]
args =
rebase_path(outputs, root_build_dir) +
rebase_path(stylesheets, root_build_dir) +
[ "--" ] +
rebase_path(scripts, root_build_dir) +
[ "--", "--defines", feature_defines_string ] +
[ preprocessor ] +
[ "--perl", perl_exe ]
deps = make_core_generated_deps
}
# "HTMLElementLookupTrie" in make_core_generated from GYP.
action("make_core_generated_html_element_lookup_trie") {
visibility = ":make_core_generated"
script = "../build/scripts/make_element_lookup_trie.py"
input_file = "html/HTMLTagNames.in"
source_prereqs = scripts_for_in_files + [
input_file,
"../build/scripts/templates/ElementLookupTrie.cpp.tmpl",
"../build/scripts/templates/ElementLookupTrie.h.tmpl",
]
outputs = [
"$blink_core_output_dir/HTMLElementLookupTrie.cpp",
"$blink_core_output_dir/HTMLElementLookupTrie.h",
]
args = [
rebase_path(input_file, root_build_dir),
"--output_dir", rel_blink_core_gen_dir,
]
deps = make_core_generated_deps
}
# The bison rules from make_core_generated.
action_foreach("make_core_generated_bison") {
script = "../build/scripts/rule_bison.py"
sources = [
"css/CSSGrammar.y",
"xml/XPathGrammar.y",
]
outputs = [
"$blink_core_output_dir/{{source_name_part}}.cpp",
"$blink_core_output_dir/{{source_name_part}}.h",
]
args = [
"{{source}}",
rel_blink_core_gen_dir,
bison_exe,
]
deps = make_core_generated_deps
}