Home | History | Annotate | Download | only in sync
      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.
      4 
      5 {
      6   'variables': {
      7     'chromium_code': 1,
      8   },
      9 
     10   'includes': [
     11     'sync_android.gypi',
     12     'sync_tests.gypi',
     13   ],
     14 
     15   'conditions': [
     16     # Notes:
     17     # 1) In static mode, the public 'sync' target has a target type of 'none',
     18     #    and is composed of the static library targets 'sync_api', 'sync_core',
     19     #    'sync_internal_api', 'sync_notifier', and 'sync_proto'.
     20     # 2) In component mode, we build the public 'sync' target into a single DLL,
     21     #    which includes the contents of sync_api.gypi, sync_core.gypi,
     22     #    sync_internal_api.gypi, sync_notifier.gypi, and sync_proto.gypi.
     23     # 3) All external targets that depend on anything in sync/ must simply
     24     #    declare a dependency on 'sync.gyp:sync'
     25     ['component=="static_library"', {
     26       'targets': [
     27         # The public sync static library target.
     28         {
     29           'target_name': 'sync',
     30           'type': 'none',
     31           'dependencies': [
     32             'sync_api',
     33             'sync_core',
     34             'sync_internal_api',
     35             'sync_notifier',
     36             'sync_proto',
     37           ],
     38           'export_dependent_settings': [
     39             'sync_notifier',
     40             'sync_proto',
     41           ],
     42         },
     43 
     44         # The sync external API library.
     45         {
     46           'target_name': 'sync_api',
     47           'type': 'static_library',
     48           'variables': { 'enable_wexit_time_destructors': 1, },
     49           'includes': [
     50             'sync_api.gypi',
     51           ],
     52           'dependencies': [
     53             'sync_internal_api',
     54             'sync_proto',
     55           ],
     56         },
     57 
     58         # The core sync library.
     59         {
     60           'target_name': 'sync_core',
     61           'type': 'static_library',
     62           'variables': { 'enable_wexit_time_destructors': 1, },
     63           'includes': [
     64             'sync_core.gypi',
     65           ],
     66           'dependencies': [
     67             'sync_proto',
     68           ],
     69           'export_dependent_settings': [
     70             'sync_proto',
     71           ],
     72         },
     73 
     74         # The sync internal API library.
     75         {
     76           'target_name': 'sync_internal_api',
     77           'type': 'static_library',
     78           'variables': { 'enable_wexit_time_destructors': 1, },
     79           'includes': [
     80             'sync_internal_api.gypi',
     81           ],
     82           'dependencies': [
     83             'sync_core',
     84             'sync_notifier',
     85             'sync_proto',
     86           ],
     87           'export_dependent_settings': [
     88             'sync_core',
     89             'sync_proto',
     90           ],
     91         },
     92 
     93         # The sync notifications library.
     94         {
     95           'target_name': 'sync_notifier',
     96           'type': 'static_library',
     97           'variables': { 'enable_wexit_time_destructors': 1, },
     98           'includes': [
     99             'sync_notifier.gypi',
    100           ],
    101           'dependencies': [
    102             'sync_core',
    103           ],
    104         },
    105 
    106         # The sync protocol buffer library.
    107         {
    108           'target_name': 'sync_proto',
    109           'type': 'static_library',
    110           'variables': { 'enable_wexit_time_destructors': 1, },
    111           'includes': [
    112             'sync_proto.gypi',
    113           ],
    114         },
    115       ],
    116     },
    117     {  # component != static_library
    118       'targets': [
    119         # The public sync shared library target.
    120         {
    121           'target_name': 'sync',
    122           'type': 'shared_library',
    123           'variables': { 'enable_wexit_time_destructors': 1, },
    124           'includes': [
    125             'sync_api.gypi',
    126             'sync_core.gypi',
    127             'sync_internal_api.gypi',
    128             'sync_notifier.gypi',
    129             'sync_proto.gypi',
    130           ],
    131         },
    132       ],
    133     }],
    134   ],
    135 }
    136