blob: 7f3bc59ed091900c98e4a1a5789526ebb8a3b884 [file] [log] [blame]
[email protected]2f80c312009-02-25 21:26:551# Copyright (c) 2009 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
[email protected]21642ab2009-09-15 23:52:145# IMPORTANT:
6# Please don't directly include this file if you are building via gyp_chromium,
7# since gyp_chromium is automatically forcing its inclusion.
[email protected]2f80c312009-02-25 21:26:558{
9 'variables': {
[email protected]b3fb8092009-03-12 19:09:2410 # .gyp files should set chromium_code to 1 if they build Chromium-specific
11 # code, as opposed to external code. This variable is used to control
12 # such things as the set of warnings to enable, and whether warnings are
13 # treated as errors.
[email protected]2f80c312009-02-25 21:26:5514 'chromium_code%': 0,
[email protected]b3fb8092009-03-12 19:09:2415
16 # Variables expected to be overriden on the GYP command line (-D) or by
17 # ~/.gyp/include.gypi.
18
[email protected]e14a9f92009-08-05 19:26:0719 # Putting a variables dict inside another variables dict looks kind of
20 # weird. This is done so that "branding" and "buildtype" are defined as
21 # variables within the outer variables dict here. This is necessary
22 # to get these variables defined for the conditions within this variables
23 # dict that operate on these variables.
24 'variables': {
25 # Override branding to select the desired branding flavor.
26 'branding%': 'Chromium',
27
28 # Override buildtype to select the desired build flavor.
29 # Dev - everyday build for development/testing
30 # Official - release build (generally implies additional processing)
31 # TODO(mmoss) Once 'buildtype' is fully supported (e.g. Windows gyp
32 # conversion is done), some of the things which are now controlled by
33 # 'branding', such as symbol generation, will need to be refactored based
34 # on 'buildtype' (i.e. we don't care about saving symbols for non-Official
35 # builds).
36 'buildtype%': 'Dev',
[email protected]cbd5fd52009-08-26 00:14:2737
[email protected]521240182009-10-16 00:53:5938 # Compute the architecture that we're building for. Default to the
39 # architecture that we're building on.
40 'conditions': [
41 [ 'OS=="linux"', {
42 # This handles the Linux platforms we generally deal with. Anything
43 # else gets passed through, which probably won't work very well; such
44 # hosts should pass an explicit target_arch to gyp.
45 'target_arch%':
[email protected]85c55dc2009-11-06 03:05:4646 '<!(uname -m | sed -e "s/i.86/ia32/;s/x86_64/x64/;s/arm.*/arm/")',
47
[email protected]521240182009-10-16 00:53:5948 }, { # OS!="linux"
49 'target_arch%': 'ia32',
[email protected]cb6037d2009-11-16 22:55:1750 }],
[email protected]521240182009-10-16 00:53:5951 ],
[email protected]e0d00142009-09-18 22:10:2752
[email protected]cbd5fd52009-08-26 00:14:2753 # We do want to build Chromium with Breakpad support in certain
54 # situations. I.e. for Chrome bot.
55 'linux_chromium_breakpad%': 0,
[email protected]4c9cc6c2009-10-01 18:54:5756 # And if we want to dump symbols.
[email protected]05cb6962009-10-01 23:29:0357 'linux_chromium_dump_symbols%': 0,
58 # Also see linux_strip_binary below.
[email protected]c153e5352009-09-22 12:37:4459
60 # By default, Linux does not use views. To turn on views in Linux,
61 # set the variable GYP_DEFINES to "toolkit_views=1", or modify
62 # ~/.gyp/include.gypi .
63 'toolkit_views%': 0,
64
65 # Defaults to a desktop build, overridden via command line/env.
66 'chromeos%': 0,
[email protected]b2f030c2009-09-24 20:36:2167
68 # This variable tells WebCore.gyp and JavaScriptCore.gyp whether they are
69 # are built under a chromium full build (1) or a webkit.org chromium
70 # build (0).
71 'inside_chromium_build%': 1,
[email protected]9c1949e2009-10-02 19:59:5472
73 # Set to 1 to enable fast builds. It disables debug info for fastest
74 # compilation.
75 'fastbuild%': 0,
[email protected]e14a9f92009-08-05 19:26:0776 },
77
78 # Define branding and buildtype on the basis of their settings within the
79 # variables sub-dict above, unless overridden.
80 'branding%': '<(branding)',
81 'buildtype%': '<(buildtype)',
[email protected]e0d00142009-09-18 22:10:2782 'target_arch%': '<(target_arch)',
[email protected]c153e5352009-09-22 12:37:4483 'toolkit_views%': '<(toolkit_views)',
84 'chromeos%': '<(chromeos)',
[email protected]b2f030c2009-09-24 20:36:2185 'inside_chromium_build%': '<(inside_chromium_build)',
[email protected]9c1949e2009-10-02 19:59:5486 'fastbuild%': '<(fastbuild)',
[email protected]e14a9f92009-08-05 19:26:0787
[email protected]caa95c82009-11-23 22:39:3288 # The release channel that this build targets. This is used to restrict
89 # channel-specific build options, like which installer packages to create.
90 # The default is 'all', which does no channel-specific filtering.
91 'channel%': 'all',
92
[email protected]b3fb8092009-03-12 19:09:2493 # Override chromium_mac_pch and set it to 0 to suppress the use of
94 # precompiled headers on the Mac. Prefix header injection may still be
95 # used, but prefix headers will not be precompiled. This is useful when
96 # using distcc to distribute a build to compile slaves that don't
97 # share the same compiler executable as the system driving the compilation,
98 # because precompiled headers rely on pointers into a specific compiler
99 # executable's image. Setting this to 0 is needed to use an experimental
100 # Linux-Mac cross compiler distcc farm.
101 'chromium_mac_pch%': 1,
102
[email protected]3224dcd2009-09-16 17:31:25103 # Mac OS X SDK and deployment target support.
104 # The SDK identifies the version of the system headers that will be used,
105 # and corresponds to the MAC_OS_X_VERSION_MAX_ALLOWED compile-time macro.
106 # "Maximum allowed" refers to the operating system version whose APIs are
107 # available in the headers.
108 # The deployment target identifies the minimum system version that the
109 # built products are expected to function on. It corresponds to the
110 # MAC_OS_X_VERSION_MIN_REQUIRED compile-time macro.
111 # To ensure these macros are available, #include <AvailabilityMacros.h>.
112 # Additional documentation on these macros is available at
113 # http://developer.apple.com/mac/library/technotes/tn2002/tn2064.html#SECTION3
114 # Chrome normally builds with the Mac OS X 10.5 SDK and sets the
115 # deployment target to 10.5. Other projects, such as O3D, may override
116 # these defaults.
117 'mac_sdk%': '10.5',
118 'mac_deployment_target%': '10.5',
[email protected]9543af052009-09-15 22:42:59119
[email protected]f5ecbba12009-04-03 04:35:18120 # Set to 1 to enable code coverage. In addition to build changes
121 # (e.g. extra CFLAGS), also creates a new target in the src/chrome
122 # project file called "coverage".
123 # Currently ignored on Windows.
124 'coverage%': 0,
[email protected]653bd5f032009-04-08 12:55:49125
[email protected]c61f6432009-04-22 01:16:42126 # Overridable specification for potential use of alternative
127 # JavaScript engines.
128 'javascript_engine%': 'v8',
129
[email protected]653bd5f032009-04-08 12:55:49130 # To do a shared build on linux we need to be able to choose between type
131 # static_library and shared_library. We default to doing a static build
132 # but you can override this with "gyp -Dlibrary=shared_library" or you
133 # can add the following line (without the #) to ~/.gyp/include.gypi
134 # {'variables': {'library': 'shared_library'}}
135 # to compile as shared by default
136 'library%': 'static_library',
[email protected]279cd4212009-09-11 22:32:11137
[email protected]06e6f872009-09-01 19:09:41138 # The Google Update appid.
139 'google_update_appid%': '{8A69D345-D564-463c-AFF1-A69D9E530F96}',
[email protected]279cd4212009-09-11 22:32:11140
141 # Whether to add the experimental build define.
[email protected]756499c2009-09-28 16:50:46142 'chrome_frame_define%': 0,
[email protected]e5b2eaa2009-04-14 01:39:12143
[email protected]a79a3f8d2009-11-02 21:07:35144 # Whether pepper APIs are enabled.
145 'enable_pepper%': 0,
[email protected]cb6037d2009-11-16 22:55:17146
[email protected]95ff8082009-11-13 22:21:01147 # Whether usage of OpenMAX is enabled.
148 'enable_openmax%': 0,
149
[email protected]e5b2eaa2009-04-14 01:39:12150 # TODO(bradnelson): eliminate this when possible.
151 # To allow local gyp files to prevent release.vsprops from being included.
152 # Yes(1) means include release.vsprops.
153 # Once all vsprops settings are migrated into gyp, this can go away.
154 'msvs_use_common_release%': 1,
[email protected]606116d22009-05-06 22:38:23155
[email protected]cbd5fd52009-08-26 00:14:27156 # TODO(bradnelson): eliminate this when possible.
157 # To allow local gyp files to override additional linker options for msvs.
158 # Yes(1) means set use the common linker options.
[email protected]48c7af72009-07-03 22:00:19159 'msvs_use_common_linker_extras%': 1,
160
[email protected]1ffb6502009-06-02 07:46:24161 # TODO(sgk): eliminate this if possible.
162 # It would be nicer to support this via a setting in 'target_defaults'
163 # in chrome/app/locales/locales.gypi overriding the setting in the
164 # 'Debug' configuration in the 'target_defaults' dict below,
165 # but that doesn't work as we'd like.
166 'msvs_debug_link_incremental%': '2',
167
[email protected]ee28c9f2009-09-04 01:53:01168 # The system root for cross-compiles. Default: none.
169 'sysroot%': '',
170
[email protected]573136142009-07-15 22:48:37171 # This is the location of the sandbox binary. Chrome looks for this before
172 # running the zygote process. If found, and SUID, it will be used to
173 # sandbox the zygote process and, thus, all renderer processes.
174 'linux_sandbox_path%': '',
175
[email protected]ad6d2c42009-09-15 20:13:38176 # Set this to true to enable SELinux support.
177 'selinux%': 0,
[email protected]4c9cc6c2009-10-01 18:54:57178
[email protected]05cb6962009-10-01 23:29:03179 # Strip the binary after dumping symbols.
180 'linux_strip_binary%': 0,
181
[email protected]01699e22009-11-11 19:24:24182 # Enable TCMalloc.
[email protected]45350972009-11-17 06:42:28183 'linux_use_tcmalloc%': 0,
[email protected]01699e22009-11-11 19:24:24184
[email protected]c153e5352009-09-22 12:37:44185 # Set to select the Title Case versions of strings in GRD files.
186 'use_titlecase_in_grd_files%': 0,
[email protected]ad6d2c42009-09-15 20:13:38187
[email protected]d8c7cbcc2009-10-02 19:00:31188 # Used to disable Native Client at compile time, for platforms where it
189 # isn't supported
190 'disable_nacl%': 0,
191
[email protected]3ed42e32009-10-07 00:10:46192 # Set ARM-v7 compilation flags
193 'armv7%': 0,
194
[email protected]912c55c2009-07-31 23:33:55195 'conditions': [
[email protected]cbd5fd52009-08-26 00:14:27196 ['OS=="linux"', {
[email protected]242a9e62009-11-03 17:32:10197 # This will set gcc_version to XY if you are running gcc X.Y.*.
198 # This is used to tweak build flags for gcc 4.4.
199 'gcc_version%': '<!(python <(DEPTH)/build/compiler_version.py)',
[email protected]cbd5fd52009-08-26 00:14:27200 'conditions': [
201 ['branding=="Chrome" or linux_chromium_breakpad==1', {
202 'linux_breakpad%': 1,
203 }, {
204 'linux_breakpad%': 0,
205 }],
[email protected]4c9cc6c2009-10-01 18:54:57206 # All Chrome builds have breakpad symbols, but only process the
207 # symbols from official builds.
208 # TODO(mmoss) dump_syms segfaults on x64. Enable once dump_syms and
209 # crash server handle 64-bit symbols.
210 ['linux_chromium_dump_symbols==1 or '
211 '(branding=="Chrome" and buildtype=="Official" and '
212 'target_arch=="ia32")', {
213 'linux_dump_symbols%': 1,
214 }, {
215 'linux_dump_symbols%': 0,
216 }],
[email protected]c153e5352009-09-22 12:37:44217 ['toolkit_views==0', {
218 # GTK wants Title Case strings
219 'use_titlecase_in_grd_files%': 1,
220 }],
[email protected]cbd5fd52009-08-26 00:14:27221 ],
222 }], # OS=="linux"
[email protected]e14a9f92009-08-05 19:26:07223 ['OS=="mac"', {
[email protected]c153e5352009-09-22 12:37:44224 # Mac wants Title Case strings
225 'use_titlecase_in_grd_files%': 1,
[email protected]e14a9f92009-08-05 19:26:07226 'conditions': [
227 # mac_product_name is set to the name of the .app bundle as it should
228 # appear on disk. This duplicates data from
229 # chrome/app/theme/chromium/BRANDING and
230 # chrome/app/theme/google_chrome/BRANDING, but is necessary to get
231 # these names into the build system.
232 ['branding=="Chrome"', {
233 'mac_product_name%': 'Google Chrome',
234 }, { # else: branding!="Chrome"
235 'mac_product_name%': 'Chromium',
236 }],
237
238 # Feature variables for enabling Mac Breakpad and Keystone auto-update
239 # support. Both features are on by default in official builds with
240 # Chrome branding.
241 ['branding=="Chrome" and buildtype=="Official"', {
242 'mac_breakpad%': 1,
243 'mac_keystone%': 1,
244 }, { # else: branding!="Chrome" or buildtype!="Official"
245 'mac_breakpad%': 0,
246 'mac_keystone%': 0,
247 }],
248 ],
249 }], # OS=="mac"
[email protected]912c55c2009-07-31 23:33:55250 # Whether to use multiple cores to compile with visual studio. This is
251 # optional because it sometimes causes corruption on VS 2005.
252 # It is on by default on VS 2008 and off on VS 2005.
253 ['OS=="win"', {
254 'conditions': [
255 ['MSVS_VERSION=="2005"', {
[email protected]669795372009-08-14 17:51:13256 'msvs_multi_core_compile%': 0,
[email protected]912c55c2009-07-31 23:33:55257 },{
258 'msvs_multi_core_compile%': 1,
259 }],
[email protected]10bb8c92009-08-07 21:16:03260 # Don't do incremental linking for large modules on 32-bit.
261 ['MSVS_OS_BITS==32', {
262 'msvs_large_module_debug_link_mode%': '1', # No
263 },{
264 'msvs_large_module_debug_link_mode%': '2', # Yes
265 }],
[email protected]912c55c2009-07-31 23:33:55266 ],
267 }],
268 ],
[email protected]f703c4e2009-09-17 21:54:28269
270 # NOTE: When these end up in the Mac bundle, we need to replace '-' for '_'
271 # so Cocoa is happy (http://crbug.com/20441).
272 'locales': [
[email protected]af27c8c2009-11-04 20:36:50273 'am', 'ar', 'bg', 'bn', 'ca', 'cs', 'da', 'de', 'el', 'en-GB',
[email protected]f703c4e2009-09-17 21:54:28274 'en-US', 'es-419', 'es', 'et', 'fi', 'fil', 'fr', 'gu', 'he',
275 'hi', 'hr', 'hu', 'id', 'it', 'ja', 'kn', 'ko', 'lt', 'lv',
276 'ml', 'mr', 'nb', 'nl', 'or', 'pl', 'pt-BR', 'pt-PT', 'ro',
[email protected]af27c8c2009-11-04 20:36:50277 'ru', 'sk', 'sl', 'sr', 'sv', 'sw', 'ta', 'te', 'th', 'tr',
[email protected]f703c4e2009-09-17 21:54:28278 'uk', 'vi', 'zh-CN', 'zh-TW',
279 ],
[email protected]2f80c312009-02-25 21:26:55280 },
281 'target_defaults': {
[email protected]1c966092009-08-20 21:19:26282 'variables': {
[email protected]d5d593a2009-08-28 23:23:29283 'mac_release_optimization%': '3', # Use -O3 unless overridden
[email protected]ffd984b12009-09-11 19:37:00284 'mac_debug_optimization%': '0', # Use -O0 unless overridden
285 'release_extra_cflags%': '',
286 'debug_extra_cflags%': '',
[email protected]92822e82009-09-18 14:26:56287 'release_valgrind_build%': 0,
[email protected]1c966092009-08-20 21:19:26288 },
[email protected]32aa8cc2009-03-04 21:36:39289 'conditions': [
290 ['branding=="Chrome"', {
291 'defines': ['GOOGLE_CHROME_BUILD'],
292 }, { # else: branding!="Chrome"
293 'defines': ['CHROMIUM_BUILD'],
294 }],
[email protected]756499c2009-09-28 16:50:46295 ['chrome_frame_define', {
296 'defines': ['CHROME_FRAME_BUILD'],
[email protected]279cd4212009-09-11 22:32:11297 }],
[email protected]6cb1cec2009-05-15 03:05:20298 ['toolkit_views==1', {
[email protected]e6970232009-05-12 23:51:17299 'defines': ['TOOLKIT_VIEWS=1'],
300 }],
[email protected]3e193f9c2009-10-13 23:31:53301 ['chromeos==1', {
302 'defines': ['CHROMEOS_TRANSITIONAL=1'],
303 }],
[email protected]a678f3f2009-10-12 23:58:03304 ['chromeos==1 or toolkit_views==1', {
[email protected]16779842009-07-08 23:45:29305 'defines': ['OS_CHROMEOS=1'],
[email protected]2b883b92009-06-02 22:57:50306 }],
[email protected]a79a3f8d2009-11-02 21:07:35307 ['enable_pepper==1', {
308 'defines': ['ENABLE_PEPPER=1'],
309 }],
[email protected]9c1949e2009-10-02 19:59:54310 ['fastbuild!=0', {
311 'conditions': [
312 # Finally, for Windows, we simply turn on profiling.
313 ['OS=="win"', {
314 'msvs_settings': {
315 'VCLinkerTool': {
316 'GenerateDebugInformation': 'false',
317 },
318 'VCCLCompilerTool': {
319 'DebugInformationFormat': '0',
320 }
321 }
322 }], # OS==win
323 ], # conditions for fastbuild.
324 }], # fastbuild!=0
[email protected]ad6d2c42009-09-15 20:13:38325 ['selinux==1', {
326 'defines': ['CHROMIUM_SELINUX=1'],
327 }],
[email protected]f5ecbba12009-04-03 04:35:18328 ['coverage!=0', {
329 'conditions': [
330 ['OS=="mac"', {
331 'xcode_settings': {
[email protected]ab2956372009-08-13 18:11:04332 'GCC_INSTRUMENT_PROGRAM_FLOW_ARCS': 'YES', # -fprofile-arcs
333 'GCC_GENERATE_TEST_COVERAGE_FILES': 'YES', # -ftest-coverage
[email protected]5ae4f55e2009-04-13 23:19:47334 },
[email protected]ac1f5732009-10-23 00:12:01335 # Add -lgcov for executables and shared_libraries, not for
336 # static_libraries. This is a delayed conditional.
[email protected]f5ecbba12009-04-03 04:35:18337 'target_conditions': [
[email protected]ac1f5732009-10-23 00:12:01338 ['_type=="executable" or _type=="shared_library"', {
[email protected]f5ecbba12009-04-03 04:35:18339 'xcode_settings': { 'OTHER_LDFLAGS': [ '-lgcov' ] },
[email protected]5ae4f55e2009-04-13 23:19:47340 }],
341 ],
342 }],
[email protected]7122ffd52009-04-30 23:19:00343 # Linux gyp (into scons) doesn't like target_conditions?
344 # TODO(???): track down why 'target_conditions' doesn't work
345 # on Linux gyp into scons like it does on Mac gyp into xcodeproj.
[email protected]f5ecbba12009-04-03 04:35:18346 ['OS=="linux"', {
347 'cflags': [ '-ftest-coverage',
348 '-fprofile-arcs' ],
[email protected]7122ffd52009-04-30 23:19:00349 'link_settings': { 'libraries': [ '-lgcov' ] },
[email protected]f5ecbba12009-04-03 04:35:18350 }],
[email protected]e8f6ff42009-07-07 18:20:53351 # Finally, for Windows, we simply turn on profiling.
352 ['OS=="win"', {
353 'msvs_settings': {
354 'VCLinkerTool': {
355 'Profile': 'true',
356 },
[email protected]10bb8c92009-08-07 21:16:03357 'VCCLCompilerTool': {
[email protected]e8f6ff42009-07-07 18:20:53358 # /Z7, not /Zi, so coverage is happyb
359 'DebugInformationFormat': '1',
360 'AdditionalOptions': '/Yd',
361 }
362 }
363 }], # OS==win
364 ], # conditions for coverage
365 }], # coverage!=0
366 ], # conditions for 'target_defaults'
[email protected]2f80c312009-02-25 21:26:55367 'default_configuration': 'Debug',
368 'configurations': {
[email protected]825ff8d2009-05-22 01:40:48369 # VCLinkerTool LinkIncremental values below:
370 # 0 == default
371 # 1 == /INCREMENTAL:NO
372 # 2 == /INCREMENTAL
373 # Debug links incremental, Release does not.
[email protected]bb05e452009-10-29 21:24:56374 'Common': {
375 'abstract': 1,
376 'msvs_configuration_attributes': {
377 'OutputDirectory': '$(SolutionDir)$(ConfigurationName)',
378 'IntermediateDirectory': '$(OutDir)\\obj\\$(ProjectName)',
379 'CharacterSet': '1',
380 },
[email protected]2fa40782009-11-01 21:17:34381 'msvs_configuration_platform': 'Win32',
[email protected]bb05e452009-10-29 21:24:56382 },
[email protected]2f80c312009-02-25 21:26:55383 'Debug': {
[email protected]bb05e452009-10-29 21:24:56384 'inherit_from': ['Common'],
[email protected]1c966092009-08-20 21:19:26385 'xcode_settings': {
386 'COPY_PHASE_STRIP': 'NO',
[email protected]d5d593a2009-08-28 23:23:29387 'GCC_OPTIMIZATION_LEVEL': '<(mac_debug_optimization)',
[email protected]bd232ac2009-10-21 02:23:53388 'OTHER_CFLAGS': [ '<@(debug_extra_cflags)', ],
[email protected]1c966092009-08-20 21:19:26389 },
[email protected]bb05e452009-10-29 21:24:56390 'msvs_settings': {
391 'VCCLCompilerTool': {
392 'Optimization': '0',
393 'PreprocessorDefinitions': ['_DEBUG'],
394 'BasicRuntimeChecks': '3',
395 'RuntimeLibrary': '1',
396 },
397 'VCLinkerTool': {
398 'LinkIncremental': '<(msvs_debug_link_incremental)',
399 },
400 'VCResourceCompilerTool': {
401 'PreprocessorDefinitions': ['_DEBUG'],
402 },
403 },
[email protected]2f80c312009-02-25 21:26:55404 'conditions': [
[email protected]bb05e452009-10-29 21:24:56405 ['OS=="linux"', {
406 'cflags': [
407 '<@(debug_extra_cflags)',
408 ],
[email protected]2f80c312009-02-25 21:26:55409 }],
410 ],
411 },
412 'Release': {
[email protected]bb05e452009-10-29 21:24:56413 'inherit_from': ['Common'],
[email protected]2f80c312009-02-25 21:26:55414 'defines': [
415 'NDEBUG',
416 ],
[email protected]1c966092009-08-20 21:19:26417 'xcode_settings': {
418 'DEAD_CODE_STRIPPING': 'YES', # -Wl,-dead_strip
419 'GCC_OPTIMIZATION_LEVEL': '<(mac_release_optimization)',
[email protected]ffd984b12009-09-11 19:37:00420 'OTHER_CFLAGS': [ '<@(release_extra_cflags)', ],
[email protected]1c966092009-08-20 21:19:26421 },
[email protected]bb05e452009-10-29 21:24:56422 'msvs_settings': {
423 'VCLinkerTool': {
424 'LinkIncremental': '1',
425 },
426 },
[email protected]2f80c312009-02-25 21:26:55427 'conditions': [
[email protected]92822e82009-09-18 14:26:56428 ['release_valgrind_build==0', {
429 'defines': ['NVALGRIND'],
430 }],
[email protected]bb05e452009-10-29 21:24:56431 ['msvs_use_common_release', {
[email protected]2f80c312009-02-25 21:26:55432 'msvs_props': ['release.vsprops'],
433 }],
[email protected]bb05e452009-10-29 21:24:56434 ['OS=="linux"', {
435 'cflags': [
[email protected]ffd984b12009-09-11 19:37:00436 '<@(release_extra_cflags)',
[email protected]bb05e452009-10-29 21:24:56437 ],
438 }],
[email protected]2f80c312009-02-25 21:26:55439 ],
440 },
[email protected]f926fa0a2009-08-04 22:50:13441 'conditions': [
442 [ 'OS=="win"', {
443 # TODO(bradnelson): add a gyp mechanism to make this more graceful.
444 'Purify': {
[email protected]bb05e452009-10-29 21:24:56445 'inherit_from': ['Release'],
[email protected]f926fa0a2009-08-04 22:50:13446 'defines': [
[email protected]f926fa0a2009-08-04 22:50:13447 'PURIFY',
448 'NO_TCMALLOC',
449 ],
450 'msvs_settings': {
451 'VCCLCompilerTool': {
452 'Optimization': '0',
453 'RuntimeLibrary': '0',
454 'BufferSecurityCheck': 'false',
455 },
456 'VCLinkerTool': {
457 'EnableCOMDATFolding': '1',
458 'LinkIncremental': '1',
459 },
460 },
[email protected]f926fa0a2009-08-04 22:50:13461 },
462 'Release - no tcmalloc': {
[email protected]bb05e452009-10-29 21:24:56463 'inherit_from': ['Release'],
464 'defines': ['NO_TCMALLOC'],
[email protected]f926fa0a2009-08-04 22:50:13465 },
[email protected]78263c12009-11-01 23:45:30466 'Debug_x64': {
467 'inherit_from': ['Debug'],
468 'msvs_configuration_platform': 'x64',
469 },
470 'Release_x64': {
471 'inherit_from': ['Release'],
472 'msvs_configuration_platform': 'x64',
473 },
474 'Purify_x64': {
475 'inherit_from': ['Purify'],
476 'msvs_configuration_platform': 'x64',
477 },
478 'Release - no tcmalloc_x64': {
479 'inherit_from': ['Release - no tcmalloc'],
480 'msvs_configuration_platform': 'x64',
481 },
[email protected]f926fa0a2009-08-04 22:50:13482 }],
483 ],
[email protected]2f80c312009-02-25 21:26:55484 },
485 },
486 'conditions': [
[email protected]606116d22009-05-06 22:38:23487 ['OS=="linux"', {
[email protected]9d384032009-03-20 23:13:26488 'target_defaults': {
[email protected]5315f2842009-04-28 00:43:27489 # Enable -Werror by default, but put it in a variable so it can
490 # be disabled in ~/.gyp/include.gypi on the valgrind builders.
491 'variables': {
492 'werror%': '-Werror',
[email protected]cc4219a2009-08-14 05:30:52493 'no_strict_aliasing%': 0,
[email protected]5315f2842009-04-28 00:43:27494 },
[email protected]9d384032009-03-20 23:13:26495 'cflags': [
[email protected]1bba09c2009-08-13 12:53:16496 '<(werror)', # See note above about the werror variable.
497 '-pthread',
[email protected]ee7baa72009-11-18 01:51:34498 # We don't use exceptions. By disabling exceptions
499 # (and asynchronous-unwind-tables), we shave off 2.5mb from
500 # our resulting binary by not including the eh_frame section.
[email protected]1bba09c2009-08-13 12:53:16501 '-fno-exceptions',
[email protected]ee7baa72009-11-18 01:51:34502 '-fno-asynchronous-unwind-tables',
[email protected]7cd2afd2009-10-27 21:40:26503 '-fvisibility=hidden',
[email protected]1bba09c2009-08-13 12:53:16504 '-Wall',
505 '-D_FILE_OFFSET_BITS=64',
[email protected]8a2fcba2009-07-29 00:52:24506 ],
507 'cflags_cc': [
[email protected]832d0212009-10-28 19:12:22508 '-fno-rtti',
[email protected]8a2fcba2009-07-29 00:52:24509 '-fno-threadsafe-statics',
[email protected]f5986c42009-11-17 18:39:36510 # Make inline functions have hidden visiblity by default.
511 # Surprisingly, not covered by -fvisibility=hidden.
512 '-fvisibility-inlines-hidden',
[email protected]9d384032009-03-20 23:13:26513 ],
[email protected]a6cf87e2009-04-03 04:07:38514 'ldflags': [
[email protected]9d384032009-03-20 23:13:26515 '-pthread',
516 ],
[email protected]b5e46b92009-03-26 18:58:10517 'scons_variable_settings': {
518 'LIBPATH': ['$LIB_DIR'],
[email protected]9d384032009-03-20 23:13:26519 # Linking of large files uses lots of RAM, so serialize links
520 # using the handy flock command from util-linux.
[email protected]c13fcbd2009-03-27 04:27:01521 'FLOCK_LINK': ['flock', '$TOP_BUILDDIR/linker.lock', '$LINK'],
[email protected]789fbb7c2009-04-02 16:20:31522 'FLOCK_SHLINK': ['flock', '$TOP_BUILDDIR/linker.lock', '$SHLINK'],
523 'FLOCK_LDMODULE': ['flock', '$TOP_BUILDDIR/linker.lock', '$LDMODULE'],
[email protected]9d384032009-03-20 23:13:26524
525 # We have several cases where archives depend on each other in
526 # a cyclic fashion. Since the GNU linker does only a single
527 # pass over the archives we surround the libraries with
528 # --start-group and --end-group (aka -( and -) ). That causes
529 # ld to loop over the group until no more undefined symbols
530 # are found. In an ideal world we would only make groups from
531 # those libraries which we knew to be in cycles. However,
532 # that's tough with SCons, so we bodge it by making all the
533 # archives a group by redefining the linking command here.
534 #
535 # TODO: investigate whether we still have cycles that
536 # require --{start,end}-group. There has been a lot of
537 # refactoring since this was first coded, which might have
538 # eliminated the circular dependencies.
[email protected]12862922009-04-20 21:36:41539 #
540 # Note: $_LIBDIRFLAGS comes before ${LINK,SHLINK,LDMODULE}FLAGS
541 # so that we prefer our own built libraries (e.g. -lpng) to
542 # system versions of libraries that pkg-config might turn up.
543 # TODO(sgk): investigate handling this not by re-ordering the
544 # flags this way, but by adding a hook to use the SCons
545 # ParseFlags() option on the output from pkg-config.
[email protected]610d8cc2009-09-19 00:47:04546 'LINKCOM': [['$FLOCK_LINK', '-o', '$TARGET',
547 '$_LIBDIRFLAGS', '$LINKFLAGS', '$SOURCES',
548 '-Wl,--start-group', '$_LIBFLAGS', '-Wl,--end-group']],
549 'SHLINKCOM': [['$FLOCK_SHLINK', '-o', '$TARGET',
550 '$_LIBDIRFLAGS', '$SHLINKFLAGS', '$SOURCES',
551 '-Wl,--start-group', '$_LIBFLAGS', '-Wl,--end-group']],
552 'LDMODULECOM': [['$FLOCK_LDMODULE', '-o', '$TARGET',
553 '$_LIBDIRFLAGS', '$LDMODULEFLAGS', '$SOURCES',
554 '-Wl,--start-group', '$_LIBFLAGS', '-Wl,--end-group']],
[email protected]9d384032009-03-20 23:13:26555 'IMPLICIT_COMMAND_DEPENDENCIES': 0,
[email protected]d0644282009-04-22 00:20:29556 # -rpath is only used when building with shared libraries.
557 'conditions': [
558 [ 'library=="shared_library"', {
559 'RPATH': '$LIB_DIR',
560 }],
561 ],
[email protected]9d384032009-03-20 23:13:26562 },
[email protected]b5e46b92009-03-26 18:58:10563 'scons_import_variables': [
[email protected]52049d5c2009-05-01 20:32:49564 'AS',
[email protected]b5e46b92009-03-26 18:58:10565 'CC',
566 'CXX',
567 'LINK',
568 ],
569 'scons_propagate_variables': [
[email protected]52049d5c2009-05-01 20:32:49570 'AS',
[email protected]b5e46b92009-03-26 18:58:10571 'CC',
572 'CCACHE_DIR',
573 'CXX',
574 'DISTCC_DIR',
575 'DISTCC_HOSTS',
576 'HOME',
[email protected]5ae4f55e2009-04-13 23:19:47577 'INCLUDE_SERVER_ARGS',
578 'INCLUDE_SERVER_PORT',
[email protected]b5e46b92009-03-26 18:58:10579 'LINK',
[email protected]fff920a2009-05-08 22:35:32580 'CHROME_BUILD_TYPE',
581 'CHROMIUM_BUILD',
582 'OFFICIAL_BUILD',
[email protected]b5e46b92009-03-26 18:58:10583 ],
[email protected]3aacaf952009-04-02 15:34:09584 'configurations': {
585 'Debug': {
[email protected]c5bdc032009-04-20 19:11:31586 'variables': {
587 'debug_optimize%': '0',
588 },
[email protected]3aacaf952009-04-02 15:34:09589 'defines': [
590 '_DEBUG',
591 ],
592 'cflags': [
[email protected]22898f62009-10-26 22:14:01593 '-O>(debug_optimize)',
[email protected]3aacaf952009-04-02 15:34:09594 '-g',
[email protected]9a5d2a52009-05-22 03:37:45595 # One can use '-gstabs' to enable building the debugging
596 # information in STABS format for breakpad's dumpsyms.
[email protected]3aacaf952009-04-02 15:34:09597 ],
[email protected]96fd0032009-04-24 00:13:08598 'ldflags': [
599 '-rdynamic', # Allows backtrace to resolve symbols.
600 ],
[email protected]5315f2842009-04-28 00:43:27601 },
[email protected]3aacaf952009-04-02 15:34:09602 'Release': {
[email protected]740e2de2009-07-21 11:41:01603 'variables': {
604 'release_optimize%': '2',
605 },
[email protected]3aacaf952009-04-02 15:34:09606 'cflags': [
[email protected]22898f62009-10-26 22:14:01607 '-O>(release_optimize)',
[email protected]d8cc3a62009-04-08 18:29:53608 # Don't emit the GCC version ident directives, they just end up
609 # in the .comment section taking up binary size.
610 '-fno-ident',
611 # Put data and code in their own sections, so that unused symbols
612 # can be removed at link time with --gc-sections.
613 '-fdata-sections',
614 '-ffunction-sections',
[email protected]3aacaf952009-04-02 15:34:09615 ],
[email protected]3a48e0542009-11-18 17:07:13616 'ldflags': [
617 '-Wl,--gc-sections',
618 ],
[email protected]3aacaf952009-04-02 15:34:09619 },
620 },
[email protected]601b540222009-04-03 21:32:04621 'variants': {
622 'coverage': {
623 'cflags': ['-fprofile-arcs', '-ftest-coverage'],
624 'ldflags': ['-fprofile-arcs'],
625 },
626 'profile': {
627 'cflags': ['-pg', '-g'],
628 'ldflags': ['-pg'],
629 },
630 'symbols': {
631 'cflags': ['-g'],
632 },
633 },
[email protected]606116d22009-05-06 22:38:23634 'conditions': [
[email protected]7e8eb7612009-07-29 15:56:00635 [ 'target_arch=="ia32"', {
[email protected]606116d22009-05-06 22:38:23636 'asflags': [
637 # Needed so that libs with .s files (e.g. libicudata.a)
638 # are compatible with the general 32-bit-ness.
639 '-32',
640 ],
641 # All floating-point computations on x87 happens in 80-bit
642 # precision. Because the C and C++ language standards allow
643 # the compiler to keep the floating-point values in higher
644 # precision than what's specified in the source and doing so
645 # is more efficient than constantly rounding up to 64-bit or
646 # 32-bit precision as specified in the source, the compiler,
647 # especially in the optimized mode, tries very hard to keep
648 # values in x87 floating-point stack (in 80-bit precision)
649 # as long as possible. This has important side effects, that
650 # the real value used in computation may change depending on
651 # how the compiler did the optimization - that is, the value
652 # kept in 80-bit is different than the value rounded down to
653 # 64-bit or 32-bit. There are possible compiler options to make
654 # this behavior consistent (e.g. -ffloat-store would keep all
655 # floating-values in the memory, thus force them to be rounded
656 # to its original precision) but they have significant runtime
657 # performance penalty.
658 #
659 # -mfpmath=sse -msse2 makes the compiler use SSE instructions
660 # which keep floating-point values in SSE registers in its
661 # native precision (32-bit for single precision, and 64-bit for
662 # double precision values). This means the floating-point value
663 # used during computation does not change depending on how the
664 # compiler optimized the code, since the value is always kept
665 # in its specified precision.
[email protected]ffde7932009-05-29 00:39:06666 'conditions': [
667 ['branding=="Chromium"', {
668 'cflags': [
669 '-march=pentium4',
670 '-msse2',
671 '-mfpmath=sse',
672 ],
673 }],
674 ],
[email protected]606116d22009-05-06 22:38:23675 'cflags': [
676 '-m32',
[email protected]1c6560af2009-07-14 11:02:16677 ],
[email protected]606116d22009-05-06 22:38:23678 'ldflags': [
679 '-m32',
680 ],
681 }],
[email protected]3dda8a962009-08-10 18:58:07682 ['target_arch=="arm"', {
[email protected]dc9711f2009-11-13 19:30:25683 'conditions': [
684 ['armv7==1', {
685 'target_conditions': [
686 ['_toolset=="target"', {
687 'cflags': [
688 '-march=armv7-a',
689 '-mtune=cortex-a8',
690 '-mfpu=neon',
691 '-mfloat-abi=softfp',
692 ],
693 }],
[email protected]3dda8a962009-08-10 18:58:07694 ],
695 }],
696 ],
697 }],
[email protected]ee28c9f2009-09-04 01:53:01698 ['sysroot!=""', {
[email protected]fd36ce822009-10-28 20:13:57699 'target_conditions': [
700 ['_toolset=="target"', {
701 'cflags': [
702 '--sysroot=<(sysroot)',
703 ],
704 'ldflags': [
705 '--sysroot=<(sysroot)',
706 ],
707 }]]
[email protected]ee28c9f2009-09-04 01:53:01708 }],
[email protected]cc4219a2009-08-14 05:30:52709 ['no_strict_aliasing==1', {
710 'cflags': [
711 '-fno-strict-aliasing',
712 ],
713 }],
[email protected]cbd5fd52009-08-26 00:14:27714 ['linux_breakpad==1', {
715 'cflags': [ '-gstabs' ],
716 'defines': ['USE_LINUX_BREAKPAD'],
717 }],
[email protected]7cd2afd2009-10-27 21:40:26718 ['library=="shared_library"', {
719 # When building with shared libraries, remove the visiblity-hiding
720 # flag.
721 'cflags!': [ '-fvisibility=hidden' ],
[email protected]4907ac42009-11-02 20:32:51722 'conditions': [
[email protected]08be8a72009-11-18 20:35:54723 ['target_arch=="x64" or target_arch=="arm"', {
724 # Shared libraries need -fPIC on x86-64 and arm
[email protected]4907ac42009-11-02 20:32:51725 'cflags': ['-fPIC']
726 }]
727 ],
[email protected]7cd2afd2009-10-27 21:40:26728 }],
[email protected]01699e22009-11-11 19:24:24729 ['linux_use_tcmalloc==1', {
730 'defines': ['LINUX_USE_TCMALLOC'],
731 }],
[email protected]606116d22009-05-06 22:38:23732 ],
[email protected]9d384032009-03-20 23:13:26733 },
734 }],
[email protected]2f80c312009-02-25 21:26:55735 ['OS=="mac"', {
736 'target_defaults': {
[email protected]24700642009-06-01 16:01:20737 'variables': {
738 # This should be 'mac_real_dsym%', but there seems to be a bug
739 # with % in variables that are intended to be set to different
740 # values in different targets, like this one.
741 'mac_real_dsym': 0, # Fake .dSYMs are fine in most cases.
742 },
[email protected]d92c7c012009-03-19 19:26:42743 'mac_bundle': 0,
[email protected]2f80c312009-02-25 21:26:55744 'xcode_settings': {
745 'ALWAYS_SEARCH_USER_PATHS': 'NO',
[email protected]ab2956372009-08-13 18:11:04746 'GCC_C_LANGUAGE_STANDARD': 'c99', # -std=c99
747 'GCC_CW_ASM_SYNTAX': 'NO', # No -fasm-blocks
748 'GCC_DYNAMIC_NO_PIC': 'NO', # No -mdynamic-no-pic
749 # (Equivalent to -fPIC)
750 'GCC_ENABLE_CPP_EXCEPTIONS': 'NO', # -fno-exceptions
751 'GCC_ENABLE_CPP_RTTI': 'NO', # -fno-rtti
752 'GCC_ENABLE_PASCAL_STRINGS': 'NO', # No -mpascal-strings
[email protected]3224dcd2009-09-16 17:31:25753 # GCC_INLINES_ARE_PRIVATE_EXTERN maps to -fvisibility-inlines-hidden
754 'GCC_INLINES_ARE_PRIVATE_EXTERN': 'YES',
[email protected]ab2956372009-08-13 18:11:04755 'GCC_OBJC_CALL_CXX_CDTORS': 'YES', # -fobjc-call-cxx-cdtors
756 'GCC_SYMBOLS_PRIVATE_EXTERN': 'YES', # -fvisibility=hidden
757 'GCC_THREADSAFE_STATICS': 'NO', # -fno-threadsafe-statics
758 'GCC_TREAT_WARNINGS_AS_ERRORS': 'YES', # -Werror
[email protected]2f80c312009-02-25 21:26:55759 'GCC_VERSION': '4.2',
[email protected]ab2956372009-08-13 18:11:04760 'GCC_WARN_ABOUT_MISSING_NEWLINE': 'YES', # -Wnewline-eof
[email protected]3224dcd2009-09-16 17:31:25761 # MACOSX_DEPLOYMENT_TARGET maps to -mmacosx-version-min
762 'MACOSX_DEPLOYMENT_TARGET': '<(mac_deployment_target)',
[email protected]ab2956372009-08-13 18:11:04763 'PREBINDING': 'NO', # No -Wl,-prebind
[email protected]2f80c312009-02-25 21:26:55764 'USE_HEADERMAP': 'NO',
765 'WARNING_CFLAGS': ['-Wall', '-Wendif-labels'],
[email protected]b3fb8092009-03-12 19:09:24766 'conditions': [
767 ['chromium_mac_pch', {'GCC_PRECOMPILE_PREFIX_HEADER': 'YES'},
[email protected]9543af052009-09-15 22:42:59768 {'GCC_PRECOMPILE_PREFIX_HEADER': 'NO'}
769 ],
[email protected]b3fb8092009-03-12 19:09:24770 ],
[email protected]2f80c312009-02-25 21:26:55771 },
772 'target_conditions': [
[email protected]2f80c312009-02-25 21:26:55773 ['_type!="static_library"', {
[email protected]5d7dc972009-04-16 15:30:46774 'xcode_settings': {'OTHER_LDFLAGS': ['-Wl,-search_paths_first']},
775 }],
776 ['_mac_bundle', {
777 'xcode_settings': {'OTHER_LDFLAGS': ['-Wl,-ObjC']},
[email protected]87fde4a2009-02-28 00:50:08778 }],
[email protected]e14a9f92009-08-05 19:26:07779 ['_type=="executable" or _type=="shared_library"', {
[email protected]24700642009-06-01 16:01:20780 'target_conditions': [
781 ['mac_real_dsym == 1', {
782 # To get a real .dSYM bundle produced by dsymutil, set the
783 # debug information format to dwarf-with-dsym. Since
784 # strip_from_xcode will not be used, set Xcode to do the
785 # stripping as well.
786 'configurations': {
787 'Release': {
788 'xcode_settings': {
789 'DEBUG_INFORMATION_FORMAT': 'dwarf-with-dsym',
790 'DEPLOYMENT_POSTPROCESSING': 'YES',
791 'STRIP_INSTALLED_PRODUCT': 'YES',
[email protected]e14a9f92009-08-05 19:26:07792 'target_conditions': [
793 ['_type=="shared_library"', {
794 # The Xcode default is to strip debugging symbols
795 # only (-S). Local symbols should be stripped as
796 # well, which will be handled by -x. Xcode will
797 # continue to insert -S when stripping even when
798 # additional flags are added with STRIPFLAGS.
799 'STRIPFLAGS': '-x',
800 }], # _type=="shared_library"
801 ], # target_conditions
802 }, # xcode_settings
803 }, # configuration "Release"
804 }, # configurations
[email protected]24700642009-06-01 16:01:20805 }, { # mac_real_dsym != 1
806 # To get a fast fake .dSYM bundle, use a post-build step to
807 # produce the .dSYM and strip the executable. strip_from_xcode
808 # only operates in the Release configuration.
809 'postbuilds': [
810 {
811 'variables': {
812 # Define strip_from_xcode in a variable ending in _path
813 # so that gyp understands it's a path and performs proper
814 # relativization during dict merging.
815 'strip_from_xcode_path': 'mac/strip_from_xcode',
816 },
817 'postbuild_name': 'Strip If Needed',
818 'action': ['<(strip_from_xcode_path)'],
819 },
[email protected]e14a9f92009-08-05 19:26:07820 ], # postbuilds
821 }], # mac_real_dsym
822 ], # target_conditions
823 }], # _type=="executable" or _type=="shared_library"
824 ], # target_conditions
825 }, # target_defaults
826 }], # OS=="mac"
[email protected]2f80c312009-02-25 21:26:55827 ['OS=="win"', {
828 'target_defaults': {
829 'defines': [
830 '_WIN32_WINNT=0x0600',
831 'WINVER=0x0600',
832 'WIN32',
833 '_WINDOWS',
834 '_HAS_EXCEPTIONS=0',
835 'NOMINMAX',
836 '_CRT_RAND_S',
837 'CERT_CHAIN_PARA_HAS_EXTRA_FIELDS',
838 'WIN32_LEAN_AND_MEAN',
839 '_SECURE_ATL',
[email protected]adfb98c2009-06-23 20:08:45840 '_HAS_TR1=0',
[email protected]2f80c312009-02-25 21:26:55841 ],
[email protected]5b5ca7cb2009-07-20 23:00:20842 'msvs_system_include_dirs': [
[email protected]2f80c312009-02-25 21:26:55843 '<(DEPTH)/third_party/platformsdk_win2008_6_1/files/Include',
844 '$(VSInstallDir)/VC/atlmfc/include',
845 ],
[email protected]a8d99cef2009-08-26 20:47:49846 'msvs_cygwin_dirs': ['<(DEPTH)/third_party/cygwin'],
[email protected]6840561772009-05-12 16:37:55847 'msvs_disabled_warnings': [4396, 4503, 4819],
[email protected]2f80c312009-02-25 21:26:55848 'msvs_settings': {
849 'VCCLCompilerTool': {
850 'MinimalRebuild': 'false',
851 'ExceptionHandling': '0',
852 'BufferSecurityCheck': 'true',
853 'EnableFunctionLevelLinking': 'true',
854 'RuntimeTypeInfo': 'false',
855 'WarningLevel': '3',
856 'WarnAsError': 'true',
857 'DebugInformationFormat': '3',
[email protected]3fef6e62009-07-31 19:58:58858 'conditions': [
[email protected]912c55c2009-07-31 23:33:55859 [ 'msvs_multi_core_compile', {
860 'AdditionalOptions': '/MP',
861 }],
[email protected]3fef6e62009-07-31 19:58:58862 ],
[email protected]2f80c312009-02-25 21:26:55863 },
864 'VCLibrarianTool': {
865 'AdditionalOptions': '/ignore:4221',
[email protected]2f80c312009-02-25 21:26:55866 'AdditionalLibraryDirectories':
[email protected]07506b502009-06-29 00:30:51867 ['<(DEPTH)/third_party/platformsdk_win2008_6_1/files/Lib'],
[email protected]2f80c312009-02-25 21:26:55868 },
869 'VCLinkerTool': {
[email protected]2f80c312009-02-25 21:26:55870 'AdditionalDependencies': [
871 'wininet.lib',
872 'version.lib',
873 'msimg32.lib',
874 'ws2_32.lib',
875 'usp10.lib',
876 'psapi.lib',
[email protected]96fd0032009-04-24 00:13:08877 'dbghelp.lib',
[email protected]2f80c312009-02-25 21:26:55878 ],
879 'AdditionalLibraryDirectories':
[email protected]07506b502009-06-29 00:30:51880 ['<(DEPTH)/third_party/platformsdk_win2008_6_1/files/Lib'],
[email protected]2f80c312009-02-25 21:26:55881 'GenerateDebugInformation': 'true',
882 'MapFileName': '$(OutDir)\\$(TargetName).map',
883 'ImportLibrary': '$(OutDir)\\lib\\$(TargetName).lib',
884 'TargetMachine': '1',
885 'FixedBaseAddress': '1',
[email protected]825ff8d2009-05-22 01:40:48886 # SubSystem values:
887 # 0 == not set
888 # 1 == /SUBSYSTEM:CONSOLE
889 # 2 == /SUBSYSTEM:WINDOWS
890 # Most of the executables we'll ever create are tests
891 # and utilities with console output.
892 'SubSystem': '1',
[email protected]2f80c312009-02-25 21:26:55893 },
894 'VCMIDLTool': {
895 'GenerateStublessProxies': 'true',
896 'TypeLibraryName': '$(InputName).tlb',
897 'OutputDirectory': '$(IntDir)',
898 'HeaderFileName': '$(InputName).h',
899 'DLLDataFileName': 'dlldata.c',
900 'InterfaceIdentifierFileName': '$(InputName)_i.c',
901 'ProxyFileName': '$(InputName)_p.c',
902 },
903 'VCResourceCompilerTool': {
904 'Culture' : '1033',
[email protected]245b3cd592009-03-31 01:12:14905 'AdditionalIncludeDirectories': ['<(DEPTH)'],
[email protected]2f80c312009-02-25 21:26:55906 },
907 },
908 },
909 }],
910 ['chromium_code==0', {
911 # This section must follow the other conditon sections above because
912 # external_code.gypi expects to be merged into those settings.
913 'includes': [
914 'external_code.gypi',
915 ],
[email protected]dce5df52009-06-29 17:58:25916 }, {
917 'target_defaults': {
918 # In Chromium code, we define __STDC_FORMAT_MACROS in order to get the
919 # C99 macros on Mac and Linux.
920 'defines': [
921 '__STDC_FORMAT_MACROS',
922 ],
923 },
[email protected]2f80c312009-02-25 21:26:55924 }],
[email protected]d8c7cbcc2009-10-02 19:00:31925 ['disable_nacl==1', {
926 'target_defaults': {
927 'defines': [
928 'DISABLE_NACL',
929 ],
930 },
931 }],
[email protected]48c7af72009-07-03 22:00:19932 ['msvs_use_common_linker_extras', {
933 'target_defaults': {
934 'msvs_settings': {
935 'VCLinkerTool': {
936 'AdditionalOptions':
937 '/safeseh /dynamicbase /ignore:4199 /ignore:4221 /nxcompat',
938 'DelayLoadDLLs': [
939 'dbghelp.dll',
940 'dwmapi.dll',
941 'uxtheme.dll',
942 ],
943 },
944 },
945 },
946 }],
[email protected]2f80c312009-02-25 21:26:55947 ],
[email protected]c13fcbd2009-03-27 04:27:01948 'scons_settings': {
949 'sconsbuild_dir': '<(DEPTH)/sconsbuild',
[email protected]a8b56d92009-08-10 04:09:07950 'tools': ['ar', 'as', 'gcc', 'g++', 'gnulink', 'chromium_builders'],
[email protected]c13fcbd2009-03-27 04:27:01951 },
[email protected]2f80c312009-02-25 21:26:55952 'xcode_settings': {
[email protected]0c8ab452009-11-06 21:57:50953 # DON'T ADD ANYTHING NEW TO THIS BLOCK UNLESS YOU REALLY REALLY NEED IT!
954 # This block adds *project-wide* configuration settings to each project
955 # file. It's almost always wrong to put things here. Specify your
956 # custom xcode_settings in target_defaults to add them to targets instead.
957
958 # In an Xcode Project Info window, the "Base SDK for All Configurations"
959 # setting sets the SDK on a project-wide basis. In order to get the
960 # configured SDK to show properly in the Xcode UI, SDKROOT must be set
961 # here at the project level.
962 'SDKROOT': 'macosx<(mac_sdk)', # -isysroot
963
[email protected]2f80c312009-02-25 21:26:55964 # The Xcode generator will look for an xcode_settings section at the root
965 # of each dict and use it to apply settings on a file-wide basis. Most
966 # settings should not be here, they should be in target-specific
967 # xcode_settings sections, or better yet, should use non-Xcode-specific
968 # settings in target dicts. SYMROOT is a special case, because many other
969 # Xcode variables depend on it, including variables such as
970 # PROJECT_DERIVED_FILE_DIR. When a source group corresponding to something
971 # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the
972 # files to appear (when present) in the UI as actual files and not red
973 # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR,
974 # and therefore SYMROOT, needs to be set at the project level.
[email protected]bfa24b962009-03-02 00:16:16975 'SYMROOT': '<(DEPTH)/xcodebuild',
[email protected]2f80c312009-02-25 21:26:55976 },
[email protected]ee28c9f2009-09-04 01:53:01977}
[email protected]f5c990c2009-10-06 03:02:38978
979# Local Variables:
980# tab-width:2
981# indent-tabs-mode:nil
982# End:
983# vim: set expandtab tabstop=2 shiftwidth=2: