blob: 07edb34d935bf4dfc2833f2fe15610e6b481eb92 [file] [log] [blame]
jame76324e2015-10-03 06:01:28 +09001# 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{
6 'includes': [
7 '../third_party/mojo/mojo_variables.gypi',
8 ],
9 'target_defaults' : {
10 'include_dirs': [
11 '..',
jame76324e2015-10-03 06:01:28 +090012 ],
13 'direct_dependent_settings': {
14 'include_dirs': [
15 '..',
16 ],
17 },
18 },
19 'targets': [
20 {
21 # GN version: //mojo/edk/system
22 'target_name': 'mojo_system_impl2',
23 'type': 'static_library',
24 # TODO(use_chrome_edk): this should be a component to match third_party,
25 # but since third_party includes it, we either make it a static library
26 # or we have to change the export macros to be different than third_party.
27 #'type': '<(component)',
28 'dependencies': [
29 '../base/base.gyp:base',
30 '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
31 ],
32 'defines': [
33 'MOJO_SYSTEM_IMPL_IMPLEMENTATION',
34 'MOJO_SYSTEM_IMPLEMENTATION',
35 'MOJO_USE_SYSTEM_IMPL',
36 ],
37 'sources': [
38 'edk/embedder/configuration.h',
jame76324e2015-10-03 06:01:28 +090039 'edk/embedder/embedder.cc',
40 'edk/embedder/embedder.h',
41 'edk/embedder/embedder_internal.h',
42 'edk/embedder/entrypoints.cc',
43 'edk/embedder/platform_channel_pair.cc',
44 'edk/embedder/platform_channel_pair.h',
45 'edk/embedder/platform_channel_pair_posix.cc',
46 'edk/embedder/platform_channel_pair_win.cc',
47 'edk/embedder/platform_channel_utils_posix.cc',
48 'edk/embedder/platform_channel_utils_posix.h',
49 'edk/embedder/platform_handle.cc',
50 'edk/embedder/platform_handle.h',
51 'edk/embedder/platform_handle_utils.h',
52 'edk/embedder/platform_handle_utils_posix.cc',
53 'edk/embedder/platform_handle_utils_win.cc',
54 'edk/embedder/platform_handle_vector.h',
55 'edk/embedder/platform_shared_buffer.h',
56 'edk/embedder/platform_support.h',
57 'edk/embedder/scoped_platform_handle.h',
58 'edk/embedder/simple_platform_shared_buffer.cc',
59 'edk/embedder/simple_platform_shared_buffer.h',
60 'edk/embedder/simple_platform_shared_buffer_android.cc',
61 'edk/embedder/simple_platform_shared_buffer_posix.cc',
62 'edk/embedder/simple_platform_shared_buffer_win.cc',
63 'edk/embedder/simple_platform_support.cc',
64 'edk/embedder/simple_platform_support.h',
65 'edk/system/awakable.h',
66 'edk/system/awakable_list.cc',
67 'edk/system/awakable_list.h',
68 'edk/system/async_waiter.cc',
69 'edk/system/async_waiter.h',
jam6de73f32015-11-26 03:48:29 +090070 'edk/system/broker.h',
71 'edk/system/broker_messages.h',
72 'edk/system/broker_state.cc',
73 'edk/system/broker_state.h',
74 'edk/system/child_broker_host.cc',
75 'edk/system/child_broker_host.h',
jame76324e2015-10-03 06:01:28 +090076 'edk/system/configuration.cc',
77 'edk/system/configuration.h',
78 'edk/system/core.cc',
79 'edk/system/core.h',
80 'edk/system/data_pipe.cc',
81 'edk/system/data_pipe.h',
82 'edk/system/data_pipe_consumer_dispatcher.cc',
83 'edk/system/data_pipe_consumer_dispatcher.h',
84 'edk/system/data_pipe_producer_dispatcher.cc',
85 'edk/system/data_pipe_producer_dispatcher.h',
86 'edk/system/dispatcher.cc',
87 'edk/system/dispatcher.h',
88 'edk/system/handle_signals_state.h',
89 'edk/system/handle_table.cc',
90 'edk/system/handle_table.h',
91 'edk/system/mapping_table.cc',
92 'edk/system/mapping_table.h',
93 'edk/system/message_in_transit.cc',
94 'edk/system/message_in_transit.h',
95 'edk/system/message_in_transit_queue.cc',
96 'edk/system/message_in_transit_queue.h',
97 'edk/system/message_pipe_dispatcher.cc',
98 'edk/system/message_pipe_dispatcher.h',
99 'edk/system/options_validation.h',
jam6de73f32015-11-26 03:48:29 +0900100 'edk/system/child_broker.cc',
101 'edk/system/child_broker.h',
jame76324e2015-10-03 06:01:28 +0900102 'edk/system/platform_handle_dispatcher.cc',
103 'edk/system/platform_handle_dispatcher.h',
104 'edk/system/raw_channel.cc',
105 'edk/system/raw_channel.h',
106 'edk/system/raw_channel_posix.cc',
107 'edk/system/raw_channel_win.cc',
108 'edk/system/shared_buffer_dispatcher.cc',
109 'edk/system/shared_buffer_dispatcher.h',
110 'edk/system/simple_dispatcher.cc',
111 'edk/system/simple_dispatcher.h',
jame76324e2015-10-03 06:01:28 +0900112 'edk/system/transport_data.cc',
113 'edk/system/transport_data.h',
114 'edk/system/waiter.cc',
115 'edk/system/waiter.h',
116 # Test-only code:
117 # TODO(vtl): It's a little unfortunate that these end up in the same
118 # component as non-test-only code. In the static build, this code
119 # should hopefully be dead-stripped.
120 'edk/embedder/test_embedder.cc',
121 'edk/embedder/test_embedder.h',
122 ],
123 'all_dependent_settings': {
124 # Ensures that dependent projects import the core functions on Windows.
125 'defines': ['MOJO_USE_SYSTEM_IMPL'],
126 },
127 'conditions': [
128 ['OS=="android"', {
129 'dependencies': [
130 '../third_party/ashmem/ashmem.gyp:ashmem',
131 ],
132 }],
133 ['OS=="win"', {
134 # Structure was padded due to __declspec(align()), which is
135 # uninteresting.
136 'msvs_disabled_warnings': [ 4324 ],
137 }],
138 ],
139 },
140 {
141 # GN version: //mojo/edk/js
142 # TODO(use_chrome_edk): remove "2"
143 'target_name': 'mojo_js_lib2',
144 'type': 'static_library',
145 'dependencies': [
146 '../base/base.gyp:base',
147 '../gin/gin.gyp:gin',
148 '../v8/tools/gyp/v8.gyp:v8',
149 ],
150 'export_dependent_settings': [
151 '../base/base.gyp:base',
152 '../gin/gin.gyp:gin',
153 ],
154 'sources': [
155 # Sources list duplicated in GN build.
156 'edk/js/core.cc',
157 'edk/js/core.h',
158 'edk/js/drain_data.cc',
159 'edk/js/drain_data.h',
160 'edk/js/handle.cc',
161 'edk/js/handle.h',
162 'edk/js/handle_close_observer.h',
163 'edk/js/mojo_runner_delegate.cc',
164 'edk/js/mojo_runner_delegate.h',
165 'edk/js/support.cc',
166 'edk/js/support.h',
167 'edk/js/threading.cc',
168 'edk/js/threading.h',
169 'edk/js/waiting_callback.cc',
170 'edk/js/waiting_callback.h',
171 ],
172 },
173 {
174 # GN version: //mojo/edk/test:test_support_impl
175 # TODO(use_chrome_edk): remove "2"
176 'target_name': 'mojo_test_support_impl2',
177 'type': 'static_library',
178 'dependencies': [
179 '../base/base.gyp:base',
180 ],
181 'sources': [
182 'edk/test/test_support_impl.cc',
183 'edk/test/test_support_impl.h',
184 ],
185 },
186 {
187 # GN version: //mojo/edk/test:test_support
188 'target_name': 'mojo_common_test_support2',
189 'type': 'static_library',
190 'dependencies': [
191 '../base/base.gyp:base',
192 '../base/base.gyp:test_support_base',
193 '../testing/gtest.gyp:gtest',
194 'mojo_system_impl2',
195 ],
196 'sources': [
197 'edk/test/multiprocess_test_helper.cc',
198 'edk/test/multiprocess_test_helper.h',
199 'edk/test/scoped_ipc_support.cc',
200 'edk/test/scoped_ipc_support.h',
201 'edk/test/test_utils.h',
202 'edk/test/test_utils_posix.cc',
203 'edk/test/test_utils_win.cc',
204 ],
205 'conditions': [
206 ['OS=="ios"', {
207 'sources!': [
208 'edk/test/multiprocess_test_helper.cc',
209 ],
210 }],
211 ],
212 },
213 {
214 # GN version: //mojo/edk/test:run_all_unittests
215 # TODO(use_chrome_edk): remove "2"
216 'target_name': 'mojo_run_all_unittests2',
217 'type': 'static_library',
218 'dependencies': [
219 '../base/base.gyp:base',
220 '../base/base.gyp:test_support_base',
221 '../testing/gtest.gyp:gtest',
222 '../third_party/mojo/mojo_public.gyp:mojo_public_test_support',
223 'mojo_system_impl2',
224 'mojo_test_support_impl2',
225 ],
226 'sources': [
227 'edk/test/run_all_unittests.cc',
228 ],
229 },
230 ],
231}