2 # Copyright (C) 2011 Google Inc. All rights reserved.
4 # Redistribution and use in source and binary forms, with or without
5 # modification, are permitted provided that the following conditions are
8 # * Redistributions of source code must retain the above copyright
9 # notice, this list of conditions and the following disclaimer.
10 # * Redistributions in binary form must reproduce the above
11 # copyright notice, this list of conditions and the following disclaimer
12 # in the documentation and/or other materials provided with the
14 # * Neither the name of Google Inc. nor the names of its
15 # contributors may be used to endorse or promote products derived from
16 # this software without specific prior written permission.
18 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
19 # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
20 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
21 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
22 # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
24 # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
25 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33 '../bindings/bindings.gypi',
35 '../build/features.gypi',
36 '../build/scripts/scripts.gypi',
37 '../build/win/precompile.gypi',
38 '../modules/modules.gypi',
44 'target_name': 'webkit',
45 'type': '<(component)',
46 'variables': { 'enable_wexit_time_destructors': 1, },
49 '../config.gyp:config',
50 '../platform/blink_platform.gyp:blink_common',
51 '../core/core.gyp:webcore',
52 '../modules/modules.gyp:modules',
53 '<(DEPTH)/skia/skia.gyp:skia',
54 '<(DEPTH)/third_party/angle_dx11/src/build_angle.gyp:translator',
55 '<(DEPTH)/third_party/icu/icu.gyp:icuuc',
56 '<(DEPTH)/third_party/npapi/npapi.gyp:npapi',
57 '<(DEPTH)/v8/tools/gyp/v8.gyp:v8',
59 'export_dependent_settings': [
60 '<(DEPTH)/skia/skia.gyp:skia',
61 '<(DEPTH)/third_party/icu/icu.gyp:icuuc',
62 '<(DEPTH)/third_party/npapi/npapi.gyp:npapi',
63 '<(DEPTH)/v8/tools/gyp/v8.gyp:v8',
68 '<(DEPTH)/third_party/angle_dx11/include',
69 '<(DEPTH)/third_party/skia/include/utils',
72 'BLINK_IMPLEMENTATION=1',
76 '<@(webcore_platform_support_files)',
80 ['component=="shared_library"', {
82 '../core/core.gyp:webcore_derived',
83 '../core/core.gyp:webcore_test_support',
84 '../modules/modules.gyp:modules_test_support',
85 '<(DEPTH)/base/base.gyp:test_support_base',
86 '<(DEPTH)/testing/gmock.gyp:gmock',
87 '<(DEPTH)/testing/gtest.gyp:gtest',
88 '<(DEPTH)/third_party/icu/icu.gyp:*',
89 '<(libjpeg_gyp_path):libjpeg',
90 '<(DEPTH)/third_party/libpng/libpng.gyp:libpng',
91 '<(DEPTH)/third_party/libwebp/libwebp.gyp:libwebp',
92 '<(DEPTH)/third_party/libxml/libxml.gyp:libxml',
93 '<(DEPTH)/third_party/libxslt/libxslt.gyp:libxslt',
94 '<(DEPTH)/third_party/modp_b64/modp_b64.gyp:modp_b64',
95 '<(DEPTH)/third_party/ots/ots.gyp:ots',
96 '<(DEPTH)/third_party/zlib/zlib.gyp:zlib',
97 '<(DEPTH)/url/url.gyp:url_lib',
98 '<(DEPTH)/v8/tools/gyp/v8.gyp:v8',
99 # We must not add webkit_support here because of cyclic dependency.
101 'export_dependent_settings': [
102 '<(DEPTH)/url/url.gyp:url_lib',
103 '<(DEPTH)/v8/tools/gyp/v8.gyp:v8',
106 # WARNING: Do not view this particular case as a precedent for
107 # including WebCore headers in DumpRenderTree project.
108 '../core/testing/v8', # for WebCoreTestSupport.h, needed to link in window.internals code.
111 # Compile Blink unittest files into webkit.dll in component build mode
112 # since there're methods that are tested but not exported.
113 # WebUnitTests.* exports an API that runs all the unittests inside
115 '<@(bindings_unittest_files)',
116 '<@(core_unittest_files)',
117 '<@(modules_unittest_files)',
118 '<@(web_unittest_files)',
119 'WebTestingSupport.cpp',
120 'tests/WebUnitTests.cpp', # Components test runner support.
123 ['OS=="win" or OS=="mac"', {
125 '<(DEPTH)/third_party/nss/nss.gyp:*',
129 # FIXME: It would be nice to enable this in shared builds too,
130 # but the test files have global constructors from the GTEST macro
131 # and we pull in the test files into the webkit target in the
133 'cflags!': ['-Wglobal-constructors'],
135 'WARNING_CFLAGS!': ['-Wglobal-constructors'],
142 ['incremental_chrome_dll==1', {
143 'UseLibraryDependencyInputs': "true",
151 '<(DEPTH)/build/linux/system.gyp:fontconfig',
154 '../../public/web/linux',
158 ['exclude', 'linux/'],
163 '<(DEPTH)/build/linux/system.gyp:x11',
166 '../../public/web/x11',
173 ['toolkit_uses_gtk == 1', {
175 '<(DEPTH)/build/linux/system.gyp:gtk',
178 '../../public/web/gtk',
180 }, { # else: toolkit_uses_gtk != 1
182 ['exclude', 'WebInputEventFactoryGtk.cpp$'],
187 '../../public/web/android',
188 '../../public/web/linux', # We need linux/WebFontRendering.h on Android.
190 }, { # else: OS!="android"
192 ['exclude', 'WebInputEventFactoryAndroid.cpp$'],
197 '../../public/web/mac',
201 '$(SDKROOT)/System/Library/Frameworks/Accelerate.framework',
202 '$(SDKROOT)/System/Library/Frameworks/OpenGL.framework',
205 }, { # else: OS!="mac"
207 ['exclude', 'WebInputEventFactoryMac.mm$'],
212 '../../public/web/win',
214 }, { # else: OS!="win"
216 ['exclude', 'WebInputEventFactoryWin.cpp$'],
219 ['use_default_render_theme==1', {
221 '../../public/web/default',
223 }, { # else use_default_render_theme==0
225 ['exclude', 'default/WebRenderTheme.cpp'],
229 'direct_dependent_settings': {
234 'target_conditions': [
237 ['include', '^linux/WebFontRendering\\.cpp$'],
238 ['include', '^linux/WebFontRenderStyle\\.cpp$'],
244 'target_name': 'webkit_test_support',
246 ['component=="shared_library"', {
249 'type': 'static_library',
251 '../config.gyp:config',
252 '../core/core.gyp:webcore_test_support',
253 '../modules/modules.gyp:modules_test_support',
254 '../wtf/wtf.gyp:wtf',
255 '<(DEPTH)/skia/skia.gyp:skia',
259 '../core/testing/v8', # for WebCoreTestSupport.h, needed to link in window.internals code.
263 'WebTestingSupport.cpp',
269 'target_name': 'picker_resources',
271 'hard_dependency': 1,
273 'make_file_arrays': 'scripts/make-file-arrays.py',
277 'action_name': 'PickerCommon',
280 'resources/pickerCommon.css',
281 'resources/pickerCommon.js',
285 '<(make_file_arrays)',
289 '<(SHARED_INTERMEDIATE_DIR)/blink/PickerCommon.h',
290 '<(SHARED_INTERMEDIATE_DIR)/blink/PickerCommon.cpp',
294 '<(make_file_arrays)',
295 '--out-h=<(SHARED_INTERMEDIATE_DIR)/blink/PickerCommon.h',
296 '--out-cpp=<(SHARED_INTERMEDIATE_DIR)/blink/PickerCommon.cpp',
301 'action_name': 'CalendarPicker',
304 'resources/calendarPicker.css',
305 'resources/calendarPicker.js',
306 'resources/pickerButton.css',
307 'resources/suggestionPicker.css',
308 'resources/suggestionPicker.js',
312 '<(make_file_arrays)',
316 '<(SHARED_INTERMEDIATE_DIR)/blink/CalendarPicker.h',
317 '<(SHARED_INTERMEDIATE_DIR)/blink/CalendarPicker.cpp',
321 '<(make_file_arrays)',
322 '--condition=ENABLE(CALENDAR_PICKER)',
323 '--out-h=<(SHARED_INTERMEDIATE_DIR)/blink/CalendarPicker.h',
324 '--out-cpp=<(SHARED_INTERMEDIATE_DIR)/blink/CalendarPicker.cpp',
329 'action_name': 'ColorSuggestionPicker',
332 'resources/colorSuggestionPicker.css',
333 'resources/colorSuggestionPicker.js',
337 '<(make_file_arrays)',
341 '<(SHARED_INTERMEDIATE_DIR)/blink/ColorSuggestionPicker.h',
342 '<(SHARED_INTERMEDIATE_DIR)/blink/ColorSuggestionPicker.cpp',
346 '<(make_file_arrays)',
347 '--out-h=<(SHARED_INTERMEDIATE_DIR)/blink/ColorSuggestionPicker.h',
348 '--out-cpp=<(SHARED_INTERMEDIATE_DIR)/blink/ColorSuggestionPicker.cpp',
356 ['gcc_version>=46', {
358 # Disable warnings about c++0x compatibility, as some names (such
359 # as nullptr) conflict with upcoming c++0x types.
360 'cflags_cc': ['-Wno-c++0x-compat'],
366 'target_name': 'copy_mesa',
368 'dependencies': ['<(DEPTH)/third_party/mesa/mesa.gyp:osmesa'],
370 'destination': '<(PRODUCT_DIR)/DumpRenderTree.app/Contents/MacOS/',
371 'files': ['<(PRODUCT_DIR)/osmesa.so'],
378 'cflags': ['-Wglobal-constructors'],
380 'WARNING_CFLAGS': ['-Wglobal-constructors'],