blob: 711abf9d3001dc7cb82e938a4c33c86027bed51b [file] [log] [blame]
[email protected]3e1d8c82012-05-31 04:36:031# Copyright (c) 2012 The Chromium Authors. All rights reserved.
[email protected]40ce1e442011-06-30 15:03:112# 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,
8 },
9 'targets': [
10 {
11 'target_name': 'sql',
[email protected]d4526962011-11-10 21:40:2812 'type': '<(component)',
[email protected]40ce1e442011-06-30 15:03:1113 'dependencies': [
14 '../base/base.gyp:base',
15 '../third_party/sqlite/sqlite.gyp:sqlite',
[email protected]a7ec1292013-07-22 22:02:1816 '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
[email protected]40ce1e442011-06-30 15:03:1117 ],
[email protected]4350e322013-06-18 22:18:1018 'export_dependent_settings': [
19 '../base/base.gyp:base',
20 ],
[email protected]d4526962011-11-10 21:40:2821 'defines': [ 'SQL_IMPLEMENTATION' ],
[email protected]40ce1e442011-06-30 15:03:1122 'sources': [
[email protected]f0a54b22011-07-19 18:40:2123 'connection.cc',
24 'connection.h',
[email protected]0d04ede2012-10-18 04:31:5325 'error_delegate_util.cc',
26 'error_delegate_util.h',
[email protected]f0a54b22011-07-19 18:40:2127 'init_status.h',
28 'meta_table.cc',
29 'meta_table.h',
[email protected]8d409412013-07-19 18:25:3030 'recovery.cc',
31 'recovery.h',
[email protected]f0a54b22011-07-19 18:40:2132 'statement.cc',
33 'statement.h',
34 'transaction.cc',
35 'transaction.h',
[email protected]40ce1e442011-06-30 15:03:1136 ],
[email protected]4350e322013-06-18 22:18:1037 'include_dirs': [
38 '..',
39 ],
40 'direct_dependent_settings': {
41 'include_dirs': [
42 '..',
43 ],
44 },
[email protected]4be31d42013-01-11 18:47:5345 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
46 'msvs_disabled_warnings': [4267, ],
[email protected]40ce1e442011-06-30 15:03:1147 },
48 {
[email protected]4350e322013-06-18 22:18:1049 'target_name': 'test_support_sql',
50 'type': 'static_library',
51 'dependencies': [
52 'sql',
53 '../base/base.gyp:base',
54 '../testing/gtest.gyp:gtest',
Scott Hessdcf120482015-02-10 21:33:2955 '../third_party/sqlite/sqlite.gyp:sqlite',
[email protected]4350e322013-06-18 22:18:1056 ],
57 'export_dependent_settings': [
58 'sql',
59 '../base/base.gyp:base',
60 ],
61 'sources': [
[email protected]98cf3002013-07-12 01:38:5662 'test/error_callback_support.cc',
63 'test/error_callback_support.h',
[email protected]4350e322013-06-18 22:18:1064 'test/scoped_error_ignorer.cc',
65 'test/scoped_error_ignorer.h',
[email protected]43ffdd82013-09-10 23:44:5066 'test/test_helpers.cc',
67 'test/test_helpers.h',
[email protected]4350e322013-06-18 22:18:1068 ],
69 'include_dirs': [
70 '..',
71 ],
72 'direct_dependent_settings': {
73 'include_dirs': [
74 '..',
75 ],
76 },
77 },
78 {
[email protected]40ce1e442011-06-30 15:03:1179 'target_name': 'sql_unittests',
[email protected]3e1d8c82012-05-31 04:36:0380 'type': '<(gtest_target_type)',
[email protected]40ce1e442011-06-30 15:03:1181 'dependencies': [
82 'sql',
[email protected]4350e322013-06-18 22:18:1083 'test_support_sql',
[email protected]40ce1e442011-06-30 15:03:1184 '../base/base.gyp:test_support_base',
85 '../testing/gtest.gyp:gtest',
[email protected]dd325f052013-08-06 02:37:4086 '../third_party/sqlite/sqlite.gyp:sqlite',
[email protected]40ce1e442011-06-30 15:03:1187 ],
88 'sources': [
[email protected]f0a54b22011-07-19 18:40:2189 'connection_unittest.cc',
[email protected]6ed6d14f2013-09-07 15:48:3690 'meta_table_unittest.cc',
[email protected]8d409412013-07-19 18:25:3091 'recovery_unittest.cc',
[email protected]f0a54b22011-07-19 18:40:2192 'sqlite_features_unittest.cc',
93 'statement_unittest.cc',
[email protected]cfb821612014-07-10 00:48:0694 'test/paths.cc',
95 'test/paths.h',
96 'test/run_all_unittests.cc',
97 'test/sql_test_suite.cc',
98 'test/sql_test_suite.h',
[email protected]f0a54b22011-07-19 18:40:2199 'transaction_unittest.cc',
[email protected]40ce1e442011-06-30 15:03:11100 ],
101 'include_dirs': [
102 '..',
103 ],
104 'conditions': [
[email protected]073bef82012-07-24 18:03:47105 ['os_posix==1 and OS!="mac" and OS!="ios"', {
[email protected]40ce1e442011-06-30 15:03:11106 'conditions': [
[email protected]2fa89ef2014-05-07 18:45:59107 ['use_allocator!="none"', {
[email protected]40ce1e442011-06-30 15:03:11108 'dependencies': [
109 '../base/allocator/allocator.gyp:allocator',
110 ],
111 }],
112 ],
113 }],
[email protected]87a80852014-05-17 16:09:58114 ['OS == "android"', {
[email protected]3e1d8c82012-05-31 04:36:03115 'dependencies': [
116 '../testing/android/native_test.gyp:native_test_native_code',
117 ],
118 }],
the_jkffdda022014-10-03 11:36:19119 ['sqlite_enable_fts2', {
120 'defines': [
121 'SQLITE_ENABLE_FTS2',
122 ],
123 }],
[email protected]40ce1e442011-06-30 15:03:11124 ],
[email protected]4be31d42013-01-11 18:47:53125 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
126 'msvs_disabled_warnings': [4267, ],
[email protected]40ce1e442011-06-30 15:03:11127 },
128 ],
[email protected]3e1d8c82012-05-31 04:36:03129 'conditions': [
[email protected]87a80852014-05-17 16:09:58130 ['OS == "android"', {
[email protected]3e1d8c82012-05-31 04:36:03131 'targets': [
132 {
133 'target_name': 'sql_unittests_apk',
134 'type': 'none',
135 'dependencies': [
[email protected]3e1d8c82012-05-31 04:36:03136 'sql_unittests',
137 ],
138 'variables': {
139 'test_suite_name': 'sql_unittests',
[email protected]3e1d8c82012-05-31 04:36:03140 },
141 'includes': [ '../build/apk_test.gypi' ],
142 },
143 ],
144 }],
[email protected]cfb821612014-07-10 00:48:06145 ['test_isolation_mode != "noop"', {
146 'targets': [
147 {
148 'target_name': 'sql_unittests_run',
149 'type': 'none',
150 'dependencies': [
151 'sql_unittests',
152 ],
153 'includes': [
154 '../build/isolate.gypi',
[email protected]cfb821612014-07-10 00:48:06155 ],
156 'sources': [
157 'sql_unittests.isolate',
158 ],
159 },
160 ],
161 }],
[email protected]3e1d8c82012-05-31 04:36:03162 ],
[email protected]40ce1e442011-06-30 15:03:11163}