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',
34 '../build/features.gypi',
35 '../build/scripts/scripts.gypi',
37 '../modules/modules.gypi',
38 '../platform/blink_platform.gypi',
44 # GN version: //third_party/WebKit/Source/web:webkit_unit_tests
45 'target_name': 'webkit_unit_tests',
47 'variables': { 'enable_wexit_time_destructors': 1, },
49 '../../public/blink.gyp:blink',
50 '../config.gyp:unittest_config',
51 '../wtf/wtf_tests.gyp:wtf_unittest_helpers',
52 'web.gyp:blink_web_test_support',
53 '<(DEPTH)/base/base.gyp:base',
54 '<(DEPTH)/base/base.gyp:base_i18n',
55 '<(DEPTH)/base/base.gyp:test_support_base',
56 '<(DEPTH)/testing/gmock.gyp:gmock',
57 '<(DEPTH)/testing/gtest.gyp:gtest',
58 '<(DEPTH)/third_party/libwebp/libwebp.gyp:libwebp',
59 '<(DEPTH)/third_party/zlib/zlib.gyp:zlib',
60 '<(DEPTH)/url/url.gyp:url_lib',
61 '<(DEPTH)/v8/tools/gyp/v8.gyp:v8',
62 '<(DEPTH)/content/content_shell_and_tests.gyp:test_support_content',
65 '../web/tests/RunAllTests.cpp',
73 ['component!="shared_library"', {
75 '../core/core.gyp:webcore',
78 'BLINK_IMPLEMENTATION=1',
82 '<@(bindings_unittest_files)',
83 '<@(core_unittest_files)',
84 '<@(modules_unittest_files)',
85 '<@(platform_web_unittest_files)',
86 '<@(web_unittest_files)',
89 ['OS=="win" and component!="shared_library"', {
94 'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
100 ['win_use_allocator_shim==1', {
102 '<(DEPTH)/base/allocator/allocator.gyp:allocator',
108 'type': 'shared_library',
110 '<(DEPTH)/testing/android/native_test.gyp:native_test_native_code',
111 '<(DEPTH)/tools/android/forwarder2/forwarder.gyp:forwarder2',
116 '../../public/web/mac',
119 [ 'os_posix==1 and OS!="mac" and OS!="android" and OS!="ios" and use_allocator!="none"', {
121 '<(DEPTH)/base/allocator/allocator.gyp:allocator',
128 ['gcc_version>=46', {
130 # Disable warnings about c++0x compatibility, as some names (such
131 # as nullptr) conflict with upcoming c++0x types.
132 'cflags_cc': ['-Wno-c++0x-compat'],
135 ['OS=="android" and android_webview_build==0 and gtest_target_type == "shared_library"', {
136 # Wrap libwebkit_unit_tests.so into an android apk for execution.
138 'target_name': 'webkit_unit_tests_apk',
141 '<(DEPTH)/base/base.gyp:base_java',
142 '<(DEPTH)/net/net.gyp:net_java',
146 'test_suite_name': 'webkit_unit_tests',
147 'input_shlib_path': '<(SHARED_LIB_DIR)/<(SHARED_LIB_PREFIX)webkit_unit_tests<(SHARED_LIB_SUFFIX)',
148 'additional_input_paths': ['<(PRODUCT_DIR)/content_shell/assets/content_shell.pak'],
149 'asset_location': '<(PRODUCT_DIR)/content_shell/assets',
151 'includes': [ '../../../../build/apk_test.gypi' ],