Small clean up to about_flags_unittest.cc.
[chromium-blink-merge.git] / components / dom_distiller.gypi
blobc2bb83dc7cb05b324d048272582298243611f37b
1 # Copyright 2013 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.
6   'targets': [
7     {
8       # GN version: //components/dom_distiller/webui
9       'target_name': 'dom_distiller_webui',
10       'type': 'static_library',
11       'dependencies': [
12         '../base/base.gyp:base',
13         '../content/content.gyp:content_browser',
14         '../net/net.gyp:net',
15         '../skia/skia.gyp:skia',
16         '../sync/sync.gyp:sync',
17         '../url/url.gyp:url_lib',
18         'components_resources.gyp:components_resources',
19         'components_strings.gyp:components_strings',
20         'dom_distiller_core',
21         'dom_distiller_protos',
22       ],
23       'include_dirs': [
24         '..',
25       ],
26       'sources': [
27         'dom_distiller/webui/dom_distiller_handler.cc',
28         'dom_distiller/webui/dom_distiller_handler.h',
29         'dom_distiller/webui/dom_distiller_ui.cc',
30         'dom_distiller/webui/dom_distiller_ui.h',
31       ],
32     },
33     {
34       # GN version: //components/dom_distiller/core
35       'target_name': 'dom_distiller_core',
36       'type': 'static_library',
37       'dependencies': [
38         '../base/base.gyp:base',
39         '../base/base.gyp:base_prefs',
40         '../skia/skia.gyp:skia',
41         '../sync/sync.gyp:sync',
42         '../third_party/re2/re2.gyp:re2',
43         '../third_party/dom_distiller_js/dom_distiller_js.gyp:dom_distiller_js_proto',
44         'components.gyp:leveldb_proto',
45         'components_resources.gyp:components_resources',
46         'components_strings.gyp:components_strings',
47         'dom_distiller_protos',
48         'pref_registry',
49       ],
50       'include_dirs': [
51         '..',
52       ],
53       'export_dependent_settings': [
54         'dom_distiller_protos',
55         '../third_party/dom_distiller_js/dom_distiller_js.gyp:dom_distiller_js_proto',
56       ],
57       'sources': [
58         'dom_distiller/android/component_jni_registrar.cc',
59         'dom_distiller/android/component_jni_registrar.h',
60         'dom_distiller/core/article_attachments_data.cc',
61         'dom_distiller/core/article_attachments_data.h',
62         'dom_distiller/core/article_distillation_update.cc',
63         'dom_distiller/core/article_distillation_update.h',
64         'dom_distiller/core/article_entry.cc',
65         'dom_distiller/core/article_entry.h',
66         'dom_distiller/core/distillable_page_detector.cc',
67         'dom_distiller/core/distillable_page_detector.h',
68         'dom_distiller/core/distilled_content_store.cc',
69         'dom_distiller/core/distilled_content_store.h',
70         'dom_distiller/core/distilled_page_prefs.cc',
71         'dom_distiller/core/distilled_page_prefs.h',
72         'dom_distiller/core/distilled_page_prefs_android.cc',
73         'dom_distiller/core/distilled_page_prefs_android.h',
74         'dom_distiller/core/distiller.cc',
75         'dom_distiller/core/distiller.h',
76         'dom_distiller/core/distiller_page.cc',
77         'dom_distiller/core/distiller_page.h',
78         'dom_distiller/core/distiller_url_fetcher.cc',
79         'dom_distiller/core/distiller_url_fetcher.h',
80         'dom_distiller/core/dom_distiller_constants.cc',
81         'dom_distiller/core/dom_distiller_constants.h',
82         'dom_distiller/core/dom_distiller_model.cc',
83         'dom_distiller/core/dom_distiller_model.h',
84         'dom_distiller/core/dom_distiller_observer.h',
85         'dom_distiller/core/dom_distiller_request_view_base.cc',
86         'dom_distiller/core/dom_distiller_request_view_base.h',
87         'dom_distiller/core/dom_distiller_service.cc',
88         'dom_distiller/core/dom_distiller_service.h',
89         'dom_distiller/core/dom_distiller_service_android.cc',
90         'dom_distiller/core/dom_distiller_service_android.h',
91         'dom_distiller/core/dom_distiller_store.cc',
92         'dom_distiller/core/dom_distiller_store.h',
93         'dom_distiller/core/dom_distiller_switches.cc',
94         'dom_distiller/core/dom_distiller_switches.h',
95         'dom_distiller/core/experiments.cc',
96         'dom_distiller/core/experiments.h',
97         'dom_distiller/core/external_feedback_reporter.h',
98         'dom_distiller/core/feedback_reporter.cc',
99         'dom_distiller/core/feedback_reporter.h',
100         'dom_distiller/core/font_family_list.h',
101         'dom_distiller/core/page_features.cc',
102         'dom_distiller/core/page_features.h',
103         'dom_distiller/core/task_tracker.cc',
104         'dom_distiller/core/task_tracker.h',
105         'dom_distiller/core/theme_list.h',
106         'dom_distiller/core/url_constants.cc',
107         'dom_distiller/core/url_constants.h',
108         'dom_distiller/core/url_utils.cc',
109         'dom_distiller/core/url_utils.h',
110         'dom_distiller/core/url_utils_android.cc',
111         'dom_distiller/core/url_utils_android.h',
112         'dom_distiller/core/viewer.cc',
113         'dom_distiller/core/viewer.h',
114       ],
115       'conditions': [
116         ['OS == "android"', {
117           'dependencies': [
118             'dom_distiller_core_jni_headers',
119           ],
120         }],
121       ],
122     },
123     {
124       # GN version: components/dom_distiller/core:test_support
125       'target_name': 'dom_distiller_test_support',
126       'type': 'static_library',
127       'dependencies': [
128         'dom_distiller_core',
129         'components.gyp:leveldb_proto_test_support',
130         '../sync/sync.gyp:sync',
131         '../testing/gmock.gyp:gmock',
132         '../url/url.gyp:url_lib',
133       ],
134       'include_dirs': [
135         '..',
136       ],
137       'sources': [
138         'dom_distiller/core/dom_distiller_test_util.cc',
139         'dom_distiller/core/dom_distiller_test_util.h',
140         'dom_distiller/core/fake_distiller.cc',
141         'dom_distiller/core/fake_distiller.h',
142         'dom_distiller/core/fake_distiller_page.cc',
143         'dom_distiller/core/fake_distiller_page.h',
144       ],
145     },
146     {
147       # GN version: //components/dom_distiller/core/proto
148       'target_name': 'dom_distiller_protos',
149       'type': 'static_library',
150       'sources': [
151         'dom_distiller/core/proto/adaboost.proto',
152         'dom_distiller/core/proto/distilled_article.proto',
153         'dom_distiller/core/proto/distilled_page.proto',
154       ],
155       'variables': {
156         'proto_in_dir': 'dom_distiller/core/proto',
157         'proto_out_dir': 'components/dom_distiller/core/proto',
158       },
159       'includes': [ '../build/protoc.gypi' ]
160     },
161   ],
162   'conditions': [
163     ['OS != "ios"', {
164       'targets': [
165         {
166           # GN version: //components/dom_distiller/content
167           'target_name': 'dom_distiller_content',
168           'type': 'static_library',
169           'dependencies': [
170             '../base/base.gyp:base',
171             '../content/content.gyp:content_browser',
172             '../net/net.gyp:net',
173             '../skia/skia.gyp:skia',
174             '../sync/sync.gyp:sync',
175             '../ui/gfx/gfx.gyp:gfx',
176             '../url/url.gyp:url_lib',
177             'components_resources.gyp:components_resources',
178             'components_strings.gyp:components_strings',
179             'dom_distiller_core',
180             'dom_distiller_protos',
181           ],
182           'include_dirs': [
183             '..',
184           ],
185           'sources': [
186             'dom_distiller/content/distillable_page_utils.cc',
187             'dom_distiller/content/distillable_page_utils.h',
188             'dom_distiller/content/distillable_page_utils_android.cc',
189             'dom_distiller/content/distillable_page_utils_android.h',
190             'dom_distiller/content/distiller_page_web_contents.cc',
191             'dom_distiller/content/distiller_page_web_contents.h',
192             'dom_distiller/content/dom_distiller_viewer_source.cc',
193             'dom_distiller/content/dom_distiller_viewer_source.h',
194             'dom_distiller/content/web_contents_main_frame_observer.cc',
195             'dom_distiller/content/web_contents_main_frame_observer.h',
196           ],
197           'conditions': [
198             ['OS == "android"', {
199               'dependencies': [
200                 'dom_distiller_content_jni_headers',
201                 'dom_distiller_core_jni_headers',
202               ],
203             }],
204           ],
205         },
206       ],
207     }],
208     ['OS=="ios"', {
209       'targets': [
210         {
211           'target_name': 'dom_distiller_ios',
212           'type': 'static_library',
213           'dependencies': [
214             '../ios/provider/ios_provider_web.gyp:ios_provider_web',
215             'dom_distiller_protos',
216             'dom_distiller_core',
217           ],
218           'include_dirs': [
219             '..',
220           ],
221           'sources': [
222             'dom_distiller/ios/distiller_page_factory_ios.h',
223             'dom_distiller/ios/distiller_page_factory_ios.mm',
224             'dom_distiller/ios/distiller_page_ios.h',
225             'dom_distiller/ios/distiller_page_ios.mm',
226           ],
227         },
228       ],
229     }],
230     ['OS=="android"', {
231       'targets': [
232         {
233           # TODO(cjhopman): remove this when it is rolled downstream.
234           'target_name': 'dom_distiller_core_java',
235           'type': 'none',
236           'dependencies': [
237             'dom_distiller_java',
238           ],
239         },
240         {
241           # GN: //components/dom_distiller/android:dom_distiller_java
242           'target_name': 'dom_distiller_java',
243           'type': 'none',
244           'dependencies': [
245             'dom_distiller_core_font_family_java',
246             'dom_distiller_core_theme_java',
247             '../base/base.gyp:base',
248             '../content/content.gyp:content_java',
249           ],
250           'variables': {
251             'java_in_dir': 'dom_distiller/android/java',
252           },
253           'includes': [ '../build/java.gypi' ],
254         },
255         {
256           # GN: //components/dom_distiller/android:dom_distiller_core_font_family_javagen
257           'target_name': 'dom_distiller_core_font_family_java',
258           'type': 'none',
259           'sources': [
260             'dom_distiller/android/java/src/org/chromium/components/dom_distiller/core/FontFamily.template',
261           ],
262           'variables': {
263             'package_name': 'org/chromium/components/dom_distiller/core',
264             'template_deps': ['dom_distiller/core/font_family_list.h'],
265           },
266           'includes': [ '../build/android/java_cpp_template.gypi' ],
267         },
268         {
269           # GN: //components/dom_distiller/content:jni_headers
270           'target_name': 'dom_distiller_content_jni_headers',
271           'type': 'none',
272           'sources': [
273             'dom_distiller/android/java/src/org/chromium/components/dom_distiller/content/DistillablePageUtils.java',
274           ],
275           'variables': {
276             'jni_gen_package': 'dom_distiller_content',
277           },
278           'includes': [ '../build/jni_generator.gypi' ],
279         },
280         {
281           # GN: //components/dom_distiller/core:jni_headers
282           'target_name': 'dom_distiller_core_jni_headers',
283           'type': 'none',
284           'sources': [
285             'dom_distiller/android/java/src/org/chromium/components/dom_distiller/core/DistilledPagePrefs.java',
286             'dom_distiller/android/java/src/org/chromium/components/dom_distiller/core/DomDistillerService.java',
287             'dom_distiller/android/java/src/org/chromium/components/dom_distiller/core/DomDistillerUrlUtils.java',
288           ],
289           'variables': {
290             'jni_gen_package': 'dom_distiller_core',
291           },
292           'includes': [ '../build/jni_generator.gypi' ],
293         },
294         {
295           # GN: //components/dom_distiller/android:dom_distiller_core_theme_javagen
296           'target_name': 'dom_distiller_core_theme_java',
297           'type': 'none',
298           'sources': [
299             'dom_distiller/android/java/src/org/chromium/components/dom_distiller/core/Theme.template',
300           ],
301           'variables': {
302             'package_name': 'org/chromium/components/dom_distiller/core',
303             'template_deps': ['dom_distiller/core/theme_list.h'],
304           },
305           'includes': [ '../build/android/java_cpp_template.gypi' ],
306         },
307       ],
308     }],
309   ],