summaryrefslogtreecommitdiffstats
path: root/components/leveldb_proto.gypi
diff options
context:
space:
mode:
authormathp@chromium.org <mathp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-06-18 16:22:30 +0000
committermathp@chromium.org <mathp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-06-18 16:22:30 +0000
commit2b894b8dae83b4bada9199713504aeb52cdfc8ed (patch)
treef527ed157c42675be946635c08a81288863b4ef5 /components/leveldb_proto.gypi
parentab4f95a66b2e01a329562d2f7a2b4445b0e4ee47 (diff)
downloadchromium_src-2b894b8dae83b4bada9199713504aeb52cdfc8ed.zip
chromium_src-2b894b8dae83b4bada9199713504aeb52cdfc8ed.tar.gz
chromium_src-2b894b8dae83b4bada9199713504aeb52cdfc8ed.tar.bz2
Extract protobuf database into a new 'leveldb_proto' component
Code extracted from components/dom_distiller/core/dom_distiller_database.* Slight API change: callers to UpdateEntries now have to pass a vector of (string, proto) as key and value, instead of just a vector of protos where key is derived. Ran clang-format on the files I touched so you may see some diffs. Note: Implementations are in proto_database_impl.h and fake_db.h for proper linking. BUG=385747 TBR=jochen,dgrogan TEST=DomDistiller*,ProtoDatabaseImplTest Review URL: https://codereview.chromium.org/330833002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@278096 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'components/leveldb_proto.gypi')
-rw-r--r--components/leveldb_proto.gypi44
1 files changed, 44 insertions, 0 deletions
diff --git a/components/leveldb_proto.gypi b/components/leveldb_proto.gypi
new file mode 100644
index 0000000..b90ad90
--- /dev/null
+++ b/components/leveldb_proto.gypi
@@ -0,0 +1,44 @@
+# 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.
+
+{
+ 'targets': [
+ {
+ 'target_name': 'leveldb_proto',
+ 'type': 'static_library',
+ 'include_dirs': [
+ '..',
+ ],
+ 'dependencies': [
+ '../base/base.gyp:base',
+ '../third_party/leveldatabase/leveldatabase.gyp:leveldatabase',
+ ],
+ 'sources': [
+ 'leveldb_proto/leveldb_database.cc',
+ 'leveldb_proto/leveldb_database.h',
+ 'leveldb_proto/proto_database.h',
+ 'leveldb_proto/proto_database_impl.h',
+ ]
+ },
+ {
+ 'target_name': 'leveldb_proto_test_support',
+ 'type': 'static_library',
+ 'dependencies': [
+ 'leveldb_proto',
+ ],
+ 'include_dirs': [
+ '..',
+ ],
+ 'sources': [
+ 'leveldb_proto/testing/fake_db.h',
+ 'leveldb_proto/testing/proto/test.proto',
+ ],
+ 'variables': {
+ 'proto_in_dir': 'leveldb_proto/testing/proto',
+ 'proto_out_dir': 'components/leveldb_proto/testing/proto',
+ },
+ 'includes': [ '../build/protoc.gypi' ]
+ },
+ ],
+}