1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
|
# 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/buildflag_header.gni")
import("//build/config/chromecast_build.gni")
import("//build/config/features.gni")
import("//content/common/common.gni")
import("//mojo/public/tools/bindings/mojom.gni")
import("//third_party/webrtc/build/webrtc.gni")
# See //content/BUILD.gn for how this works.
group("common") {
if (is_component_build) {
public_deps = [
"//content",
]
} else {
public_deps = [
":common_sources",
]
}
}
# This target allows other targets to depend on result_codes.h which is a
# header-only dependency, without bringing in all of content.
source_set("result_codes") {
sources = [
"result_codes.h",
]
}
# This target allows other targets to depend on content_descriptors.h which is
# a header-only dependency, without bringing in all of content.
source_set("content_descriptors") {
sources = [
"content_descriptors.h",
]
# The header uses V8_USE_EXTERNAL_STARTUP_DATA.
public_configs = [ "//v8:external_startup_data" ]
deps = [
"//ipc",
]
}
# Forces static linking for targets using the static_switches constants, even
# in the component build. This config makes it impossible to use the static
# switches target and use the rest of content at the same time, because the
# component export flags won't be consistent.
config("static_switches_defines") {
defines = [ "COMPILE_CONTENT_STATICALLY" ]
}
# Set in GN builds, triggering behavior in content when run from an external
# Mojo shell.
config("mojo_shell_client") {
# This configuration has only been tested on these platforms.
if ((is_win || is_linux || is_chromeos) && !is_chromecast) {
defines = [ "MOJO_SHELL_CLIENT" ]
}
}
# This target allows you to use the content_switches constants and statically
# link to it, without depending on the rest of content. This is only for use
# without content, or you will get multiply defined symbols.
source_set("static_switches") {
public = [
"content_switches.h",
]
sources = [
"//content/common/content_export.h",
"content_switches.cc",
]
public_configs = [ ":static_switches_defines" ]
}
source_set("common_sources") {
visibility = [ "//content/*" ]
sources = rebase_path(content_common_gypi_values.public_common_sources,
".",
"//content")
configs += [
"//build/config:precompiled_headers",
"//content:content_implementation",
]
public_configs = [ "//v8:external_startup_data" ]
public_deps = [
"//content/common",
"//mojo/public/cpp/bindings",
"//url/ipc:url_ipc",
]
deps = [
"//ipc",
"//ipc/mojo",
"//media",
"//mojo/common",
"//net",
"//ppapi/c",
"//skia",
"//storage/common",
"//third_party/WebKit/public:blink_headers",
"//third_party/icu",
"//ui/accessibility",
"//ui/base",
"//ui/gfx",
"//ui/gfx/ipc",
"//ui/surface",
]
# //content/common needs to include public headers.
allow_circular_includes_from = [ "//content/common" ]
if (!enable_plugins) {
sources -= [
"pepper_plugin_info.cc",
"pepper_plugin_info.h",
]
}
if (enable_webrtc) {
sources += [
"webrtc_ip_handling_policy.cc",
"webrtc_ip_handling_policy.h",
]
}
}
mojom("mojo_bindings") {
sources = [
"background_sync.mojom",
"mojo_geoposition.mojom",
"permission_status.mojom",
"service_worker_event_status.mojom",
]
}
buildflag_header("features") {
header = "features.h"
flags = [ "RTC_USE_H264=$rtc_use_h264" ]
}
source_set("feature_h264_with_openh264_ffmpeg") {
deps = [
":features",
"//base",
]
sources = [
"feature_h264_with_openh264_ffmpeg.cc",
"feature_h264_with_openh264_ffmpeg.h",
]
}
|