cygprofile: increase timeouts to allow showing web contents
[chromium-blink-merge.git] / mojo / services / network / BUILD.gn
blob4dec488069742a689016bd5d25e7fd35d432f43b
1 # Copyright 2014 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.
5 import("//mojo/public/mojo_application.gni")
7 if (is_android) {
8   import("//build/config/android/rules.gni")
10   java_library_path = "$target_out_dir/java_library.dex.jar"
12   mojo_android_application("network") {
13     output_name = "network_service"
14     input_so = "$root_shlib_dir/${shlib_prefix}network_service$shlib_extension"
15     input_dex_jar = java_library_path
16     deps = [
17       ":java_library",
18       ":native_library",
19     ]
20   }
22   shared_library("native_library") {
23     output_name = "network_service"
25     sources = [
26       "android_hooks.cc",
27     ]
29     deps = [
30       ":sources",
31       "//base",
32       "//build/config/sanitizers:deps",
33       "//net",
34     ]
35   }
37   android_standalone_library("java_library") {
38     dex_path = java_library_path
40     deps = [
41       "//net/android:net_java",
42     ]
43   }
44 } else {
45   mojo_native_application("network") {
46     output_name = "network_service"
48     deps = [
49       ":sources",
50     ]
51   }
54 source_set("lib") {
55   sources = [
56     "cookie_store_impl.cc",
57     "cookie_store_impl.h",
58     "http_connection_impl.cc",
59     "http_connection_impl.h",
60     "http_server_impl.cc",
61     "http_server_impl.h",
62     "mojo_persistent_cookie_store.cc",
63     "mojo_persistent_cookie_store.h",
64     "net_adapters.cc",
65     "net_adapters.h",
66     "net_address_type_converters.cc",
67     "net_address_type_converters.h",
68     "network_context.cc",
69     "network_context.h",
70     "network_service_delegate.cc",
71     "network_service_delegate.h",
72     "network_service_delegate_observer.h",
73     "network_service_impl.cc",
74     "network_service_impl.h",
75     "tcp_bound_socket_impl.cc",
76     "tcp_bound_socket_impl.h",
77     "tcp_connected_socket_impl.cc",
78     "tcp_connected_socket_impl.h",
79     "tcp_server_socket_impl.cc",
80     "tcp_server_socket_impl.h",
81     "udp_socket_impl.cc",
82     "udp_socket_impl.h",
83     "url_loader_factory_impl.cc",
84     "url_loader_factory_impl.h",
85     "url_loader_impl.cc",
86     "url_loader_impl.h",
87     "web_socket_factory_impl.cc",
88     "web_socket_factory_impl.h",
89     "web_socket_impl.cc",
90     "web_socket_impl.h",
91   ]
93   deps = [
94     "//base",
95     "//components/filesystem/public/interfaces",
96     "//mojo/application/public/cpp",
97     "//mojo/common:common_base",
98     "//mojo/common:url_type_converters",
99     "//mojo/message_pump",
100     "//mojo/services/network/public/cpp",
101     "//mojo/services/network/public/interfaces",
102     "//net",
103     "//net:extras",
104     "//net:http_server",
105     "//url",
106     "//sql/mojo",
107     "//third_party/mojo/src/mojo/public/cpp/system:system",
108   ]
111 source_set("sources") {
112   visibility = [ ":*" ]
114   sources = [
115     "main.cc",
116   ]
118   deps = [
119     ":lib",
120     "//base",
121     "//mojo/application/public/cpp",
122     "//mojo/services/network/public/cpp",
123     "//mojo/services/network/public/interfaces",
124     "//third_party/mojo/src/mojo/public/c/system:for_shared_library",
125     "//third_party/mojo/src/mojo/public/cpp/bindings:bindings",
126   ]
129 mojo_native_application("apptests") {
130   output_name = "network_service_apptests"
131   testonly = true
133   sources = [
134     "http_server_apptest.cc",
135     "udp_socket_apptest.cc",
136     "url_loader_impl_apptest.cc",
137   ]
139   deps = [
140     ":lib",
141     ":network",
142     "//base",
143     "//mojo/application/public/cpp:sources",
144     "//mojo/application/public/cpp:test_support",
145     "//mojo/common:common_base",
146     "//mojo/message_pump",
147     "//mojo/services/network/public/cpp",
148     "//mojo/services/network/public/interfaces",
149     "//net",
150     "//net:test_support",
151     "//testing/gtest",
152     "//third_party/mojo/src/mojo/public/cpp/bindings:callback",
153   ]