Prepare for webview compositing on MACOSX.
[chromium-blink-merge.git] / chrome / common_constants.gyp
blobe231e11b12532ac5a8cbb682a34fc55b063e755e
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.
6   'variables': {
7     'chromium_code': 1,
8   },
10   'includes': [
11     'version.gypi',
12   ],
14   'target_defaults': {
15     'sources': [
16       'common/chrome_constants.cc',
17       'common/chrome_constants.h',
18       'common/chrome_paths.cc',
19       'common/chrome_paths.h',
20       'common/chrome_paths_android.cc',
21       'common/chrome_paths_internal.h',
22       'common/chrome_paths_linux.cc',
23       'common/chrome_paths_mac.mm',
24       'common/chrome_paths_win.cc',
25       'common/chrome_switches.cc',
26       'common/chrome_switches.h',
27       'common/env_vars.cc',
28       'common/env_vars.h',
29       'common/net/test_server_locations.cc',
30       'common/net/test_server_locations.h',
31       'common/pref_names.cc',
32       'common/pref_names.h',
33     ],
34     'actions': [
35       {
36         'action_name': 'Make chrome_version.cc',
37         'variables': {
38           'make_version_cc_path': 'tools/build/make_version_cc.py',
39         },
40         'inputs': [
41           '<(make_version_cc_path)',
42           'VERSION',
43         ],
44         'outputs': [
45           '<(INTERMEDIATE_DIR)/chrome_version.cc',
46         ],
47         'action': [
48           'python',
49           '<(make_version_cc_path)',
50           '<@(_outputs)',
51           '<(version_full)',
52         ],
53         'process_outputs_as_sources': 1,
54       },
55     ],
56   },
57   'targets': [
58     {
59       'target_name': 'common_constants',
60       'type': 'static_library',
61       'include_dirs': [
62         '<(SHARED_INTERMEDIATE_DIR)',  # Needed by chrome_paths.cc.
63       ],
64       'dependencies': [
65         '../base/base.gyp:base',
66         '../third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
67       ],
68       'target_conditions': [
69         ['OS=="ios"', {
70           # iOS needs chrome_paths_mac, which is excluded by filename rules;
71           # re-add it in target_conditionals so it's after that exclusion.
72           'sources/': [
73             ['include', '^common/chrome_paths_mac\\.mm$'],
74           ],
75         }],
76       ],
77       'conditions': [
78         ['toolkit_uses_gtk == 1', {
79           'dependencies': ['../build/linux/system.gyp:gtk'],
80         }],
81       ],
82     },
83   ],
84   'conditions': [
85     ['OS=="win" and target_arch=="ia32"', {
86       'targets': [
87         {
88           'target_name': 'common_constants_win64',
89           'type': 'static_library',
90           'include_dirs': [
91             '<(SHARED_INTERMEDIATE_DIR)',  # Needed by chrome_paths.cc.
92           ],
93           'dependencies': [
94             '../base/base.gyp:base_nacl_win64',
95             '../third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
96           ],
97           'defines': [
98             '<@(nacl_win64_defines)',
99             'COMPILE_CONTENT_STATICALLY',
100           ],
101           'configurations': {
102             'Common_Base': {
103               'msvs_target_platform': 'x64',
104             },
105           },
106         },
107       ],
108     }],
109   ],