Chromium Code Reviews| Index: build/common.gypi |
| diff --git a/build/common.gypi b/build/common.gypi |
| index 708e12c2aa3f6ae9ff536f5c7a71f33ca6d4f34f..2700b546c90387bbbff4b3fe32e99c5c3ff25b3e 100644 |
| --- a/build/common.gypi |
| +++ b/build/common.gypi |
| @@ -346,6 +346,10 @@ |
| # by the GYP command line or by ~/.gyp/include.gypi. |
| 'component%': 'static_library', |
| + # /analyze is off by default on Windows because it is very slow and noisy. |
| + # Enable with GYP_DEFINES=win_analyze=1 |
| + 'win_analyze%': 0, |
| + |
| # Set to select the Title Case versions of strings in GRD files. |
| 'use_titlecase_in_grd%': 0, |
| @@ -1108,6 +1112,7 @@ |
| 'chroot_cmd%': '<(chroot_cmd)', |
| 'system_libdir%': '<(system_libdir)', |
| 'component%': '<(component)', |
| + 'win_analyze%': '<(win_analyze)', |
| 'enable_resource_whitelist_generation%': '<(enable_resource_whitelist_generation)', |
| 'use_titlecase_in_grd%': '<(use_titlecase_in_grd)', |
| 'use_third_party_translations%': '<(use_third_party_translations)', |
| @@ -2803,9 +2808,15 @@ |
| 'VCCLCompilerTool': { |
| 'DebugInformationFormat': '1', |
| } |
| - } |
| + } # win_z7!=0 |
| }], |
| - ], # win_z7!=0 |
| + ['win_analyze', { |
| + 'defines!': [ |
| + # This is prohibited when running /analyze. |
| + '_USING_V110_SDK71_', |
| + ], |
| + }], # win_analyze |
| + ], |
| }], # OS==win |
| ['chromecast==1', { |
| 'defines': [ |
| @@ -3210,6 +3221,32 @@ |
| # "/Oy /Oy-" and warnings about overriding. |
| 'AdditionalOptions': ['/Oy-'], |
| }], |
| + ['win_analyze', { |
|
scottmg
2014/10/28 00:36:14
do you mean for this to be inside Debug_Base? (i w
|
| + # Set WarnAsError to false to disable this setting for most |
| + # projects so that compilation continues. |
| + 'WarnAsError': 'false', |
| + # When win_analye is specified add the /analyze switch. |
|
scottmg
2014/10/28 00:38:38
"win_analye" -> "win_analyze"
|
| + # Also add /WX- to force-disable WarnAsError for projects that |
| + # override WarnAsError. |
| + # Also, disable various noisy warnings that have low value. |
| + 'AdditionalOptions': [ |
| + '/analyze', |
| + '/WX-', |
| + '/wd6011', # Dereferencing NULL pointer |
| + '/wd6312', # Possible infinite loop: use of the constant |
| + # EXCEPTION_CONTINUE_EXECUTION in the exception-filter |
| + '/wd6326', # Potential comparison of constant with constant |
| + '/wd28159', # Consider using 'GetTickCount64' |
| + '/wd28204', # Inconsistent SAL annotations |
| + '/wd28251', # Inconsistent SAL annotations |
| + '/wd28252', # Inconsistent SAL annotations |
| + '/wd28253', # Inconsistent SAL annotations |
| + '/wd28196', # The precondition is not satisfied |
| + '/wd28301', # Inconsistent SAL annotations |
| + '/wd6340', # Sign mismatch in function parameter |
| + '/wd28182', # Dereferencing NULL pointer |
| + ], |
| + }], |
| ], |
| 'AdditionalOptions': [ '<@(win_debug_extra_cflags)', ], |
| }, |