-# Headless renderer is a convenience library for non component builds that
-# includes headless classes that depend on the renderer.
-if (!is_component_build) {
- static_library("headless_renderer") {
- defines = []
- sources = [
- "lib/browser/headless_web_contents_impl.cc",
- "lib/browser/headless_web_contents_impl.h",
- "lib/headless_content_main_delegate.cc",
- "lib/headless_content_main_delegate.h",
- "lib/renderer/headless_content_renderer_client.cc",
- "lib/renderer/headless_content_renderer_client.h",
- "lib/utility/headless_content_utility_client.cc",
- "lib/utility/headless_content_utility_client.h",
- ]
-
- if (is_mac) {
- sources += [ "lib/headless_content_main_delegate_mac.mm" ]
- }
-
- if (enable_basic_printing) {
- sources += [
- "lib/renderer/headless_print_render_frame_helper_delegate.cc",
- "lib/renderer/headless_print_render_frame_helper_delegate.h",
- ]
- }
-
- deps = [
- ":headless_shared_sources",
- "//build:chromeos_buildflags",
- "//components/crash/core/common",
- "//components/security_state/content",
- "//components/security_state/core",
- "//content/public/app",
- "//content/public/browser",
- "//content/public/common",
- "//content/public/renderer",
- "//content/public/utility",
- "//printing/buildflags",
- "//third_party/blink/public:blink_headers",
- "//ui/base",
- "//ui/compositor",
- "//v8",
- ]
- if (use_ozone) {
- deps += [ "//ui/ozone" ]
- }
- if (enable_basic_printing) {
- deps += [
- "//components/printing/renderer",
- "//components/services/print_compositor",
- "//components/services/print_compositor/public/mojom",
- ]
- }
- configs += [ ":headless_defines_config" ]
- if (headless_use_embedded_resources) {
- defines += [ "HEADLESS_USE_EMBEDDED_RESOURCES" ]
- deps += [ ":embed_resources" ]
- sources += [
- "$root_gen_dir/headless/embedded_resource_pak.cc",
- "$root_gen_dir/headless/embedded_resource_pak.h",
- ]
- }
-
- if (is_mac || is_win || is_linux || is_chromeos) {
- deps += [ "//components/crash/core/app" ]
- }
- }
-} else {
- # For component builds all dependencies are already included in the headless
- # component.
- group("headless_renderer") {
- deps = [ ":headless_non_renderer" ]
- }
-}
-