[GCM] Add heartbeat manager and reconnection logic due to heartbeat failure
[chromium-blink-merge.git] / google_apis / gcm / gcm.gyp
blob79ecd0e6906846929d4a1cce1faa1e28d7cef188
1 # Copyright 2013 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.
6   'variables': {
7     'chromium_code': 1,
8   },
10   'targets': [
11     # The public GCM target.
12     {
13       'target_name': 'gcm',
14       'type': '<(component)',
15       'variables': {
16         'enable_wexit_time_destructors': 1,
17         'proto_in_dir': './protocol',
18         'proto_out_dir': 'google_apis/gcm/protocol',
19         'cc_generator_options': 'dllexport_decl=GCM_EXPORT:',
20         'cc_include': 'google_apis/gcm/base/gcm_export.h',
21       },
22       'include_dirs': [
23         '../..',
24       ],
25       'defines': [
26         'GCM_IMPLEMENTATION',
27       ],
28       'export_dependent_settings': [
29         '../../third_party/protobuf/protobuf.gyp:protobuf_lite'
30       ],
31       'dependencies': [
32         '../../base/base.gyp:base',
33         '../../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
34         '../../components/components.gyp:encryptor',
35         '../../net/net.gyp:net',
36         '../../third_party/leveldatabase/leveldatabase.gyp:leveldatabase',
37         '../../third_party/protobuf/protobuf.gyp:protobuf_lite',
38         '../../url/url.gyp:url_lib',
39       ],
40       'sources': [
41         'base/mcs_message.h',
42         'base/mcs_message.cc',
43         'base/mcs_util.h',
44         'base/mcs_util.cc',
45         'base/socket_stream.h',
46         'base/socket_stream.cc',
47         'engine/connection_factory.h',
48         'engine/connection_factory.cc',
49         'engine/connection_factory_impl.h',
50         'engine/connection_factory_impl.cc',
51         'engine/connection_handler.h',
52         'engine/connection_handler.cc',
53         'engine/connection_handler_impl.h',
54         'engine/connection_handler_impl.cc',
55         'engine/heartbeat_manager.h',
56         'engine/heartbeat_manager.cc',
57         'engine/mcs_client.h',
58         'engine/mcs_client.cc',
59         'engine/rmq_store.h',
60         'engine/rmq_store.cc',
61         'gcm_client.cc',
62         'gcm_client.h',
63         'gcm_client_impl.cc',
64         'gcm_client_impl.h',
65         'protocol/mcs.proto',
66       ],
67       'includes': [
68         '../../build/protoc.gypi'
69       ],
70     },
72     # A standalone MCS (mobile connection server) client.
73     {
74       'target_name': 'mcs_probe',
75       'type': 'executable',
76       'variables': { 'enable_wexit_time_destructors': 1, },
77       'include_dirs': [
78         '../..',
79       ],
80       'dependencies': [
81         '../../base/base.gyp:base',
82         '../../net/net.gyp:net',
83         '../../net/net.gyp:net_test_support',
84         '../../third_party/protobuf/protobuf.gyp:protobuf_lite',
85         'gcm'
86       ],
87       'sources': [
88         'tools/mcs_probe.cc',
89       ],
90     },
92     # The main GCM unit tests.
93     {
94       'target_name': 'gcm_unit_tests',
95       'type': '<(gtest_target_type)',
96       'variables': { 'enable_wexit_time_destructors': 1, },
97       'include_dirs': [
98         '../..',
99       ],
100       'export_dependent_settings': [
101         '../../third_party/protobuf/protobuf.gyp:protobuf_lite'
102       ],
103       'dependencies': [
104         '../../base/base.gyp:run_all_unittests',
105         '../../base/base.gyp:base',
106         '../../components/components.gyp:encryptor',
107         '../../net/net.gyp:net',
108         '../../net/net.gyp:net_test_support',
109         '../../testing/gtest.gyp:gtest',
110         '../../third_party/protobuf/protobuf.gyp:protobuf_lite',
111         'gcm'
112       ],
113       'sources': [
114         'base/mcs_message_unittest.cc',
115         'base/mcs_util_unittest.cc',
116         'base/socket_stream_unittest.cc',
117         'engine/connection_factory_impl_unittest.cc',
118         'engine/connection_handler_impl_unittest.cc',
119         'engine/fake_connection_factory.h',
120         'engine/fake_connection_factory.cc',
121         'engine/fake_connection_handler.h',
122         'engine/fake_connection_handler.cc',
123         'engine/heartbeat_manager_unittest.cc',
124         'engine/mcs_client_unittest.cc',
125         'engine/rmq_store_unittest.cc',
126       ]
127     },
128   ],