Remove define of defunct SK_DEBUG_PATH_REF from skia.gyp
[chromium-blink-merge.git] / content / content.gyp
blob68a6f4016caad44368555dcb746c0c7a01379c03
1 # Copyright (c) 2012 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   'variables': {
7     'chromium_code': 1,  # Use higher warning level.
8     'chromium_enable_vtune_jit_for_v8%': 0,  # enable the vtune support for V8 engine.
9     'directxsdk_exists': '<!(python <(DEPTH)/build/dir_exists.py ../third_party/directxsdk)',
10   },
11   'target_defaults': {
12     'defines': ['CONTENT_IMPLEMENTATION'],
13     'conditions': [
14       # TODO(jschuh): Remove this after crbug.com/173851 gets fixed.
15       ['OS=="win" and target_arch=="x64"', {
16         'msvs_settings': {
17           'VCCLCompilerTool': {
18             'AdditionalOptions': ['/bigobj'],
19           },
20         },
21       }],
22     ],
23   },
24   'includes': [
25     'content_tests.gypi',
26   ],
27   'conditions': [
28     ['OS != "ios"', {
29       'includes': [
30         '../build/win_precompile.gypi',
31         'content_shell.gypi',
32       ],
33     }],
34     # In component mode, we build all of content as a single DLL.
35     # However, in the static mode, we need to build content as multiple
36     # targets in order to prevent dependencies from getting introduced
37     # upstream unnecessarily (e.g., content_renderer depends on allocator
38     # and chrome_exe depends on content_common but we don't want
39     # chrome_exe to have to depend on allocator).
40     ['component=="static_library"', {
41       'target_defines': [
42         'COMPILE_CONTENT_STATICALLY',
43       ],
44       'targets': [
45         {
46           'target_name': 'content',
47           'type': 'none',
48           'dependencies': [
49             'content_app',
50             'content_browser',
51             'content_child',
52             'content_common',
53           ],
54           'conditions': [
55             ['OS != "ios" and chrome_split_dll != 1', {
56               'dependencies': [
57                 'content_gpu',
58                 'content_plugin',
59                 'content_ppapi_plugin',
60                 'content_renderer',
61                 'content_utility',
62                 'content_worker',
63               ],
64             }],
65           ],
66         },
67         {
68           'target_name': 'content_app',
69           'type': 'static_library',
70           'variables': { 'enable_wexit_time_destructors': 1, },
71           'includes': [
72             'content_app.gypi',
73           ],
74           'dependencies': [
75             'content_common',
76           ],
77         },
78         {
79           'target_name': 'content_browser',
80           'type': 'static_library',
81           'variables': { 'enable_wexit_time_destructors': 1, },
82           'includes': [
83             'content_browser.gypi',
84           ],
85           'dependencies': [
86             'content_common',
87             'content_resources.gyp:content_resources',
88           ],
89           'conditions': [
90             ['OS != "ios" and chrome_split_dll != 1', {
91               'dependencies': [
92                 'content_gpu',
93                 'content_renderer',
94               ],
95             }],
96             ['chrome_split_dll', {
97               'dependencies': [
98                 'content_gpu',
99               ],
100             }],
101             ['java_bridge==1', {
102               'dependencies': [
103                 'content_child',
104               ]
105             }]
106           ],
107         },
108         {
109           'target_name': 'content_common',
110           'type': 'static_library',
111           'variables': { 'enable_wexit_time_destructors': 1, },
112           'includes': [
113             'content_common.gypi',
114           ],
115           'conditions': [
116             ['OS != "ios"', {
117               'dependencies': [
118                 'content_resources.gyp:content_resources',
119               ],
120             }],
121           ],
122           # Disable c4267 warnings until we fix size_t to int truncations.
123           'msvs_disabled_warnings': [ 4267, ],
124         },
125         {
126           'target_name': 'content_child',
127           'type': 'static_library',
128           'variables': { 'enable_wexit_time_destructors': 1, },
129           'includes': [
130             'content_child.gypi',
131           ],
132           'conditions': [
133             ['OS != "ios"', {
134               'dependencies': [
135                 'content_resources.gyp:content_resources',
136               ],
137             }],
138           ],
139           # Disable c4267 warnings until we fix size_t to int truncations.
140           'msvs_disabled_warnings': [ 4267, ],
141         },
143       ],
144       'conditions': [
145         ['OS != "ios"', {
146           'targets': [
147             {
148               'target_name': 'content_gpu',
149               'type': 'static_library',
150               'variables': { 'enable_wexit_time_destructors': 1, },
151               'includes': [
152                 'content_gpu.gypi',
153               ],
154               'dependencies': [
155                 'content_common',
156               ],
157             },
158             {
159               'target_name': 'content_plugin',
160               'type': 'static_library',
161               'variables': { 'enable_wexit_time_destructors': 1, },
162               'includes': [
163                 'content_plugin.gypi',
164               ],
165               'dependencies': [
166                 'content_child',
167                 'content_common',
168               ],
169             },
170             {
171               'target_name': 'content_ppapi_plugin',
172               'type': 'static_library',
173               'variables': { 'enable_wexit_time_destructors': 1, },
174               'includes': [
175                 'content_ppapi_plugin.gypi',
176               ],
177               # Disable c4267 warnings until we fix size_t to int truncations.
178               'msvs_disabled_warnings': [ 4267, ],
179             },
180             {
181               'target_name': 'content_renderer',
182               'type': 'static_library',
183               'variables': { 'enable_wexit_time_destructors': 1, },
184               'includes': [
185                 'content_renderer.gypi',
186               ],
187               'dependencies': [
188                 'content_child',
189                 'content_common',
190                 'content_resources.gyp:content_resources',
191               ],
192               'conditions': [
193                 ['chromium_enable_vtune_jit_for_v8==1', {
194                   'dependencies': [
195                     '../v8/src/third_party/vtune/v8vtune.gyp:v8_vtune',
196                   ],
197                 }],
198               ],
199             },
200             {
201               'target_name': 'content_utility',
202               'type': 'static_library',
203               'variables': { 'enable_wexit_time_destructors': 1, },
204               'includes': [
205                 'content_utility.gypi',
206               ],
207               'dependencies': [
208                 'content_common',
209               ],
210             },
211             {
212               'target_name': 'content_worker',
213               'type': 'static_library',
214               'variables': { 'enable_wexit_time_destructors': 1, },
215               'includes': [
216                 'content_worker.gypi',
217               ],
218               'dependencies': [
219                 'content_child',
220                 'content_common',
221               ],
222             },
223           ],
224         }],
225       ],
226     },
227     {  # component != static_library
228       'targets': [
229         {
230           'target_name': 'content',
231           'type': 'shared_library',
232           'variables': { 'enable_wexit_time_destructors': 1, },
233           'dependencies': [
234            'content_resources.gyp:content_resources',
235           ],
236           'conditions': [
237             ['OS=="mac"', {
238               'dependencies': [
239                 '<(DEPTH)/third_party/mach_override/mach_override.gyp:mach_override',
240               ],
241             }],
242             ['chromium_enable_vtune_jit_for_v8==1', {
243               'dependencies': [
244                 '../v8/src/third_party/vtune/v8vtune.gyp:v8_vtune',
245               ],
246             }],
247           ],
248           'includes': [
249             'content_app.gypi',
250             'content_browser.gypi',
251             'content_child.gypi',
252             'content_common.gypi',
253             'content_gpu.gypi',
254             'content_plugin.gypi',
255             'content_ppapi_plugin.gypi',
256             'content_renderer.gypi',
257             'content_utility.gypi',
258             'content_worker.gypi',
259           ],
260           'msvs_settings': {
261             'VCLinkerTool': {
262               'conditions': [
263                 ['incremental_chrome_dll==1', {
264                   'UseLibraryDependencyInputs': "true",
265                 }],
266               ],
267             },
268           },
269         },
270         {
271           'target_name': 'content_app',
272           'type': 'none',
273           'dependencies': ['content', 'content_browser'],
274         },
275         {
276           'target_name': 'content_browser',
277           'type': 'none',
278           'dependencies': ['content'],
279         },
280         {
281           'target_name': 'content_common',
282           'type': 'none',
283           'dependencies': ['content', 'content_resources.gyp:content_resources'],
284           # Disable c4267 warnings until we fix size_t to int truncations.
285           'msvs_disabled_warnings': [ 4267, ],
286         },
287         {
288           'target_name': 'content_child',
289           'type': 'none',
290           'dependencies': ['content'],
291         },
292         {
293           'target_name': 'content_gpu',
294           'type': 'none',
295           'dependencies': ['content'],
296         },
297         {
298           'target_name': 'content_plugin',
299           'type': 'none',
300           'dependencies': ['content'],
301         },
302         {
303           'target_name': 'content_ppapi_plugin',
304           'type': 'none',
305           'dependencies': ['content'],
306           # Disable c4267 warnings until we fix size_t to int truncations.
307           'msvs_disabled_warnings': [ 4267, ],
308         },
309         {
310           'target_name': 'content_renderer',
311           'type': 'none',
312           'dependencies': ['content'],
313         },
314         {
315           'target_name': 'content_utility',
316           'type': 'none',
317           'dependencies': ['content'],
318         },
319         {
320           'target_name': 'content_worker',
321           'type': 'none',
322           'dependencies': ['content'],
323         },
324       ],
325     }],
326     ['OS == "android"', {
327       'targets': [
328         {
329           'target_name': 'common_aidl',
330           'type': 'none',
331           'variables': {
332             'aidl_interface_file': 'public/android/java/src/org/chromium/content/common/common.aidl',
333           },
334           'sources': [
335             'public/android/java/src/org/chromium/content/common/IChildProcessCallback.aidl',
336             'public/android/java/src/org/chromium/content/common/IChildProcessService.aidl',
337           ],
338           'includes': [ '../build/java_aidl.gypi' ],
339         },
340         {
341           'target_name': 'content_native_libraries_gen',
342           'type': 'none',
343           'sources': [
344             'public/android/java/templates/NativeLibraries.template',
345           ],
346           'variables': {
347             'package_name': 'org/chromium/content/app',
348             'include_path': 'public/android/java/templates',
349             'template_deps': [
350               'public/android/java/templates/native_libraries_array.h'
351             ],
352           },
353           'includes': [ '../build/android/java_cpp_template.gypi' ],
354         },
355         {
356           'target_name': 'content_java',
357           'type': 'none',
358           'dependencies': [
359             '../base/base.gyp:base',
360             '../media/media.gyp:media_java',
361             '../net/net.gyp:net',
362             '../ui/ui.gyp:ui_java',
363             'common_aidl',
364             'content_common',
365             'page_transition_types_java',
366             'result_codes_java',
367             'speech_recognition_error_java',
368             'top_controls_state_java',
369             'content_native_libraries_gen',
370           ],
371           'variables': {
372             'java_in_dir': '../content/public/android/java',
373             'jar_excluded_classes': [ '*/NativeLibraries.class' ],
374             'has_java_resources': 1,
375             'R_package': 'org.chromium.content',
376             'R_package_relpath': 'org/chromium/content',
377             'java_strings_grd': 'android_content_strings.grd',
378           },
379           'conditions': [
380             ['android_webview_build == 0', {
381               'dependencies': [
382                 '../third_party/eyesfree/eyesfree.gyp:eyesfree_java',
383                 '../third_party/guava/guava.gyp:guava_javalib',
384               ],
385             }],
386           ],
387           'includes': [ '../build/java.gypi' ],
388         },
389         {
390           'target_name': 'page_transition_types_java',
391           'type': 'none',
392           'sources': [
393             'public/android/java/src/org/chromium/content/browser/PageTransitionTypes.template',
394           ],
395           'variables': {
396             'package_name': 'org/chromium/content/browser',
397             'template_deps': ['public/common/page_transition_types_list.h'],
398           },
399           'includes': [ '../build/android/java_cpp_template.gypi' ],
400         },
401         {
402           'target_name': 'result_codes_java',
403           'type': 'none',
404           'sources': [
405             'public/android/java/src/org/chromium/content/common/ResultCodes.template',
406           ],
407           'variables': {
408             'package_name': 'org/chromium/content/common',
409             'template_deps': ['public/common/result_codes_list.h'],
410           },
411           'includes': [ '../build/android/java_cpp_template.gypi' ],
412         },
413         {
414           'target_name': 'speech_recognition_error_java',
415           'type': 'none',
416           'sources': [
417             'public/android/java/src/org/chromium/content/browser/SpeechRecognitionError.template',
418           ],
419           'variables': {
420             'package_name': 'org/chromium/content/browser',
421             'template_deps': ['public/common/speech_recognition_error_list.h'],
422           },
423           'includes': [ '../build/android/java_cpp_template.gypi' ],
424         },
425         {
426           'target_name': 'top_controls_state_java',
427           'type': 'none',
428           'sources': [
429             'public/android/java/src/org/chromium/content/common/TopControlsState.template',
430           ],
431           'variables': {
432             'package_name': 'org/chromium/content/common',
433             'template_deps': ['public/common/top_controls_state_list.h'],
434           },
435           'includes': [ '../build/android/java_cpp_template.gypi' ],
436         },
437         {
438           'target_name': 'java_set_jni_headers',
439           'type': 'none',
440           'variables': {
441             'jni_gen_package': 'content',
442             'input_java_class': 'java/util/HashSet.class',
443           },
444           'includes': [ '../build/jar_file_jni_generator.gypi' ],
445         },
447         {
448           'target_name': 'content_jni_headers',
449           'type': 'none',
450           'dependencies': [
451             'java_set_jni_headers',
452           ],
453           'direct_dependent_settings': {
454             'include_dirs': [
455               '<(SHARED_INTERMEDIATE_DIR)/content',
456             ],
457           },
458           'includes': [ 'content_jni.gypi' ],
459         },
460       ],
461     }],  # OS == "android"
462   ],