Home | History | Annotate | Download | only in snapshot
      1 # Copyright (c) 2012 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': 'snapshot',
     12       'type': '<(component)',
     13       'dependencies': [
     14         '../../base/base.gyp:base',
     15         '../../skia/skia.gyp:skia',
     16         '../base/ui_base.gyp:ui_base',
     17         '../gfx/gfx.gyp:gfx',
     18         '../gfx/gfx.gyp:gfx_geometry',
     19       ],
     20       'defines': [
     21         'SNAPSHOT_IMPLEMENTATION',
     22       ],
     23       'sources': [
     24         'snapshot.h',
     25         'snapshot_android.cc',
     26         'snapshot_async.cc',
     27         'snapshot_async.h',
     28         'snapshot_aura.cc',
     29         'snapshot_export.h',
     30         'snapshot_ios.mm',
     31         'snapshot_mac.mm',
     32         'snapshot_win.cc',
     33         'snapshot_win.h',
     34       ],
     35       'include_dirs': [
     36         '..',
     37       ],
     38       'conditions': [
     39         ['use_aura==1 or OS=="android"', {
     40           'dependencies': [
     41             '../../cc/cc.gyp:cc',
     42             '../../gpu/gpu.gyp:command_buffer_common',
     43           ],
     44         }],
     45         ['use_aura!=1 and OS!="android"', {
     46 	  'sources!': [
     47             'snapshot_async.cc',
     48             'snapshot_async.h',
     49           ],
     50         }],
     51         ['use_aura==1', {
     52           'dependencies': [
     53             '../aura/aura.gyp:aura',
     54             '../compositor/compositor.gyp:compositor',
     55           ],
     56         }],
     57       ],
     58     },
     59     {
     60       'target_name': 'snapshot_unittests',
     61       'type': '<(gtest_target_type)',
     62       'dependencies': [
     63         '../../skia/skia.gyp:skia',
     64         '../../base/base.gyp:base',
     65         '../../base/base.gyp:test_support_base',
     66         '../../testing/gtest.gyp:gtest',
     67         '../base/ui_base.gyp:ui_base',
     68         '../gfx/gfx.gyp:gfx',
     69         '../gfx/gfx.gyp:gfx_geometry',
     70         'snapshot'
     71       ],
     72       'sources': [
     73         'snapshot_aura_unittest.cc',
     74         'snapshot_mac_unittest.mm',
     75         'test/run_all_unittests.cc',
     76       ],
     77       'conditions': [
     78         ['use_aura==1', {
     79           'dependencies': [
     80             '../../base/base.gyp:test_support_base',
     81             '../aura/aura.gyp:aura_test_support',
     82             '../compositor/compositor.gyp:compositor',
     83             '../compositor/compositor.gyp:compositor_test_support',
     84             '../wm/wm.gyp:wm',
     85           ],
     86         }],
     87         # See http://crbug.com/162998#c4 for why this is needed.
     88         ['OS=="linux" and use_allocator!="none"', {
     89           'dependencies': [
     90             '../../base/allocator/allocator.gyp:allocator',
     91           ],
     92         }],
     93       ],
     94     },
     95   ],
     96   'conditions': [
     97     ['OS=="win"', {
     98       'targets': [
     99         {
    100           'target_name': 'snapshot_test_support',
    101           'type': 'static_library',
    102           'sources': [
    103             'test/snapshot_desktop.h',
    104             'test/snapshot_desktop_win.cc',
    105           ],
    106           'dependencies': [
    107             'snapshot',
    108           ],
    109           'include_dirs': [
    110             '../..',
    111           ],
    112         },
    113       ],
    114     }],
    115   ],
    116 }
    117