blob: 762c36958473a1e2b46cb8826854e458fd4f157e [file] [log] [blame]
Torne (Richard Coles)58218062012-11-14 11:43:16 +00001# Copyright (c) 2012 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 'variables': {
7 'chromium_code': 1, # Use higher warning level.
8 },
9 'includes': [
10 '../build/win_precompile.gypi',
11 ],
12 'targets': [
13 {
14 'target_name': 'google_apis',
15 'type': 'static_library',
Torne (Richard Coles)90dce4d2013-05-29 14:40:03 +010016 'includes': [
17 'determine_use_official_keys.gypi',
18 ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +000019 'dependencies': [
20 '../base/base.gyp:base',
21 '../crypto/crypto.gyp:crypto',
22 '../net/net.gyp:net',
23 ],
24 'conditions': [
25 ['google_api_key!=""', {
26 'defines': ['GOOGLE_API_KEY="<(google_api_key)"'],
27 }],
Torne (Richard Coles)58218062012-11-14 11:43:16 +000028 ['google_default_client_id!=""', {
29 'defines': [
Ben Murdoch7dbb3d52013-07-17 14:55:54 +010030 'GOOGLE_DEFAULT_CLIENT_ID="<(google_default_client_id)"',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000031 ]
32 }],
33 ['google_default_client_secret!=""', {
34 'defines': [
Ben Murdoch7dbb3d52013-07-17 14:55:54 +010035 'GOOGLE_DEFAULT_CLIENT_SECRET="<(google_default_client_secret)"',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000036 ]
37 }],
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +010038 [ 'OS == "android"', {
39 'dependencies': [
40 '../third_party/openssl/openssl.gyp:openssl',
41 ],
42 'sources/': [
43 ['exclude', 'cup/client_update_protocol_nss\.cc$'],
44 ],
45 }],
46 [ 'use_openssl==1', {
47 'sources!': [
48 'cup/client_update_protocol_nss.cc',
49 ],
50 }, {
51 'sources!': [
52 'cup/client_update_protocol_openssl.cc',
53 ],
54 },],
Torne (Richard Coles)58218062012-11-14 11:43:16 +000055 ],
56 'sources': [
Torne (Richard Coles)868fa2f2013-06-11 10:57:03 +010057 'cup/client_update_protocol.cc',
58 'cup/client_update_protocol.h',
59 'cup/client_update_protocol_nss.cc',
60 'cup/client_update_protocol_openssl.cc',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000061 'gaia/gaia_auth_consumer.cc',
62 'gaia/gaia_auth_consumer.h',
63 'gaia/gaia_auth_fetcher.cc',
64 'gaia/gaia_auth_fetcher.h',
65 'gaia/gaia_auth_util.cc',
66 'gaia/gaia_auth_util.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000067 'gaia/gaia_constants.cc',
68 'gaia/gaia_constants.h',
69 'gaia/gaia_oauth_client.cc',
70 'gaia/gaia_oauth_client.h',
71 'gaia/gaia_switches.cc',
72 'gaia/gaia_switches.h',
73 'gaia/gaia_urls.cc',
74 'gaia/gaia_urls.h',
75 'gaia/google_service_auth_error.cc',
76 'gaia/google_service_auth_error.h',
77 'gaia/oauth_request_signer.cc',
78 'gaia/oauth_request_signer.h',
79 'gaia/oauth2_access_token_consumer.h',
80 'gaia/oauth2_access_token_fetcher.cc',
81 'gaia/oauth2_access_token_fetcher.h',
82 'gaia/oauth2_api_call_flow.cc',
83 'gaia/oauth2_api_call_flow.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000084 'gaia/oauth2_mint_token_flow.cc',
85 'gaia/oauth2_mint_token_flow.h',
Torne (Richard Coles)424c4d72013-08-30 15:14:49 +010086 'gaia/oauth2_token_service.cc',
87 'gaia/oauth2_token_service.h',
Torne (Richard Coles)58218062012-11-14 11:43:16 +000088 'google_api_keys.cc',
89 'google_api_keys.h',
90 ],
Torne (Richard Coles)2a99a7e2013-03-28 15:31:22 +000091 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
92 'msvs_disabled_warnings': [4267, ],
Torne (Richard Coles)58218062012-11-14 11:43:16 +000093 },
Torne (Richard Coles)d0247b12013-09-19 22:36:51 +010094 {
95 'target_name': 'google_apis_unittests',
96 'type': 'executable',
97 'dependencies': [
98 '../base/base.gyp:run_all_unittests',
99 '../testing/gtest.gyp:gtest',
100 'google_apis',
101 ],
102 'include_dirs': [
103 '..',
104 ],
105 'sources': [
106 'google_api_keys_unittest.cc',
107 ],
108 },
109 {
110 'target_name': 'google_apis_test_support',
111 'type': 'static_library',
112 'dependencies': [
113 '../base/base.gyp:base',
114 '../base/base.gyp:test_support_base',
115 '../net/net.gyp:net',
116 '../net/net.gyp:net_test_support',
117 ],
118 'export_dependent_settings': [
119 '../base/base.gyp:base',
120 '../base/base.gyp:test_support_base',
121 '../net/net.gyp:net',
122 '../net/net.gyp:net_test_support',
123 ],
124 'sources': [
125 'gaia/fake_gaia.cc',
126 'gaia/fake_gaia.h',
127 ],
128 },
Torne (Richard Coles)58218062012-11-14 11:43:16 +0000129 ],
130}