OLD | NEW |
| (Empty) |
1 # Copyright (c) 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. | |
4 | |
5 { | |
6 'variables': { | |
7 'chromium_code': 1, | |
8 }, | |
9 'targets': [ | |
10 { | |
11 'target_name': 'gfx_geometry', | |
12 'type': '<(component)', | |
13 'dependencies': [ | |
14 '<(DEPTH)/base/base.gyp:base', | |
15 ], | |
16 'includes': [ | |
17 'gfx_geometry.gypi', | |
18 '../../build/android/increase_size_for_speed.gypi', | |
19 ], | |
20 }, | |
21 { | |
22 # GN version: //ui/gfx/geometry/mojo | |
23 'target_name': 'mojo_geometry_bindings_mojom', | |
24 'type': 'none', | |
25 'variables': { | |
26 'mojom_files': [ | |
27 'geometry/mojo/geometry.mojom', | |
28 ], | |
29 'mojom_typemaps': [ | |
30 'geometry/mojo/geometry.typemap', | |
31 ], | |
32 'use_new_wrapper_types': 'false', | |
33 }, | |
34 'includes': [ '../../mojo/mojom_bindings_generator_explicit.gypi' ], | |
35 }, | |
36 { | |
37 # GN version: //ui/gfx/geometry/mojo | |
38 'target_name': 'mojo_geometry_bindings', | |
39 'type': 'static_library', | |
40 'dependencies': [ | |
41 'mojo_geometry_bindings_mojom', | |
42 '../../mojo/mojo_public.gyp:mojo_cpp_bindings', | |
43 ], | |
44 }, | |
45 { | |
46 'target_name': 'gfx_range', | |
47 'type': '<(component)', | |
48 'dependencies': [ | |
49 '<(DEPTH)/base/base.gyp:base', | |
50 ], | |
51 'defines': [ | |
52 'GFX_RANGE_IMPLEMENTATION', | |
53 ], | |
54 'sources': [ | |
55 'range/gfx_range_export.h', | |
56 'range/range.cc', | |
57 'range/range.h', | |
58 'range/range_f.cc', | |
59 'range/range_f.h', | |
60 'range/range_mac.mm', | |
61 'range/range_win.cc', | |
62 ], | |
63 'conditions': [ | |
64 ['OS=="win"', { | |
65 # TODO(jschuh): C4267: http://crbug.com/167187 size_t -> int | |
66 # C4324 is structure was padded due to __declspec(align()), which is | |
67 # uninteresting. | |
68 'msvs_disabled_warnings': [ 4267, 4324 ], | |
69 }], | |
70 ] | |
71 }, | |
72 { | |
73 'target_name': 'gfx', | |
74 'type': '<(component)', | |
75 'dependencies': [ | |
76 '<(DEPTH)/base/base.gyp:base', | |
77 '<(DEPTH)/base/base.gyp:base_i18n', | |
78 '<(DEPTH)/base/base.gyp:base_static', | |
79 '<(DEPTH)/base/third_party/dynamic_annotations/dynamic_annotations.gyp:d
ynamic_annotations', | |
80 '<(DEPTH)/skia/skia.gyp:skia', | |
81 '<(DEPTH)/third_party/harfbuzz-ng/harfbuzz.gyp:harfbuzz-ng', | |
82 '<(DEPTH)/third_party/icu/icu.gyp:icui18n', | |
83 '<(DEPTH)/third_party/icu/icu.gyp:icuuc', | |
84 '<(DEPTH)/third_party/libpng/libpng.gyp:libpng', | |
85 '<(DEPTH)//third_party/qcms/qcms.gyp:qcms', | |
86 '<(DEPTH)/third_party/zlib/zlib.gyp:zlib', | |
87 'gfx_geometry', | |
88 'gfx_range', | |
89 ], | |
90 # text_elider.h includes ICU headers. | |
91 'export_dependent_settings': [ | |
92 '<(DEPTH)/skia/skia.gyp:skia', | |
93 '<(DEPTH)/third_party/icu/icu.gyp:icui18n', | |
94 '<(DEPTH)/third_party/icu/icu.gyp:icuuc', | |
95 ], | |
96 'defines': [ | |
97 'GFX_IMPLEMENTATION', | |
98 ], | |
99 'include_dirs': [ | |
100 '<(DEPTH)/third_party/icu/source/common', | |
101 ], | |
102 'sources': [ | |
103 'android/device_display_info.cc', | |
104 'android/device_display_info.h', | |
105 'android/gfx_jni_registrar.cc', | |
106 'android/gfx_jni_registrar.h', | |
107 'android/java_bitmap.cc', | |
108 'android/java_bitmap.h', | |
109 'android/shared_device_display_info.cc', | |
110 'android/shared_device_display_info.h', | |
111 'android/view_configuration.cc', | |
112 'android/view_configuration.h', | |
113 'animation/animation.cc', | |
114 'animation/animation.h', | |
115 'animation/animation_container.cc', | |
116 'animation/animation_container.h', | |
117 'animation/animation_container_element.h', | |
118 'animation/animation_container_observer.h', | |
119 'animation/animation_delegate.h', | |
120 'animation/animation_mac.mm', | |
121 'animation/animation_win.cc', | |
122 'animation/linear_animation.cc', | |
123 'animation/linear_animation.h', | |
124 'animation/multi_animation.cc', | |
125 'animation/multi_animation.h', | |
126 'animation/slide_animation.cc', | |
127 'animation/slide_animation.h', | |
128 'animation/throb_animation.cc', | |
129 'animation/throb_animation.h', | |
130 'animation/tween.cc', | |
131 'animation/tween.h', | |
132 'blit.cc', | |
133 'blit.h', | |
134 'break_list.h', | |
135 'break_list.h', | |
136 'buffer_format_util.cc', | |
137 'buffer_format_util.h', | |
138 'canvas.cc', | |
139 'canvas.h', | |
140 'canvas_notimplemented.cc', | |
141 'canvas_paint_mac.h', | |
142 'canvas_paint_mac.mm', | |
143 'canvas_skia.cc', | |
144 'canvas_skia_paint.h', | |
145 'codec/jpeg_codec.cc', | |
146 'codec/jpeg_codec.h', | |
147 'codec/png_codec.cc', | |
148 'codec/png_codec.h', | |
149 'color_analysis.cc', | |
150 'color_analysis.h', | |
151 'color_palette.h', | |
152 'color_space.cc', | |
153 'color_space.h', | |
154 'color_transform.cc', | |
155 'color_transform.h', | |
156 'color_utils.cc', | |
157 'color_utils.h', | |
158 'favicon_size.cc', | |
159 'favicon_size.h', | |
160 'font.cc', | |
161 'font.h', | |
162 'font_fallback.h', | |
163 'font_fallback_linux.cc', | |
164 'font_fallback_linux.h', | |
165 'font_fallback_mac.mm', | |
166 'font_fallback_win.cc', | |
167 'font_fallback_win.h', | |
168 'font_list.cc', | |
169 'font_list.h', | |
170 'font_list_impl.cc', | |
171 'font_list_impl.h', | |
172 'font_render_params.cc', | |
173 'font_render_params.h', | |
174 'font_render_params_android.cc', | |
175 'font_render_params_linux.cc', | |
176 'font_render_params_mac.cc', | |
177 'font_render_params_win.cc', | |
178 'generic_shared_memory_id.cc', | |
179 'generic_shared_memory_id.h', | |
180 'gfx_export.h', | |
181 'gfx_paths.cc', | |
182 'gfx_paths.h', | |
183 'harfbuzz_font_skia.cc', | |
184 'harfbuzz_font_skia.h', | |
185 'image/canvas_image_source.cc', | |
186 'image/canvas_image_source.h', | |
187 'icc_profile.cc', | |
188 'icc_profile.h', | |
189 'icc_profile_mac.mm', | |
190 'icc_profile_win.cc', | |
191 'image/image.cc', | |
192 'image/image.h', | |
193 'image/image_family.cc', | |
194 'image/image_family.h', | |
195 'image/image_ios.mm', | |
196 'image/image_mac.mm', | |
197 'image/image_png_rep.cc', | |
198 'image/image_png_rep.h', | |
199 'image/image_skia.cc', | |
200 'image/image_skia.h', | |
201 'image/image_skia_operations.cc', | |
202 'image/image_skia_operations.h', | |
203 'image/image_skia_rep.cc', | |
204 'image/image_skia_rep.h', | |
205 'image/image_skia_source.cc', | |
206 'image/image_skia_source.h', | |
207 'image/image_skia_util_ios.h', | |
208 'image/image_skia_util_ios.mm', | |
209 'image/image_skia_util_mac.h', | |
210 'image/image_skia_util_mac.mm', | |
211 'image/image_util.cc', | |
212 'image/image_util.h', | |
213 'image/image_util_ios.mm', | |
214 'interpolated_transform.cc', | |
215 'interpolated_transform.h', | |
216 'ios/NSString+CrStringDrawing.h', | |
217 'ios/NSString+CrStringDrawing.mm', | |
218 'ios/uikit_util.h', | |
219 'ios/uikit_util.mm', | |
220 'linux_font_delegate.cc', | |
221 'linux_font_delegate.h', | |
222 'mac/coordinate_conversion.h', | |
223 'mac/coordinate_conversion.mm', | |
224 'mac/io_surface.cc', | |
225 'mac/io_surface.h', | |
226 'mac/nswindow_frame_controls.h', | |
227 'mac/nswindow_frame_controls.mm', | |
228 'mac/scoped_cocoa_disable_screen_updates.h', | |
229 'native_pixmap_handle_ozone.cc', | |
230 'native_pixmap_handle_ozone.h', | |
231 'native_widget_types.h', | |
232 'nine_image_painter.cc', | |
233 'nine_image_painter.h', | |
234 'overlay_transform.h', | |
235 'paint_throbber.cc', | |
236 'paint_throbber.h', | |
237 'path.cc', | |
238 'path.h', | |
239 'path_mac.h', | |
240 'path_mac.mm', | |
241 'path_win.cc', | |
242 'path_win.h', | |
243 'path_x11.cc', | |
244 'path_x11.h', | |
245 'platform_font.h', | |
246 'platform_font_android.cc', | |
247 'platform_font_ios.h', | |
248 'platform_font_ios.mm', | |
249 'platform_font_linux.cc', | |
250 'platform_font_linux.h', | |
251 'platform_font_mac.h', | |
252 'platform_font_mac.mm', | |
253 'platform_font_win.cc', | |
254 'platform_font_win.h', | |
255 'render_text.cc', | |
256 'render_text.h', | |
257 'render_text_harfbuzz.cc', | |
258 'render_text_harfbuzz.h', | |
259 'render_text_mac.h', | |
260 'render_text_mac.mm', | |
261 'scoped_canvas.cc', | |
262 'scoped_canvas.h', | |
263 'scoped_cg_context_save_gstate_mac.h', | |
264 'scoped_ns_graphics_context_save_gstate_mac.h', | |
265 'scoped_ns_graphics_context_save_gstate_mac.mm', | |
266 'scoped_ui_graphics_push_context_ios.h', | |
267 'scoped_ui_graphics_push_context_ios.mm', | |
268 'scrollbar_size.cc', | |
269 'scrollbar_size.h', | |
270 'selection_bound.cc', | |
271 'selection_bound.h', | |
272 'selection_model.cc', | |
273 'selection_model.h', | |
274 'sequential_id_generator.cc', | |
275 'sequential_id_generator.h', | |
276 'shadow_value.cc', | |
277 'shadow_value.h', | |
278 'skbitmap_operations.cc', | |
279 'skbitmap_operations.h', | |
280 'skia_util.cc', | |
281 'skia_util.h', | |
282 'swap_result.h', | |
283 'switches.cc', | |
284 'switches.h', | |
285 'text_constants.h', | |
286 'text_elider.cc', | |
287 'text_elider.h', | |
288 'text_utils.cc', | |
289 'text_utils.h', | |
290 'text_utils_android.cc', | |
291 'text_utils_ios.mm', | |
292 'text_utils_skia.cc', | |
293 'transform.cc', | |
294 'transform.h', | |
295 'transform_util.cc', | |
296 'transform_util.h', | |
297 'ui_gfx_exports.cc', | |
298 'utf16_indexing.cc', | |
299 'utf16_indexing.h', | |
300 'vsync_provider.h', | |
301 'win/direct_manipulation.cc', | |
302 'win/direct_manipulation.h', | |
303 'win/direct_write.cc', | |
304 'win/direct_write.h', | |
305 'win/hwnd_util.cc', | |
306 'win/hwnd_util.h', | |
307 "win/physical_size.cc", | |
308 "win/physical_size.h", | |
309 'win/rendering_window_manager.cc', | |
310 'win/rendering_window_manager.h', | |
311 'win/scoped_set_map_mode.h', | |
312 'win/singleton_hwnd.cc', | |
313 'win/singleton_hwnd.h', | |
314 'win/singleton_hwnd_observer.cc', | |
315 'win/singleton_hwnd_observer.h', | |
316 'win/text_analysis_source.cc', | |
317 'win/text_analysis_source.h', | |
318 'win/window_impl.cc', | |
319 'win/window_impl.h', | |
320 ], | |
321 'includes': [ | |
322 '../../build/android/increase_size_for_speed.gypi', | |
323 ], | |
324 'conditions': [ | |
325 ['OS=="ios"', { | |
326 # Linkable dependents need to set the linker flag '-ObjC' in order to | |
327 # use the categories in this target (e.g. NSString+CrStringDrawing.h). | |
328 'link_settings': { | |
329 'xcode_settings': {'OTHER_LDFLAGS': ['-ObjC']}, | |
330 }, | |
331 'sources!': [ | |
332 'blit.cc', | |
333 'blit.h', | |
334 'canvas.cc', | |
335 'canvas.h', | |
336 'canvas_notimplemented.cc', | |
337 'canvas_paint_mac.h', | |
338 'canvas_paint_mac.mm', | |
339 'canvas_skia.cc', | |
340 'canvas_skia_paint.h', | |
341 'codec/jpeg_codec.cc', | |
342 ], | |
343 }, { | |
344 'sources':[ | |
345 'gpu_memory_buffer.cc', | |
346 'gpu_memory_buffer.h', | |
347 ], | |
348 'dependencies': [ | |
349 '<(libjpeg_gyp_path):libjpeg', | |
350 ], | |
351 }], | |
352 # TODO(asvitkine): Switch all platforms to use canvas_skia.cc. | |
353 # http://crbug.com/105550 | |
354 ['use_canvas_skia==1', { | |
355 'sources!': [ | |
356 'canvas_notimplemented.cc', | |
357 ], | |
358 }, { # use_canvas_skia!=1 | |
359 'sources!': [ | |
360 'canvas_skia.cc', | |
361 ], | |
362 }], | |
363 ['OS=="win"', { | |
364 'sources': [ | |
365 'gdi_util.cc', | |
366 'gdi_util.h', | |
367 'icon_util.cc', | |
368 'icon_util.h', | |
369 'sys_color_change_listener.cc', | |
370 'sys_color_change_listener.h', | |
371 ], | |
372 # TODO(jschuh): C4267: http://crbug.com/167187 size_t -> int | |
373 # C4324 is structure was padded due to __declspec(align()), which is | |
374 # uninteresting. | |
375 'msvs_disabled_warnings': [ 4267, 4324 ], | |
376 }], | |
377 ['OS=="mac"', { | |
378 'link_settings': { | |
379 'libraries': [ | |
380 '$(SDKROOT)/System/Library/Frameworks/IOSurface.framework', | |
381 ], | |
382 }, | |
383 }], | |
384 ['OS=="android"', { | |
385 'sources!': [ | |
386 'animation/throb_animation.cc', | |
387 'selection_model.cc', | |
388 ], | |
389 'dependencies': [ | |
390 'gfx_jni_headers', | |
391 '<(DEPTH)/base/base.gyp:base_java', | |
392 ], | |
393 'link_settings': { | |
394 'libraries': [ | |
395 '-landroid', | |
396 '-ljnigraphics', | |
397 ], | |
398 }, | |
399 }], | |
400 ['chromeos==1', { | |
401 # Chrome OS requires robust JPEG decoding for the login screen. | |
402 'sources': [ | |
403 'chromeos/codec/jpeg_codec_robust_slow.cc', | |
404 'chromeos/codec/jpeg_codec_robust_slow.h', | |
405 ], | |
406 'dependencies': [ | |
407 '<(libjpeg_ijg_gyp_path):libjpeg', | |
408 ], | |
409 }], | |
410 ['use_aura==0 and toolkit_views==0', { | |
411 'sources!': [ | |
412 'nine_image_painter.cc', | |
413 'nine_image_painter.h', | |
414 ], | |
415 }], | |
416 ['OS=="android" and use_aura==0', { | |
417 'sources!': [ | |
418 'path.cc', | |
419 ], | |
420 }], | |
421 ['OS=="android" or OS=="ios"', { | |
422 'sources!': [ | |
423 'harfbuzz_font_skia.cc', | |
424 'harfbuzz_font_skia.h', | |
425 'render_text.cc', | |
426 'render_text.h', | |
427 'render_text_harfbuzz.cc', | |
428 'render_text_harfbuzz.h', | |
429 'text_utils_skia.cc', | |
430 ], | |
431 }, { # desktop platforms | |
432 }], | |
433 ['use_x11==1', { | |
434 'dependencies': [ | |
435 '../../build/linux/system.gyp:x11', | |
436 'x/gfx_x11.gyp:gfx_x11', | |
437 ], | |
438 }], | |
439 ['use_cairo==1', { | |
440 'dependencies': [ | |
441 '<(DEPTH)/build/linux/system.gyp:pangocairo', | |
442 ], | |
443 }], | |
444 ['desktop_linux==1 or chromeos==1', { | |
445 'dependencies': [ | |
446 # font_render_params_linux.cc uses fontconfig | |
447 '<(DEPTH)/build/linux/system.gyp:fontconfig', | |
448 ], | |
449 }], | |
450 ], | |
451 'target_conditions': [ | |
452 # Need 'target_conditions' to override default filename_rules to include | |
453 # the file on iOS. | |
454 ['OS == "ios"', { | |
455 'sources/': [ | |
456 ['include', '^scoped_cg_context_save_gstate_mac\\.h$'], | |
457 ], | |
458 }], | |
459 ], | |
460 }, | |
461 # Separate from gfx to limit the impact of the hard_dependency. | |
462 { | |
463 'target_name': 'gfx_vector_icons', | |
464 'type': '<(component)', | |
465 'dependencies': [ | |
466 '<(DEPTH)/base/base.gyp:base', | |
467 '<(DEPTH)/base/base.gyp:base_i18n', | |
468 '<(DEPTH)/skia/skia.gyp:skia', | |
469 'gfx', | |
470 'gfx_geometry', | |
471 ], | |
472 'defines': [ | |
473 'GFX_IMPLEMENTATION', | |
474 ], | |
475 'sources': [ | |
476 'paint_vector_icon.cc', | |
477 'paint_vector_icon.h', | |
478 'vector_icons_public.h', | |
479 ], | |
480 'variables': { | |
481 'vector_icons_cc_file': '<(INTERMEDIATE_DIR)/ui/gfx/vector_icons.cc', | |
482 'vector_icons_h_file': '<(SHARED_INTERMEDIATE_DIR)/ui/gfx/vector_icons.h
', | |
483 }, | |
484 'include_dirs': [ | |
485 '<(SHARED_INTERMEDIATE_DIR)', | |
486 ], | |
487 'actions': [ | |
488 { | |
489 # GN version: //ui/gfx:aggregate_vector_icons | |
490 'action_name': 'aggregate_vector_icons', | |
491 'inputs': [ | |
492 'vector_icons/', | |
493 ], | |
494 'outputs': [ | |
495 '<(vector_icons_cc_file)', | |
496 '<(vector_icons_h_file)', | |
497 ], | |
498 'action': [ 'python', | |
499 'vector_icons/aggregate_vector_icons.py', | |
500 '--working_directory=vector_icons/', | |
501 '--output_cc=<(vector_icons_cc_file)', | |
502 '--output_h=<(vector_icons_h_file)', | |
503 ], | |
504 'message': 'Aggregating vector resources.', | |
505 'process_outputs_as_sources': 1, | |
506 }, | |
507 ], | |
508 # Export a hard dependency because of generated header files. | |
509 'hard_dependency': 1, | |
510 }, | |
511 { | |
512 'target_name': 'gfx_test_support', | |
513 'type': 'static_library', | |
514 'sources': [ | |
515 'image/image_unittest_util.cc', | |
516 'image/image_unittest_util.h', | |
517 'image/image_unittest_util_ios.mm', | |
518 'image/image_unittest_util_mac.mm', | |
519 'test/fontconfig_util_linux.cc', | |
520 'test/fontconfig_util_linux.h', | |
521 'test/gfx_util.cc', | |
522 'test/gfx_util.h', | |
523 'test/ui_cocoa_test_helper.h', | |
524 'test/ui_cocoa_test_helper.mm', | |
525 ], | |
526 'dependencies': [ | |
527 '../../base/base.gyp:base', | |
528 '../../skia/skia.gyp:skia', | |
529 '../../testing/gtest.gyp:gtest', | |
530 'gfx', | |
531 'gfx_geometry', | |
532 ], | |
533 'conditions': [ | |
534 ['OS == "mac"', { | |
535 'link_settings': { | |
536 'libraries': [ | |
537 '$(SDKROOT)/System/Library/Frameworks/AppKit.framework', | |
538 ], | |
539 }, | |
540 }], | |
541 ['OS=="ios"', { | |
542 # The cocoa files don't apply to iOS. | |
543 'sources/': [ | |
544 ['exclude', 'cocoa'] | |
545 ], | |
546 }], | |
547 ['OS=="linux"', { | |
548 'dependencies': [ | |
549 '../../build/linux/system.gyp:fontconfig', | |
550 ], | |
551 }], | |
552 ], | |
553 }, | |
554 ], | |
555 'conditions': [ | |
556 ['OS=="android"' , { | |
557 'targets': [ | |
558 { | |
559 'target_name': 'gfx_jni_headers', | |
560 'type': 'none', | |
561 'sources': [ | |
562 '../android/java/src/org/chromium/ui/gfx/BitmapHelper.java', | |
563 '../android/java/src/org/chromium/ui/gfx/DeviceDisplayInfo.java', | |
564 '../android/java/src/org/chromium/ui/gfx/ViewConfigurationHelper.java
', | |
565 ], | |
566 'variables': { | |
567 'jni_gen_package': 'ui/gfx', | |
568 }, | |
569 'includes': [ '../../build/jni_generator.gypi' ], | |
570 }, | |
571 ], | |
572 }], | |
573 ['disable_nacl!=1 and OS=="win" and target_arch=="ia32"', { | |
574 'targets': [ | |
575 { | |
576 'target_name': 'gfx_geometry_win64', | |
577 'type': '<(component)', | |
578 'dependencies': [ | |
579 '<(DEPTH)/base/base.gyp:base_win64', | |
580 ], | |
581 'includes': [ | |
582 'gfx_geometry.gypi', | |
583 ], | |
584 'defines': [ | |
585 '<@(nacl_win64_defines)', | |
586 ], | |
587 'configurations': { | |
588 'Common_Base': { | |
589 'msvs_target_platform': 'x64', | |
590 }, | |
591 }, | |
592 }, | |
593 ], | |
594 }], | |
595 ], | |
596 } | |
OLD | NEW |