OLD | NEW |
1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/buildflag_header.gni") | 5 import("//components/reading_list/features/reading_list.gni") |
6 import("//components/reading_list/core/reading_list.gni") | |
7 | 6 |
8 source_set("core") { | 7 source_set("core") { |
9 sources = [ | 8 sources = [ |
10 "offline_url_utils.cc", | 9 "offline_url_utils.cc", |
11 "offline_url_utils.h", | 10 "offline_url_utils.h", |
12 "reading_list_entry.cc", | 11 "reading_list_entry.cc", |
13 "reading_list_entry.h", | 12 "reading_list_entry.h", |
14 "reading_list_model.cc", | 13 "reading_list_model.cc", |
15 "reading_list_model.h", | 14 "reading_list_model.h", |
16 "reading_list_model_impl.cc", | 15 "reading_list_model_impl.cc", |
17 "reading_list_model_impl.h", | 16 "reading_list_model_impl.h", |
18 "reading_list_model_observer.h", | 17 "reading_list_model_observer.h", |
19 "reading_list_model_storage.cc", | 18 "reading_list_model_storage.cc", |
20 "reading_list_model_storage.h", | 19 "reading_list_model_storage.h", |
21 "reading_list_pref_names.cc", | 20 "reading_list_pref_names.cc", |
22 "reading_list_pref_names.h", | 21 "reading_list_pref_names.h", |
23 "reading_list_store.cc", | 22 "reading_list_store.cc", |
24 "reading_list_store.h", | 23 "reading_list_store.h", |
25 "reading_list_store_delegate.h", | 24 "reading_list_store_delegate.h", |
26 ] | 25 ] |
27 deps = [ | 26 deps = [ |
28 ":flags", | |
29 "//base", | 27 "//base", |
30 "//components/keyed_service/core", | 28 "//components/keyed_service/core", |
31 "//components/prefs", | 29 "//components/prefs", |
| 30 "//components/reading_list/features:flags", |
32 "//components/sync", | 31 "//components/sync", |
33 "//net", | 32 "//net", |
34 "//url", | 33 "//url", |
35 ] | 34 ] |
36 public_deps = [ | 35 public_deps = [ |
37 "//components/reading_list/core/proto", | 36 "//components/reading_list/core/proto", |
38 ] | 37 ] |
39 } | 38 } |
40 | 39 |
41 source_set("unit_tests") { | 40 source_set("unit_tests") { |
42 testonly = true | 41 testonly = true |
43 sources = [ | 42 sources = [ |
44 "offline_url_utils_unittest.cc", | 43 "offline_url_utils_unittest.cc", |
45 "reading_list_entry_unittest.cc", | 44 "reading_list_entry_unittest.cc", |
46 "reading_list_model_unittest.cc", | 45 "reading_list_model_unittest.cc", |
47 "reading_list_store_unittest.cc", | 46 "reading_list_store_unittest.cc", |
48 ] | 47 ] |
49 deps = [ | 48 deps = [ |
50 ":core", | 49 ":core", |
51 "//base", | 50 "//base", |
52 "//base/test:test_support", | 51 "//base/test:test_support", |
53 "//components/sync", | 52 "//components/sync", |
54 "//components/sync:test_support_model", | 53 "//components/sync:test_support_model", |
55 "//testing/gtest", | 54 "//testing/gtest", |
56 "//url", | 55 "//url", |
57 ] | 56 ] |
58 } | 57 } |
59 | |
60 source_set("flags") { | |
61 sources = [ | |
62 "reading_list_switches.cc", | |
63 "reading_list_switches.h", | |
64 ] | |
65 deps = [ | |
66 "//base", | |
67 ] | |
68 public_deps = [ | |
69 ":reading_list_enable_flags", | |
70 ] | |
71 } | |
72 | |
73 buildflag_header("reading_list_enable_flags") { | |
74 header = "reading_list_enable_flags.h" | |
75 _enabled = is_ios && enable_reading_list | |
76 flags = [ "ENABLE_READING_LIST=$_enabled" ] | |
77 } | |
OLD | NEW |