Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(789)

Side by Side Diff: components/cronet/ios/BUILD.gn

Issue 1934083002: [Cronet] Use gn desc deps to find third_party licenses. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix build from gyp project. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « components/cronet.gypi ('k') | components/cronet/ios/cronet_environment.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
4
5 import("//build/buildflag_header.gni")
6 import("//build/util/version.gni")
7 import("//chrome/version.gni")
8 import("//testing/test.gni")
9 import("//url/features.gni")
10
11 assert(!is_component_build, "Cronet requires static library build.")
12
13 declare_args() {
14 cronet_enable_data_reduction_proxy_support = false
15 }
16
17 process_version("cronet_version_header") {
18 template_file = "//components/cronet/version.h.in"
19 output = "$target_gen_dir/version.h"
20 extra_args = [
21 "-e",
22 "VERSION_FULL=\"%s.%s.%s.%s\" % (MAJOR,MINOR,BUILD,PATCH)",
23 ]
24 }
25
26 source_set("cronet_sources") {
27 deps = [
28 ":cronet_version_header",
29 "//base:base",
30 "//components/metrics:metrics",
31 "//components/metrics/proto:proto",
32 "//components/prefs:prefs",
33 "//net",
34 "//url",
35 ]
36
37 sources = [
38 "../histogram_manager.cc",
39 "../histogram_manager.h",
40 "../url_request_context_config.cc",
41 "../url_request_context_config.h",
42 "Cronet.h",
43 "Cronet.mm",
44 "cronet_bidirectional_stream.cc",
45 "cronet_bidirectional_stream.h",
46 "cronet_c_for_grpc.cc",
47 "cronet_c_for_grpc.h",
48 "cronet_environment.cc",
49 "cronet_environment.h",
50 ]
51
52 if (!use_platform_icu_alternatives) {
53 deps += [ "//base:i18n" ]
54 }
55 }
56
57 shared_library("cronet_shared") {
58 deps = [
59 ":cronet_sources",
60 "//base",
61 "//net:net",
62 ]
63 libs = [ "UIKit.Framework" ]
64 }
65
66 bundle_data("cronet_test_bundle_data") {
67 testonly = true
68 sources = [
69 "//net/data/ssl/certificates/quic_test.example.com.crt",
70 "//net/data/ssl/certificates/quic_test.example.com.key",
71 "//net/data/ssl/certificates/quic_test.example.com.key.pkcs8",
72 "//net/data/ssl/certificates/quic_test.example.com.key.sct",
73 ]
74 outputs = [
75 "{{bundle_resources_dir}}/{{source_file_part}}",
76 ]
77 }
78
79 test("cronet_test") {
80 testonly = true
81 sources = [
82 "test/cronet_bidirectional_stream_test.mm",
83 "test/cronet_test_runner.mm",
84 "test/quic_test_server.cc",
85 "test/quic_test_server.h",
86 ]
87
88 deps = [
89 ":cronet_sources",
90 ":cronet_test_bundle_data",
91 ":cronet_version_header",
92 "//base",
93 "//base:i18n",
94 "//net",
95 "//net:simple_quic_tools",
96 "//net:test_support",
97 "//third_party/icu",
98 ]
99 }
100
101 test("cronet_unittests") {
102 sources = [
103 "//components/cronet/histogram_manager_unittest.cc",
104 "//components/cronet/run_all_unittests.cc",
105 "//components/cronet/url_request_context_config_unittest.cc",
106 ]
107
108 deps = [
109 ":cronet_sources",
110 "//base",
111 "//base/test:test_support",
112 "//components/metrics",
113 "//net",
114 "//testing/gtest",
115 ]
116 }
117
118 _package_dir = "$root_out_dir/cronet"
119
120 action("generate_license") {
121 _license_path = "$_package_dir/LICENSE"
122
123 script = "//components/cronet/tools/cronet_licenses.py"
124 outputs = [
125 _license_path,
126 ]
127 args = [
128 "license",
129 rebase_path(_license_path, root_build_dir),
130 "--gn",
131 ]
132 }
133
134 copy("cronet_package_copy") {
135 sources = [
136 "$root_out_dir/libcronet_shared.dylib",
137 "//AUTHORS",
138 "//chrome/VERSION",
139 "//components/cronet/ios/Cronet.h",
140 "//components/cronet/ios/cronet_c_for_grpc.h",
141 ]
142 outputs = [
143 "$_package_dir/{{source_file_part}}",
144 ]
145
146 deps = [
147 ":cronet_shared",
148 ]
149 }
150
151 group("cronet_package") {
152 deps = [
153 ":cronet_package_copy",
154 ":generate_license",
155 ]
156 }
OLDNEW
« no previous file with comments | « components/cronet.gypi ('k') | components/cronet/ios/cronet_environment.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698