diff options
author | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-05-28 20:26:57 +0000 |
---|---|---|
committer | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-05-28 20:26:57 +0000 |
commit | b2b2bf50c65c35256bff18da5ea7f4ec4199726c (patch) | |
tree | ef6f9dca9385a5dcd97fc70c9716bd4331bd0e4b /sql | |
parent | 4ea262ab93ecb152370cb2e25f0d23145029857c (diff) | |
download | chromium_src-b2b2bf50c65c35256bff18da5ea7f4ec4199726c.zip chromium_src-b2b2bf50c65c35256bff18da5ea7f4ec4199726c.tar.gz chromium_src-b2b2bf50c65c35256bff18da5ea7f4ec4199726c.tar.bz2 |
Add GN build files for sql and google_apis.
R=scottmg@chromium.org, scottmg
Review URL: https://codereview.chromium.org/298293005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@273343 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'sql')
-rw-r--r-- | sql/BUILD.gn | 94 |
1 files changed, 94 insertions, 0 deletions
diff --git a/sql/BUILD.gn b/sql/BUILD.gn new file mode 100644 index 0000000..2b50eac --- /dev/null +++ b/sql/BUILD.gn @@ -0,0 +1,94 @@ +# Copyright 2014 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. + +component("sql") { + sources = [ + "connection.cc", + "connection.h", + "error_delegate_util.cc", + "error_delegate_util.h", + "init_status.h", + "meta_table.cc", + "meta_table.h", + "recovery.cc", + "recovery.h", + "statement.cc", + "statement.h", + "transaction.cc", + "transaction.h", + ] + + defines = [ "SQL_IMPLEMENTATION" ] + + if (is_win) { + cflags += [ "/wd4267" ] # size_t to int. + } + + deps = [ + "//base", + "//third_party/sqlite", + "//base/third_party/dynamic_annotations", + ] +} + +source_set("test_support") { + sources = [ + "test/error_callback_support.cc", + "test/error_callback_support.h", + "test/scoped_error_ignorer.cc", + "test/scoped_error_ignorer.h", + "test/test_helpers.cc", + "test/test_helpers.h", + ] + + deps = [ + ":sql", + "//base", + "//testing/gtest", + ] +} + +test("sql_unittests") { + sources = [ + "connection_unittest.cc", + "meta_table_unittest.cc", + "recovery_unittest.cc", + "sqlite_features_unittest.cc", + "statement_unittest.cc", + "transaction_unittest.cc", + ] + + if (is_win) { + cflags = [ "/wd4267" ] # size_t -> int + } + + deps = [ + ":sql", + ":test_support", + "//base/allocator", + "//base/test:run_all_unittests", + "//testing/gtest", + "//third_party/sqlite", + ] + + # TODO(GYP) + #['OS == "android"', { + # 'dependencies': [ + # '../testing/android/native_test.gyp:native_test_native_code', + # ], + #}], +} + +if (is_android) { + #TODO(GYP) + #'target_name': 'sql_unittests_apk', + #'type': 'none', + #'dependencies': [ + # 'sql_unittests', + #], + #'variables': { + # 'test_suite_name': 'sql_unittests', + #}, + #'includes': [ '../build/apk_test.gypi' ], +} |