Home | History | Annotate | Download | only in chrome
      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 
     10   'includes': [
     11     '../build/util/version.gypi',
     12   ],
     13 
     14   'target_defaults': {
     15     'sources': [
     16       'common/chrome_constants.cc',
     17       'common/chrome_constants.h',
     18       'common/chrome_icon_resources_win.cc',
     19       'common/chrome_icon_resources_win.h',
     20       'common/chrome_paths.cc',
     21       'common/chrome_paths.h',
     22       'common/chrome_paths_android.cc',
     23       'common/chrome_paths_internal.h',
     24       'common/chrome_paths_linux.cc',
     25       'common/chrome_paths_mac.mm',
     26       'common/chrome_paths_win.cc',
     27       'common/chrome_switches.cc',
     28       'common/chrome_switches.h',
     29       'common/env_vars.cc',
     30       'common/env_vars.h',
     31       'common/net/test_server_locations.cc',
     32       'common/net/test_server_locations.h',
     33       'common/pref_font_script_names-inl.h',
     34       'common/pref_font_webkit_names.h',
     35       'common/pref_names.cc',
     36       'common/pref_names.h',
     37       'common/widevine_cdm_constants.cc',
     38       'common/widevine_cdm_constants.h',
     39     ],
     40     'actions': [
     41       {
     42         'action_name': 'Make chrome_version.cc',
     43         'variables': {
     44           'make_version_cc_path': 'tools/build/make_version_cc.py',
     45         },
     46         'inputs': [
     47           '<(make_version_cc_path)',
     48           'VERSION',
     49         ],
     50         'outputs': [
     51           '<(INTERMEDIATE_DIR)/chrome_version.cc',
     52         ],
     53         'action': [
     54           'python',
     55           '<(make_version_cc_path)',
     56           '<@(_outputs)',
     57           '<(version_full)',
     58         ],
     59         'process_outputs_as_sources': 1,
     60       },
     61     ],
     62   },
     63   'targets': [
     64     {
     65       # GN version: //chrome/common:constants
     66       'target_name': 'common_constants',
     67       'type': 'static_library',
     68       'include_dirs': [
     69         '<(SHARED_INTERMEDIATE_DIR)',  # Needed by chrome_paths.cc.
     70       ],
     71       'dependencies': [
     72         '../base/base.gyp:base',
     73         '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
     74         '../components/components.gyp:bookmarks_common',
     75         '../third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
     76       ],
     77       'target_conditions': [
     78         ['OS=="ios"', {
     79           # iOS needs chrome_paths_mac, which is excluded by filename rules;
     80           # re-add it in target_conditionals so it's after that exclusion.
     81           'sources/': [
     82             ['include', '^common/chrome_paths_mac\\.mm$'],
     83           ],
     84         }],
     85       ],
     86       'conditions': [
     87         ['disable_nacl==0', {
     88           'dependencies': [
     89             '../components/nacl.gyp:nacl_switches',
     90           ],
     91         }],
     92       ],
     93     },
     94   ],
     95   'conditions': [
     96     ['OS=="win" and target_arch=="ia32"', {
     97       'targets': [
     98         {
     99           'target_name': 'common_constants_win64',
    100           'type': 'static_library',
    101           'include_dirs': [
    102             '<(SHARED_INTERMEDIATE_DIR)',  # Needed by chrome_paths.cc.
    103           ],
    104           'dependencies': [
    105             '../base/base.gyp:base_win64',
    106             '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations_win64',
    107             '../components/nacl.gyp:nacl_switches_win64',
    108             '../third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
    109           ],
    110           'defines': [
    111             '<@(nacl_win64_defines)',
    112             'COMPILE_CONTENT_STATICALLY',
    113           ],
    114           'configurations': {
    115             'Common_Base': {
    116               'msvs_target_platform': 'x64',
    117             },
    118           },
    119         },
    120       ],
    121     }],
    122   ],
    123 }
    124