OLD | NEW |
| (Empty) |
1 # Copyright (c) 2011 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. | |
4 | |
5 { | |
6 'variables': { | |
7 'chromium_code': 1, | |
8 'grit_info_cmd': ['python', '../tools/grit/grit_info.py', | |
9 '<@(grit_defines)'], | |
10 'grit_cmd': ['python', '../tools/grit/grit.py'], | |
11 'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/gfx', | |
12 }, | |
13 'targets': [ | |
14 { | |
15 'target_name': 'gfx_unittests', | |
16 'type': 'executable', | |
17 'msvs_guid': 'C8BD2821-EAE5-4AC6-A0E4-F82CAC2956CC', | |
18 'dependencies': [ | |
19 'gfx', | |
20 'gfx_resources', | |
21 '../base/base.gyp:test_support_base', | |
22 '../skia/skia.gyp:skia', | |
23 '../testing/gtest.gyp:gtest', | |
24 ], | |
25 'sources': [ | |
26 'blit_unittest.cc', | |
27 'codec/jpeg_codec_unittest.cc', | |
28 'codec/png_codec_unittest.cc', | |
29 'color_utils_unittest.cc', | |
30 'font_unittest.cc', | |
31 'insets_unittest.cc', | |
32 'rect_unittest.cc', | |
33 'run_all_unittests.cc', | |
34 'scoped_image_unittest.cc', | |
35 'skbitmap_operations_unittest.cc', | |
36 'test_suite.cc', | |
37 'test_suite.h', | |
38 '<(SHARED_INTERMEDIATE_DIR)/gfx/gfx_resources.rc', | |
39 ], | |
40 'include_dirs': [ | |
41 '..', | |
42 ], | |
43 'conditions': [ | |
44 ['OS=="win"', { | |
45 'sources': [ | |
46 # TODO(brettw) re-enable this when the dependencies on WindowImpl ar
e fixed! | |
47 'canvas_direct2d_unittest.cc', | |
48 'icon_util_unittest.cc', | |
49 'native_theme_win_unittest.cc', | |
50 ], | |
51 'include_dirs': [ | |
52 '..', | |
53 '<(DEPTH)/third_party/wtl/include', | |
54 ], | |
55 'msvs_settings': { | |
56 'VCLinkerTool': { | |
57 'DelayLoadDLLs': [ | |
58 'd2d1.dll', | |
59 'd3d10_1.dll', | |
60 ], | |
61 'AdditionalDependencies': [ | |
62 'd2d1.lib', | |
63 'd3d10_1.lib', | |
64 ], | |
65 }, | |
66 } | |
67 }], | |
68 ['OS=="linux" or OS=="freebsd" or OS=="openbsd"', { | |
69 'dependencies': [ | |
70 '../build/linux/system.gyp:gtk', | |
71 ], | |
72 }], | |
73 ], | |
74 }, | |
75 { | |
76 'target_name': 'gfx', | |
77 'type': '<(library)', | |
78 'msvs_guid': '13A8D36C-0467-4B4E-BAA3-FD69C45F076A', | |
79 'dependencies': [ | |
80 '../base/base.gyp:base', | |
81 '../base/base.gyp:base_i18n', | |
82 '../skia/skia.gyp:skia', | |
83 '../third_party/icu/icu.gyp:icui18n', | |
84 '../third_party/icu/icu.gyp:icuuc', | |
85 '../third_party/libpng/libpng.gyp:libpng', | |
86 '../third_party/zlib/zlib.gyp:zlib', | |
87 'gfx_resources', | |
88 '<(libjpeg_gyp_path):libjpeg', | |
89 ], | |
90 'sources': [ | |
91 'blit.cc', | |
92 'blit.h', | |
93 'brush.h', | |
94 'canvas.cc', | |
95 'canvas.h', | |
96 'canvas_skia.h', | |
97 'canvas_skia.cc', | |
98 'canvas_skia_linux.cc', | |
99 'canvas_skia_mac.mm', | |
100 'canvas_skia_paint.h', | |
101 'canvas_skia_win.cc', | |
102 'codec/jpeg_codec.cc', | |
103 'codec/jpeg_codec.h', | |
104 'codec/png_codec.cc', | |
105 'codec/png_codec.h', | |
106 'color_utils.cc', | |
107 'color_utils.h', | |
108 'favicon_size.h', | |
109 'font.h', | |
110 'font.cc', | |
111 'gfx_paths.cc', | |
112 'gfx_paths.h', | |
113 'gfx_module.cc', | |
114 'gfx_module.h', | |
115 'insets.cc', | |
116 'insets.h', | |
117 'native_widget_types.h', | |
118 'path.cc', | |
119 'path.h', | |
120 'path_gtk.cc', | |
121 'path_win.cc', | |
122 'platform_font.h', | |
123 'platform_font_gtk.h', | |
124 'platform_font_gtk.cc', | |
125 'platform_font_mac.h', | |
126 'platform_font_mac.mm', | |
127 'platform_font_win.h', | |
128 'platform_font_win.cc', | |
129 'point.cc', | |
130 'point.h', | |
131 'rect.cc', | |
132 'rect.h', | |
133 'scoped_cg_context_state_mac.h', | |
134 'scoped_image.h', | |
135 'scrollbar_size.cc', | |
136 'scrollbar_size.h', | |
137 'size.cc', | |
138 'size.h', | |
139 'skbitmap_operations.cc', | |
140 'skbitmap_operations.h', | |
141 'skia_util.cc', | |
142 'skia_util.h', | |
143 'skia_utils_gtk.cc', | |
144 'skia_utils_gtk.h', | |
145 ], | |
146 'conditions': [ | |
147 ['OS=="win"', { | |
148 'sources': [ | |
149 'canvas_direct2d.cc', | |
150 'canvas_direct2d.h', | |
151 'gdi_util.cc', | |
152 'gdi_util.h', | |
153 'icon_util.cc', | |
154 'icon_util.h', | |
155 'native_theme_win.cc', | |
156 'native_theme_win.h', | |
157 'win_util.cc', | |
158 'win_util.h', | |
159 ], | |
160 'include_dirs': [ | |
161 '..', | |
162 '<(DEPTH)/third_party/wtl/include', | |
163 ], | |
164 }], | |
165 ['OS=="linux" or OS=="freebsd" or OS=="openbsd"', { | |
166 'dependencies': [ | |
167 # font_gtk.cc uses fontconfig. | |
168 # TODO(evanm): I think this is wrong; it should just use GTK. | |
169 '../build/linux/system.gyp:fontconfig', | |
170 '../build/linux/system.gyp:gtk', | |
171 ], | |
172 'sources': [ | |
173 'gtk_native_view_id_manager.cc', | |
174 'gtk_native_view_id_manager.h', | |
175 'gtk_preserve_window.cc', | |
176 'gtk_preserve_window.h', | |
177 'gtk_util.cc', | |
178 'gtk_util.h', | |
179 'native_theme_linux.cc', | |
180 'native_theme_linux.h', | |
181 'native_widget_types_gtk.cc', | |
182 ], | |
183 }], | |
184 ], | |
185 }, | |
186 { | |
187 # theme_resources also generates a .cc file, so it can't use the rules abo
ve. | |
188 'target_name': 'gfx_resources', | |
189 'type': 'none', | |
190 'msvs_guid' : '5738AE53-E919-4987-A2EF-15FDBD8F90F6', | |
191 'actions': [ | |
192 { | |
193 'action_name': 'gfx_resources', | |
194 'variables': { | |
195 'input_path': 'gfx_resources.grd', | |
196 }, | |
197 'inputs': [ | |
198 '<!@(<(grit_info_cmd) --inputs <(input_path))', | |
199 ], | |
200 'outputs': [ | |
201 '<!@(<(grit_info_cmd) --outputs \'<(grit_out_dir)\' <(input_path))', | |
202 ], | |
203 'action': [ | |
204 '<@(grit_cmd)', | |
205 '-i', '<(input_path)', 'build', | |
206 '-o', '<(grit_out_dir)', | |
207 '<@(grit_defines)', | |
208 ], | |
209 'message': 'Generating resources from <(input_path)', | |
210 }, | |
211 ], | |
212 'direct_dependent_settings': { | |
213 'include_dirs': [ | |
214 '<(grit_out_dir)', | |
215 ], | |
216 }, | |
217 'conditions': [ | |
218 ['OS=="win"', { | |
219 'dependencies': ['../build/win/system.gyp:cygwin'], | |
220 }], | |
221 ], | |
222 }, | |
223 | |
224 ], | |
225 } | |
226 | |
227 # Local Variables: | |
228 # tab-width:2 | |
229 # indent-tabs-mode:nil | |
230 # End: | |
231 # vim: set expandtab tabstop=2 shiftwidth=2: | |
OLD | NEW |