Refactor the way enhanced bookmark gets large icons
[chromium-blink-merge.git] / url / url.gyp
blobb8355a87ddc9062fc69542989db95500e26affce
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   'variables': {
7     'chromium_code': 1,
8   },
9   'includes': [
10     'url_srcs.gypi',
11   ],
12   'targets': [
13     {
14       # Note, this target_name cannot be 'url', because that will generate
15       # 'url.dll' for a Windows component build, and that will confuse Windows,
16       # which has a system DLL with the same name.
17       'target_name': 'url_lib',
18       'type': '<(component)',
19       'dependencies': [
20         '../base/base.gyp:base',
21         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
22         '../third_party/icu/icu.gyp:icui18n',
23         '../third_party/icu/icu.gyp:icuuc',
24       ],
25       'sources': [
26         '<@(gurl_sources)',
27       ],
28       'direct_dependent_settings': {
29         'include_dirs': [
30           '..',
31         ],
32       },
33       'defines': [
34         'URL_IMPLEMENTATION',
35       ],
36       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
37       'msvs_disabled_warnings': [4267, ],
38     },
39     {
40       'target_name': 'url_unittests',
41       'type': 'executable',
42       'dependencies': [
43         '../base/base.gyp:run_all_unittests',
44         '../testing/gtest.gyp:gtest',
45         '../third_party/icu/icu.gyp:icuuc',
46         'url_lib',
47       ],
48       'sources': [
49         'deprecated_serialized_origin_unittest.cc',
50         'gurl_unittest.cc',
51         'origin_unittest.cc',
52         'scheme_host_port_unittest.cc',
53         'url_canon_icu_unittest.cc',
54         'url_canon_unittest.cc',
55         'url_parse_unittest.cc',
56         'url_test_utils.h',
57         'url_util_unittest.cc',
58       ],
59       'conditions': [
60         ['os_posix==1 and OS!="mac" and OS!="ios" and use_allocator!="none"',
61           {
62             'dependencies': [
63               '../base/allocator/allocator.gyp:allocator',
64             ],
65           }
66         ],
67       ],
68       # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
69       'msvs_disabled_warnings': [4267, ],
70     },
71   ],
72   'conditions': [
73     ['OS=="android"', {
74       'targets': [
75         {
76           'target_name': 'url_jni_headers',
77           'type': 'none',
78           'sources': [
79             'android/java/src/org/chromium/url/IDNStringUtil.java'
80           ],
81           'variables': {
82             'jni_gen_package': 'url',
83           },
84           'includes': [ '../build/jni_generator.gypi' ],
85         },
86         {
87           'target_name': 'url_java',
88           'type': 'none',
89           'variables': {
90             'java_in_dir': '../url/android/java',
91           },
92           'dependencies': [
93             '../base/base.gyp:base',
94           ],
95           'includes': [ '../build/java.gypi' ],
96         },
97         {
98           # Same as url_lib but using ICU alternatives on Android.
99           'target_name': 'url_lib_use_icu_alternatives_on_android',
100           'type': '<(component)',
101           'dependencies': [
102             '../base/base.gyp:base',
103             '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
104             'url_java',
105             'url_jni_headers',
106           ],
107           'sources': [
108             '<@(gurl_sources)',
109             'url_canon_icu_alternatives_android.cc',
110             'url_canon_icu_alternatives_android.h',
111           ],
112           'sources!': [
113             'url_canon_icu.cc',
114             'url_canon_icu.h',
115           ],
116           'direct_dependent_settings': {
117             'include_dirs': [
118               '..',
119             ],
120           },
121           'defines': [
122             'URL_IMPLEMENTATION',
123             'USE_ICU_ALTERNATIVES_ON_ANDROID=1',
124           ],
125         },
126       ],
127     }],
128     ['test_isolation_mode != "noop"', {
129       'targets': [
130         {
131           'target_name': 'url_unittests_run',
132           'type': 'none',
133           'dependencies': [
134             'url_unittests',
135           ],
136           'includes': [
137             '../build/isolate.gypi',
138           ],
139           'sources': [
140             'url_unittests.isolate',
141           ],
142         },
143       ],
144     }],
145   ],