| OLD | NEW | 
|    1 # Copyright (c) 2009 The Chromium Authors. All rights reserved. |    1 # 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 |    2 # Use of this source code is governed by a BSD-style license that can be | 
|    3 # found in the LICENSE file. |    3 # found in the LICENSE file. | 
|    4  |    4  | 
|    5 { |    5 { | 
|    6   'variables': { |    6   'variables': { | 
|    7     # .gyp files should set chromium_code to 1 if they build Chromium-specific |    7     # .gyp files should set chromium_code to 1 if they build Chromium-specific | 
|    8     # code, as opposed to external code.  This variable is used to control |    8     # code, as opposed to external code.  This variable is used to control | 
|    9     # such things as the set of warnings to enable, and whether warnings are |    9     # such things as the set of warnings to enable, and whether warnings are | 
|   10     # treated as errors. |   10     # treated as errors. | 
|   11     'chromium_code%': 0, |   11     'chromium_code%': 0, | 
|   12  |   12  | 
|   13     # Variables expected to be overriden on the GYP command line (-D) or by |   13     # Variables expected to be overriden on the GYP command line (-D) or by | 
|   14     # ~/.gyp/include.gypi. |   14     # ~/.gyp/include.gypi. | 
|   15  |   15  | 
|   16     # Override chromium_mac_pch and set it to 0 to suppress the use of |   16     # Override chromium_mac_pch and set it to 0 to suppress the use of | 
|   17     # precompiled headers on the Mac.  Prefix header injection may still be |   17     # precompiled headers on the Mac.  Prefix header injection may still be | 
|   18     # used, but prefix headers will not be precompiled.  This is useful when |   18     # used, but prefix headers will not be precompiled.  This is useful when | 
|   19     # using distcc to distribute a build to compile slaves that don't |   19     # using distcc to distribute a build to compile slaves that don't | 
|   20     # share the same compiler executable as the system driving the compilation, |   20     # share the same compiler executable as the system driving the compilation, | 
|   21     # because precompiled headers rely on pointers into a specific compiler |   21     # because precompiled headers rely on pointers into a specific compiler | 
|   22     # executable's image.  Setting this to 0 is needed to use an experimental |   22     # executable's image.  Setting this to 0 is needed to use an experimental | 
|   23     # Linux-Mac cross compiler distcc farm. |   23     # Linux-Mac cross compiler distcc farm. | 
|   24     'chromium_mac_pch%': 1, |   24     'chromium_mac_pch%': 1, | 
|   25  |   25  | 
|   26     # Override branding to select the desired branding flavor. |   26     # Override branding to select the desired branding flavor. | 
|   27     'branding%': 'Chromium', |   27     'branding%': 'Chromium', | 
 |   28  | 
 |   29     # Set to 1 to enable code coverage.  In addition to build changes | 
 |   30     # (e.g. extra CFLAGS), also creates a new target in the src/chrome | 
 |   31     # project file called "coverage". | 
 |   32     # Currently ignored on Windows. | 
 |   33     'coverage%': 0, | 
|   28   }, |   34   }, | 
|   29   'target_defaults': { |   35   'target_defaults': { | 
|   30     'conditions': [ |   36     'conditions': [ | 
|   31       ['branding=="Chrome"', { |   37       ['branding=="Chrome"', { | 
|   32         'defines': ['GOOGLE_CHROME_BUILD'], |   38         'defines': ['GOOGLE_CHROME_BUILD'], | 
|   33       }, {  # else: branding!="Chrome" |   39       }, {  # else: branding!="Chrome" | 
|   34         'defines': ['CHROMIUM_BUILD'], |   40         'defines': ['CHROMIUM_BUILD'], | 
|   35       }], |   41       }], | 
 |   42       ['coverage!=0', { | 
 |   43         'conditions': [ | 
 |   44           ['OS=="mac"', { | 
 |   45             'xcode_settings': { | 
 |   46               'GCC_INSTRUMENT_PROGRAM_FLOW_ARCS': 'YES', | 
 |   47               'GCC_GENERATE_TEST_COVERAGE_FILES': 'YES', | 
 |   48             }, | 
 |   49             # Add -lgcov for executables, not for static_libraries. | 
 |   50             # This is a delayed conditional. | 
 |   51             'target_conditions': [ | 
 |   52               ['_type=="executable"', { | 
 |   53                 'xcode_settings': { 'OTHER_LDFLAGS': [ '-lgcov' ] }, | 
 |   54               }], | 
 |   55             ], | 
 |   56           }], | 
 |   57           # TODO(jrg): complete this work once Linux transitions to gyp. | 
 |   58           # This is untested (--> likely doesn't work). | 
 |   59           ['OS=="linux"', { | 
 |   60             'cflags': [ '-ftest-coverage', | 
 |   61                         '-fprofile-arcs' ], | 
 |   62             'target_conditions': [ | 
 |   63               ['_type=="executable"', { | 
 |   64                 'link_settings': { 'libraries': [ '-lgcov' ] }, | 
 |   65               }], | 
 |   66             ], | 
 |   67           }], | 
 |   68         ]}, | 
 |   69       # TODO(jrg): options for code coverage on Windows | 
 |   70       ], | 
|   36     ], |   71     ], | 
|   37     'default_configuration': 'Debug', |   72     'default_configuration': 'Debug', | 
|   38     'configurations': { |   73     'configurations': { | 
|   39       'Debug': { |   74       'Debug': { | 
|   40         'conditions': [ |   75         'conditions': [ | 
|   41           [ 'OS=="mac"', { |   76           [ 'OS=="mac"', { | 
|   42             'xcode_settings': { |   77             'xcode_settings': { | 
|   43               'COPY_PHASE_STRIP': 'NO', |   78               'COPY_PHASE_STRIP': 'NO', | 
|   44               'GCC_OPTIMIZATION_LEVEL': '0', |   79               'GCC_OPTIMIZATION_LEVEL': '0', | 
|   45             } |   80             } | 
| (...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  334     # settings in target dicts.  SYMROOT is a special case, because many other |  369     # settings in target dicts.  SYMROOT is a special case, because many other | 
|  335     # Xcode variables depend on it, including variables such as |  370     # Xcode variables depend on it, including variables such as | 
|  336     # PROJECT_DERIVED_FILE_DIR.  When a source group corresponding to something |  371     # PROJECT_DERIVED_FILE_DIR.  When a source group corresponding to something | 
|  337     # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the |  372     # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the | 
|  338     # files to appear (when present) in the UI as actual files and not red |  373     # files to appear (when present) in the UI as actual files and not red | 
|  339     # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR, |  374     # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR, | 
|  340     # and therefore SYMROOT, needs to be set at the project level. |  375     # and therefore SYMROOT, needs to be set at the project level. | 
|  341     'SYMROOT': '<(DEPTH)/xcodebuild', |  376     'SYMROOT': '<(DEPTH)/xcodebuild', | 
|  342   }, |  377   }, | 
|  343 } |  378 } | 
| OLD | NEW |