Commit b46e7e96 authored by brettw@chromium.org's avatar brettw@chromium.org

GN chrome/common build, rename enable_printing.

This adds the missing conditions to the chrome/common GN build file (previously
only the basic files were there). Some refactoring of the GYP file to make this
possible.

Renames the enable_printing flag to printing_mode since this is an integer
tri-state.

Minor improvements to chrome/renderer

TBR=jamesr@chromium.org
Original review=https://codereview.chromium.org/400243003/

BUG=

Review URL: https://codereview.chromium.org/409683003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284783 0039d316-1c4b-4281-b951-d872f2087c98
parent ae15b406
...@@ -52,9 +52,9 @@ config("feature_flags") { ...@@ -52,9 +52,9 @@ config("feature_flags") {
if (enable_plugins) { if (enable_plugins) {
defines += [ "ENABLE_PLUGINS=1" ] defines += [ "ENABLE_PLUGINS=1" ]
} }
if (enable_printing > 0) { if (printing_mode > 0) {
defines += [ "ENABLE_PRINTING=1" ] defines += [ "ENABLE_PRINTING=1" ]
if (enable_printing < 2) { if (printing_mode < 2) {
defines += [ "ENABLE_FULL_PRINTING=1" ] defines += [ "ENABLE_FULL_PRINTING=1" ]
} }
} }
......
...@@ -56,9 +56,9 @@ enable_pepper_cdms = enable_plugins && (is_linux || is_mac || is_win) ...@@ -56,9 +56,9 @@ enable_pepper_cdms = enable_plugins && (is_linux || is_mac || is_win)
# fully, and 2 enables only the codepath to generate a Metafile (e.g. usually # fully, and 2 enables only the codepath to generate a Metafile (e.g. usually
# a PDF or EMF) and disables print preview, cloud print, UI, etc. # a PDF or EMF) and disables print preview, cloud print, UI, etc.
if (is_android) { if (is_android) {
enable_printing = 2 printing_mode = 2
} else { } else {
enable_printing = 1 printing_mode = 1
} }
# The seccomp-bpf sandbox is only supported on three architectures # The seccomp-bpf sandbox is only supported on three architectures
......
...@@ -138,9 +138,9 @@ if (enable_extensions) { ...@@ -138,9 +138,9 @@ if (enable_extensions) {
if (enable_plugins) { if (enable_plugins) {
grit_defines += [ "-D", "enable_plugins" ] grit_defines += [ "-D", "enable_plugins" ]
} }
if (enable_printing != 0) { if (printing_mode != 0) {
grit_defines += [ "-D", "enable_printing" ] grit_defines += [ "-D", "enable_printing" ]
if (enable_printing == 1) { if (printing_mode == 1) {
grit_defines += [ "-D", "enable_full_printing" ] grit_defines += [ "-D", "enable_full_printing" ]
} }
} }
......
...@@ -404,7 +404,7 @@ static_library("browser") { ...@@ -404,7 +404,7 @@ static_library("browser") {
".", "//chrome") ".", "//chrome")
} }
if (enable_printing != 0) { if (printing_mode != 0) {
# Some form of printing support. # Some form of printing support.
sources += rebase_path(gypi_values.chrome_browser_basic_printing_sources, sources += rebase_path(gypi_values.chrome_browser_basic_printing_sources,
".", "//chrome") ".", "//chrome")
...@@ -415,11 +415,11 @@ static_library("browser") { ...@@ -415,11 +415,11 @@ static_library("browser") {
sources += rebase_path(gypi_values.chrome_browser_printing_emf_sources, sources += rebase_path(gypi_values.chrome_browser_printing_emf_sources,
".", "//chrome") ".", "//chrome")
} }
if (enable_printing == 1) { if (printing_mode == 1) {
# Full printing on top of the above. # Full printing on top of the above.
sources += rebase_path(gypi_values.chrome_browser_full_printing_sources, sources += rebase_path(gypi_values.chrome_browser_full_printing_sources,
".", "//chrome") ".", "//chrome")
} else if (enable_printing == 2) { } else if (printing_mode == 2) {
# Partial-only printing support. # Partial-only printing support.
sources += rebase_path( sources += rebase_path(
gypi_values.chrome_browser_basic_only_printing_sources, gypi_values.chrome_browser_basic_only_printing_sources,
......
...@@ -126,7 +126,7 @@ static_library("ui") { ...@@ -126,7 +126,7 @@ static_library("ui") {
deps += [ "//net" ] deps += [ "//net" ]
} }
if (enable_printing != 0) { if (printing_mode != 0) {
deps += [ "//printing" ] deps += [ "//printing" ]
} }
...@@ -258,7 +258,7 @@ static_library("ui") { ...@@ -258,7 +258,7 @@ static_library("ui") {
if (!enable_themes) { if (!enable_themes) {
sources -= [ "webui/theme_source.cc" ] sources -= [ "webui/theme_source.cc" ]
} }
if (enable_printing == 1) { if (printing_mode == 1) {
sources += rebase_path(gypi_values.chrome_browser_ui_print_preview_sources, sources += rebase_path(gypi_values.chrome_browser_ui_print_preview_sources,
".", "//chrome") ".", "//chrome")
} }
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
{ {
'variables': { 'variables': {
# File lists shared with GN build.
'chrome_common_sources': [ 'chrome_common_sources': [
'../apps/app_shim/app_shim_launch.h', '../apps/app_shim/app_shim_launch.h',
'../apps/app_shim/app_shim_messages.h', '../apps/app_shim/app_shim_messages.h',
...@@ -125,30 +126,6 @@ ...@@ -125,30 +126,6 @@
'common/favicon/favicon_url_parser.h', 'common/favicon/favicon_url_parser.h',
'common/icon_with_badge_image_source.cc', 'common/icon_with_badge_image_source.cc',
'common/icon_with_badge_image_source.h', 'common/icon_with_badge_image_source.h',
'common/importer/firefox_importer_utils.cc',
'common/importer/firefox_importer_utils.h',
'common/importer/firefox_importer_utils_linux.cc',
'common/importer/firefox_importer_utils_mac.mm',
'common/importer/firefox_importer_utils_win.cc',
'common/importer/ie_importer_test_registry_overrider_win.cc',
'common/importer/ie_importer_test_registry_overrider_win.h',
'common/importer/ie_importer_utils_win.cc',
'common/importer/ie_importer_utils_win.h',
'common/importer/imported_bookmark_entry.cc',
'common/importer/imported_bookmark_entry.h',
'common/importer/imported_favicon_usage.cc',
'common/importer/imported_favicon_usage.h',
'common/importer/importer_bridge.cc',
'common/importer/importer_bridge.h',
'common/importer/importer_data_types.cc',
'common/importer/importer_data_types.h',
'common/importer/importer_type.h',
'common/importer/importer_url_row.cc',
'common/importer/importer_url_row.h',
'common/importer/profile_import_process_messages.cc',
'common/importer/profile_import_process_messages.h',
'common/importer/safari_importer_utils.h',
'common/importer/safari_importer_utils.mm',
'common/instant_restricted_id_cache.h', 'common/instant_restricted_id_cache.h',
'common/instant_types.cc', 'common/instant_types.cc',
'common/instant_types.h', 'common/instant_types.h',
...@@ -196,14 +173,6 @@ ...@@ -196,14 +173,6 @@
'common/search_types.h', 'common/search_types.h',
'common/search_urls.cc', 'common/search_urls.cc',
'common/search_urls.h', 'common/search_urls.h',
'common/service_messages.h',
'common/service_process_util.cc',
'common/service_process_util.h',
'common/service_process_util_linux.cc',
'common/service_process_util_mac.mm',
'common/service_process_util_posix.cc',
'common/service_process_util_posix.h',
'common/service_process_util_win.cc',
'common/spellcheck_common.cc', 'common/spellcheck_common.cc',
'common/spellcheck_common.h', 'common/spellcheck_common.h',
'common/spellcheck_marker.h', 'common/spellcheck_marker.h',
...@@ -265,6 +234,56 @@ ...@@ -265,6 +234,56 @@
'common/safe_browsing/zip_analyzer.cc', 'common/safe_browsing/zip_analyzer.cc',
'common/safe_browsing/zip_analyzer.h', 'common/safe_browsing/zip_analyzer.h',
], ],
'chrome_common_importer_sources': [
'common/importer/firefox_importer_utils.cc',
'common/importer/firefox_importer_utils.h',
'common/importer/firefox_importer_utils_linux.cc',
'common/importer/firefox_importer_utils_mac.mm',
'common/importer/firefox_importer_utils_win.cc',
'common/importer/ie_importer_test_registry_overrider_win.cc',
'common/importer/ie_importer_test_registry_overrider_win.h',
'common/importer/ie_importer_utils_win.cc',
'common/importer/ie_importer_utils_win.h',
'common/importer/imported_bookmark_entry.cc',
'common/importer/imported_bookmark_entry.h',
'common/importer/imported_favicon_usage.cc',
'common/importer/imported_favicon_usage.h',
'common/importer/importer_bridge.cc',
'common/importer/importer_bridge.h',
'common/importer/importer_data_types.cc',
'common/importer/importer_data_types.h',
'common/importer/importer_type.h',
'common/importer/importer_url_row.cc',
'common/importer/importer_url_row.h',
'common/importer/profile_import_process_messages.cc',
'common/importer/profile_import_process_messages.h',
'common/importer/safari_importer_utils.h',
'common/importer/safari_importer_utils.mm',
],
'chrome_common_service_process_sources': [
'common/service_messages.h',
'common/service_process_util.cc',
'common/service_process_util.h',
'common/service_process_util_linux.cc',
'common/service_process_util_mac.mm',
'common/service_process_util_posix.cc',
'common/service_process_util_posix.h',
'common/service_process_util_win.cc',
],
'chrome_common_win_mac_sources': [
'common/extensions/api/networking_private/networking_private_crypto_nss.cc',
'common/extensions/api/networking_private/networking_private_crypto_openssl.cc',
'common/extensions/api/networking_private/networking_private_crypto.h',
'common/media_galleries/itunes_library.cc',
'common/media_galleries/itunes_library.h',
'common/media_galleries/picasa_types.cc',
'common/media_galleries/picasa_types.h',
'common/media_galleries/pmp_constants.h',
],
'chrome_common_mac_sources': [
'common/media_galleries/iphoto_library.cc',
'common/media_galleries/iphoto_library.h',
]
}, },
'targets': [ 'targets': [
{ {
...@@ -327,31 +346,17 @@ ...@@ -327,31 +346,17 @@
], ],
'conditions': [ 'conditions': [
['enable_extensions==1', { ['enable_extensions==1', {
'sources': [ 'sources': [ '<@(chrome_common_extensions_sources)' ],
'<@(chrome_common_extensions_sources)',
],
'dependencies': [ 'dependencies': [
'../device/bluetooth/bluetooth.gyp:device_bluetooth', '../device/bluetooth/bluetooth.gyp:device_bluetooth',
'../device/usb/usb.gyp:device_usb', '../device/usb/usb.gyp:device_usb',
], ],
}], }],
['OS=="win" or OS=="mac"', { ['OS=="win" or OS=="mac"', {
'sources': [ 'sources': [ '<@(chrome_common_win_mac_sources)' ],
'common/extensions/api/networking_private/networking_private_crypto_nss.cc',
'common/extensions/api/networking_private/networking_private_crypto_openssl.cc',
'common/extensions/api/networking_private/networking_private_crypto.h',
'common/media_galleries/itunes_library.cc',
'common/media_galleries/itunes_library.h',
'common/media_galleries/picasa_types.cc',
'common/media_galleries/picasa_types.h',
'common/media_galleries/pmp_constants.h',
],
}], }],
['OS=="mac"', { ['OS=="mac"', {
'sources': [ 'sources': [ '<@(chrome_common_mac_sources)' ],
'common/media_galleries/iphoto_library.cc',
'common/media_galleries/iphoto_library.h',
],
}], }],
['OS != "ios"', { ['OS != "ios"', {
'dependencies': [ 'dependencies': [
...@@ -422,13 +427,8 @@ ...@@ -422,13 +427,8 @@
'<(DEPTH)/printing/printing.gyp:printing', '<(DEPTH)/printing/printing.gyp:printing',
], ],
}], }],
['enable_printing!=1', { ['enable_printing==1', {
'sources!' : [ 'sources': [ '<@(chrome_common_service_process_sources)' ],
'common/service_messages.h',
],
'sources/': [
['exclude', '^common/service_process_util_'],
],
}], }],
['enable_service_discovery==1', { ['enable_service_discovery==1', {
'sources' : [ 'sources' : [
...@@ -443,11 +443,6 @@ ...@@ -443,11 +443,6 @@
] ]
}], }],
['OS=="android"', { ['OS=="android"', {
'sources/': [
['exclude', '^common/importer/'],
['exclude', '^common/media_galleries/'],
['exclude', '^common/service_'],
],
'sources!': [ 'sources!': [
'common/badge_util.cc', 'common/badge_util.cc',
'common/chrome_version_info_posix.cc', 'common/chrome_version_info_posix.cc',
...@@ -456,9 +451,13 @@ ...@@ -456,9 +451,13 @@
'common/extensions/api/spellcheck/spellcheck_handler.cc', 'common/extensions/api/spellcheck/spellcheck_handler.cc',
'common/extensions/manifest_handlers/minimum_chrome_version_checker.cc', 'common/extensions/manifest_handlers/minimum_chrome_version_checker.cc',
'common/icon_with_badge_image_source.cc', 'common/icon_with_badge_image_source.cc',
'common/media_galleries/metadata_types.h',
'common/net/url_util.cc', 'common/net/url_util.cc',
'common/spellcheck_common.cc', 'common/spellcheck_common.cc',
], ],
}, {
# Non-Android.
'sources': [ '<@(chrome_common_importer_sources)' ]
}], }],
['OS=="win"', { ['OS=="win"', {
'include_dirs': [ 'include_dirs': [
...@@ -494,11 +493,6 @@ ...@@ -494,11 +493,6 @@
'../remoting/remoting.gyp:remoting_client_plugin', '../remoting/remoting.gyp:remoting_client_plugin',
], ],
}], }],
['enable_plugins==0', {
'source!' : [
'common/pepper_permission_util.cc',
],
}],
['enable_webrtc==0', { ['enable_webrtc==0', {
'sources!': [ 'sources!': [
'common/media/webrtc_logging_messages.h', 'common/media/webrtc_logging_messages.h',
...@@ -542,6 +536,7 @@ ...@@ -542,6 +536,7 @@
], ],
}, },
{ {
# GN version: //chrome/common:version
'target_name': 'common_version', 'target_name': 'common_version',
'type': 'none', 'type': 'none',
'conditions': [ 'conditions': [
...@@ -601,7 +596,7 @@ ...@@ -601,7 +596,7 @@
], ],
}, },
{ {
# GN version: //chrome/common/net:net # GN version: //chrome/common/net
'target_name': 'common_net', 'target_name': 'common_net',
'type': 'static_library', 'type': 'static_library',
'sources': [ 'sources': [
......
...@@ -42,6 +42,7 @@ static_library("common") { ...@@ -42,6 +42,7 @@ static_library("common") {
"//chrome/common/net", "//chrome/common/net",
"//chrome/common/safe_browsing:proto", "//chrome/common/safe_browsing:proto",
"//components/cloud_devices/common", "//components/cloud_devices/common",
"//components/json_schema",
"//components/metrics", "//components/metrics",
"//components/policy:policy_component_common", "//components/policy:policy_component_common",
"//components/translate/core/common", "//components/translate/core/common",
...@@ -59,30 +60,63 @@ static_library("common") { ...@@ -59,30 +60,63 @@ static_library("common") {
"//ui/resources:resources", "//ui/resources:resources",
"//url", "//url",
#":installer_util", TODO(GYP) #":installer_util", TODO(GYP)
#"//components/json_schema", TODO(GYP)
#"//media/cast/cast.gyp:cast_transport", TODO(GYP) #"//media/cast/cast.gyp:cast_transport", TODO(GYP)
] ]
if (!is_ios) { if (is_ios) {
sources += [
# Use this Mac file that was filtered out.
"chrome_version_info_mac.mm",
]
} else {
# Non-iOS.
deps += [ deps += [
"//chrome/common/extensions/api", "//chrome/common/extensions/api",
"//components/visitedlink/common", "//components/visitedlink/common",
"//components/autofill/content/common", "//components/autofill/content/common",
"//components/autofill/core/common", "//components/autofill/core/common",
"//components/password_manager/core/common",
"//components/signin/core/common",
"//components/translate/content/common", "//components/translate/content/common",
"//extensions/common/api", "//extensions/common/api",
"//ipc", "//ipc",
"//third_party/adobe/flash:flapper_version_h", "//third_party/adobe/flash:flapper_version_h",
"//third_party/re2", "//third_party/re2",
"//third_party/widevine/cdm:version_h", "//third_party/widevine/cdm:version_h",
#'<(DEPTH)/components/components.gyp:password_manager_core_common', TODO(GYP)
#'<(DEPTH)/components/components.gyp:signin_core_common', TODO(GYP)
#'<(DEPTH)/components/nacl.gyp:nacl_common', TODO(GYP)
#'<(DEPTH)/extensions/common/api/api.gyp:extensions_api', TODO(GYP)
#'<(DEPTH)/extensions/extensions.gyp:extensions_common', TODO(GYP) #'<(DEPTH)/extensions/extensions.gyp:extensions_common', TODO(GYP)
] ]
} }
if (enable_extensions) {
sources += rebase_path(
gypi_values.chrome_common_extensions_sources,
".", "//chrome")
deps += [
"//device/bluetooth",
"//device/usb",
]
}
if (is_win || is_mac) {
sources += rebase_path(
gypi_values.chrome_common_win_mac_sources,
".", "//chrome")
if (use_openssl) {
sources -= [
"extensions/api/networking_private/networking_private_crypto_nss.cc",
]
} else {
sources -= [
"extensions/api/networking_private/networking_private_crypto_openssl.cc",
]
}
}
if (is_mac) {
sources += rebase_path(
gypi_values.chrome_common_mac_sources,
".", "//chrome")
}
if (enable_nacl) { if (enable_nacl) {
deps += [ deps += [
#'<(DEPTH)/components/nacl.gyp:nacl_common', TODO(GYP) #'<(DEPTH)/components/nacl.gyp:nacl_common', TODO(GYP)
...@@ -93,6 +127,91 @@ static_library("common") { ...@@ -93,6 +127,91 @@ static_library("common") {
] ]
} }
# Printing.
if (printing_mode == 0) {
sources -= [
"print_messages.cc",
"print_messages.h",
]
} else {
deps += [ "//printing" ]
if (printing_mode == 1) {
# Full printing support.
sources += rebase_path(
gypi_values.chrome_common_service_process_sources,
".", "//chrome")
}
}
if (enable_service_discovery) {
sources += [
"local_discovery/service_discovery_client.cc",
"local_discovery/service_discovery_client.h",
]
}
if (enable_mdns) {
sources += [
"local_discovery/service_discovery_client_impl.cc",
"local_discovery/service_discovery_client_impl.h",
]
}
if (is_android) {
sources -= [
"badge_util.cc",
"chrome_version_info_posix.cc",
"extensions/api/extension_action/browser_action_handler.cc",
"extensions/api/extension_action/page_action_handler.cc",
"extensions/api/spellcheck/spellcheck_handler.cc",
"extensions/manifest_handlers/minimum_chrome_version_checker.cc",
"icon_with_badge_image_source.cc",
"media_galleries/metadata_types.h",
"net/url_util.cc",
"spellcheck_common.cc",
]
} else {
# Non-Android.
sources += rebase_path(
gypi_values.chrome_common_importer_sources,
".", "//chrome")
}
if (is_win) {
deps += [ "//third_party/wtl" ]
}
if (enable_mdns) {
sources += [ "local_discovery/local_discovery_messages.h" ]
}
if (is_chromeos) {
sources -= [ "chrome_version_info_linux.cc" ]
}
if (is_mac) {
sources -= [
"child_process_logging_posix.cc",
"chrome_version_info_posix.cc",
]
deps += [
"//third_party/mach_override",
#'../third_party/google_toolbox_for_mac/google_toolbox_for_mac.gyp:google_toolbox_for_mac', TODO(GYP)
]
}
if (enable_remoting) {
#deps += [ '../remoting/remoting.gyp:remoting_client_plugin' ] TODO(GYP)
}
if (!enable_plugins) {
sources -= [ "pepper_permission_util.cc" ]
}
if (!enable_webrtc) {
sources -= [ "media/webrtc_logging_messages.h" ]
}
if (enable_configuration_policy) {
deps += [ "//components/policy" ]
}
if (safe_browsing_mode == 1) { if (safe_browsing_mode == 1) {
defines += [ "FULL_SAFE_BROWSING" ] defines += [ "FULL_SAFE_BROWSING" ]
sources += rebase_path( sources += rebase_path(
...@@ -173,8 +292,8 @@ static_library("constants") { ...@@ -173,8 +292,8 @@ static_library("constants") {
deps = [ deps = [
"//base", "//base",
"//base/third_party/dynamic_annotations", "//base/third_party/dynamic_annotations",
"//components/bookmarks/common",
"//third_party/widevine/cdm:version_h", "//third_party/widevine/cdm:version_h",
#'../components/components.gyp:bookmarks_common', TODO(GYP)
] ]
if (enable_nacl) { if (enable_nacl) {
......
...@@ -30,10 +30,13 @@ static_library("renderer") { ...@@ -30,10 +30,13 @@ static_library("renderer") {
"//chrome:strings", "//chrome:strings",
"//components/autofill/content/renderer", "//components/autofill/content/renderer",
"//components/data_reduction_proxy/common", "//components/data_reduction_proxy/common",
"//components/plugins/renderer",
"//components/startup_metric_utils",
"//components/translate/core/common", "//components/translate/core/common",
"//components/translate/core/language_detection", "//components/translate/core/language_detection",
"//components/visitedlink/renderer", "//components/visitedlink/renderer",
"//content/public/renderer", "//content/public/renderer",
"//extensions:extensions_resources",
"//media/cast/logging/proto", "//media/cast/logging/proto",
"//third_party/re2", "//third_party/re2",
"//net", "//net",
...@@ -48,10 +51,7 @@ static_library("renderer") { ...@@ -48,10 +51,7 @@ static_library("renderer") {
"//webkit/common", "//webkit/common",
"//webkit:resources", "//webkit:resources",
#"../components/components.gyp:cdm_renderer", TODO(GYP) #"../components/components.gyp:cdm_renderer", TODO(GYP)
#"../components/components.gyp:startup_metric_utils", TODO(GYP)
#"../components/components.gyp:plugins_renderer", TODO(GYP)
#"../extensions/extensions.gyp:extensions_renderer", TODO(GYP) #"../extensions/extensions.gyp:extensions_renderer", TODO(GYP)
#"../extensions/extensions_resources.gyp:extensions_resources", TODO(GYP)
#"../media/cast/cast.gyp:cast_sender", TODO(GYP) #"../media/cast/cast.gyp:cast_sender", TODO(GYP)
#"../media/cast/cast.gyp:cast_transport", TODO(GYP) #"../media/cast/cast.gyp:cast_transport", TODO(GYP)
] ]
...@@ -108,17 +108,12 @@ static_library("renderer") { ...@@ -108,17 +108,12 @@ static_library("renderer") {
if (enable_spellcheck) { if (enable_spellcheck) {
sources += rebase_path(gypi_values.chrome_renderer_spellchecker_sources, sources += rebase_path(gypi_values.chrome_renderer_spellchecker_sources,
".", "..") ".", "..")
# TODO(GYP) When hunspell is done, the extra defines can be removed. deps += [ "//third_party/hunspell" ]
#deps += [ "//third_party/hunspell" ]
defines += [ "HUNSPELL_STATIC", "HUNSPELL_CHROME_CLIENT", "OPENOFFICEORG" ]
} }
if (enable_printing > 0) { if (printing_mode > 0) {
deps += [ deps += [ "//printing" ]
#"//printing", TODO(GYP) if (printing_mode == 1) {
]
if (enable_printing == 1) {
sources += rebase_path(gypi_values.chrome_renderer_printing_sources, sources += rebase_path(gypi_values.chrome_renderer_printing_sources,
".", "..") ".", "..")
} }
......
...@@ -77,7 +77,7 @@ static_library("utility") { ...@@ -77,7 +77,7 @@ static_library("utility") {
} }
} }
if (enable_printing != 1) { if (printing_mode != 1) {
sources -= [ sources -= [
"printing_handler.cc", "printing_handler.cc",
"printing_handler.h", "printing_handler.h",
......
...@@ -134,7 +134,7 @@ source_set("browser") { ...@@ -134,7 +134,7 @@ source_set("browser") {
sources += [ "gamepad/gamepad_platform_data_fetcher.cc" ] sources += [ "gamepad/gamepad_platform_data_fetcher.cc" ]
} }
if (enable_printing != 0) { if (printing_mode != 0) {
deps += [ "//printing" ] deps += [ "//printing" ]
} }
......
...@@ -9,7 +9,7 @@ if (cpu_arch == "arm") { ...@@ -9,7 +9,7 @@ if (cpu_arch == "arm") {
} }
skia_support_gpu = !is_ios skia_support_gpu = !is_ios
skia_support_pdf = !is_ios && enable_printing != 0 skia_support_pdf = !is_ios && printing_mode != 0
# The list of Skia defines that are to be set for chromium. # The list of Skia defines that are to be set for chromium.
gypi_skia_defines = exec_script( gypi_skia_defines = exec_script(
...@@ -248,14 +248,6 @@ component("skia") { ...@@ -248,14 +248,6 @@ component("skia") {
"ext/benchmarking_canvas.cc", "ext/benchmarking_canvas.cc",
"ext/benchmarking_canvas.h", "ext/benchmarking_canvas.h",
"ext/bitmap_platform_device.h", "ext/bitmap_platform_device.h",
"ext/bitmap_platform_device_cairo.cc",
"ext/bitmap_platform_device_cairo.h",
"ext/bitmap_platform_device_mac.cc",
"ext/bitmap_platform_device_mac.h",
#"ext/bitmap_platform_device_skia.cc",
#"ext/bitmap_platform_device_skia.h",
"ext/bitmap_platform_device_win.cc",
"ext/bitmap_platform_device_win.h",
"ext/convolver.cc", "ext/convolver.cc",
"ext/convolver.h", "ext/convolver.h",
"ext/event_tracer_impl.cc", "ext/event_tracer_impl.cc",
...@@ -415,7 +407,7 @@ component("skia") { ...@@ -415,7 +407,7 @@ component("skia") {
if (is_win) { if (is_win) {
sources -= [ "ext/SkThread_chrome.cc" ] sources -= [ "ext/SkThread_chrome.cc" ]
} }
if (is_android && enable_printing == 0) { if (is_android && printing_mode == 0) {
sources -= [ sources -= [
"ext/skia_utils_base.cc", "ext/skia_utils_base.cc",
"ext/vector_platform_device_skia.cc" "ext/vector_platform_device_skia.cc"
...@@ -469,11 +461,27 @@ component("skia") { ...@@ -469,11 +461,27 @@ component("skia") {
] ]
} }
if (!use_cairo) { # Select the right BitmapPlatformDevice.
sources -= [ if (is_win) {
sources += [
"ext/bitmap_platform_device_win.cc",
"ext/bitmap_platform_device_win.h",
]
} else if (is_mac) {
sources += [
"ext/bitmap_platform_device_mac.cc",
"ext/bitmap_platform_device_mac.h",
]
} else if (use_cairo) {
sources += [
"ext/bitmap_platform_device_cairo.cc", "ext/bitmap_platform_device_cairo.cc",
"ext/bitmap_platform_device_cairo.h", "ext/bitmap_platform_device_cairo.h",
] ]
} else {
sources += [
"ext/bitmap_platform_device_skia.cc",
"ext/bitmap_platform_device_skia.h",
]
} }
if (is_clang) { if (is_clang) {
......
...@@ -21,6 +21,7 @@ ...@@ -21,6 +21,7 @@
}, },
'sources': [ 'sources': [
# Note: file list duplicated in GN build.
'ext/analysis_canvas.cc', 'ext/analysis_canvas.cc',
'ext/analysis_canvas.h', 'ext/analysis_canvas.h',
'ext/benchmarking_canvas.cc', 'ext/benchmarking_canvas.cc',
......
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