OLD | NEW |
(Empty) | |
| 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 |
| 3 # found in the LICENSE file. |
| 4 |
| 5 { |
| 6 'variables': { |
| 7 'chromium_code%': 0, |
| 8 }, |
| 9 'target_defaults': { |
| 10 # TODO(bradnelson): This should really be able to be either: |
| 11 # CHROMIUM_BUILD or GOOGLE_CHROME_BUILD |
| 12 'defines': ['CHROMIUM_BUILD'], |
| 13 'default_configuration': 'Debug', |
| 14 'configurations': { |
| 15 'Debug': { |
| 16 'conditions': [ |
| 17 [ 'OS=="mac"', { |
| 18 'xcode_settings': { |
| 19 'COPY_PHASE_STRIP': 'NO', |
| 20 'GCC_OPTIMIZATION_LEVEL': '0', |
| 21 } |
| 22 }], |
| 23 [ 'OS=="win"', { |
| 24 'configuration_platform': 'Win32', |
| 25 'msvs_configuration_attributes': { |
| 26 'OutputDirectory': '$(SolutionDir)$(ConfigurationName)', |
| 27 'IntermediateDirectory': '$(OutDir)\\obj\\$(ProjectName)', |
| 28 'CharacterSet': '1', |
| 29 }, |
| 30 'msvs_settings': { |
| 31 'VCCLCompilerTool': { |
| 32 'Optimization': '0', |
| 33 'PreprocessorDefinitions': ['_DEBUG'], |
| 34 'BasicRuntimeChecks': '3', |
| 35 'RuntimeLibrary': '1', |
| 36 }, |
| 37 'VCLinkerTool': { |
| 38 'LinkIncremental': '1', |
| 39 }, |
| 40 'VCResourceCompilerTool': { |
| 41 'PreprocessorDefinitions': ['_DEBUG'], |
| 42 }, |
| 43 }, |
| 44 }], |
| 45 ], |
| 46 }, |
| 47 'Release': { |
| 48 'defines': [ |
| 49 'NDEBUG', |
| 50 ], |
| 51 'conditions': [ |
| 52 [ 'OS=="mac"', { |
| 53 'xcode_settings': { |
| 54 'DEAD_CODE_STRIPPING': 'YES', |
| 55 } |
| 56 }], |
| 57 [ 'OS=="win"', { |
| 58 'configuration_platform': 'Win32', |
| 59 'msvs_props': ['release.vsprops'], |
| 60 }], |
| 61 ], |
| 62 }, |
| 63 }, |
| 64 }, |
| 65 'conditions': [ |
| 66 ['OS=="mac"', { |
| 67 'target_defaults': { |
| 68 'xcode_settings': { |
| 69 'ALWAYS_SEARCH_USER_PATHS': 'NO', |
| 70 'GCC_C_LANGUAGE_STANDARD': 'c99', |
| 71 'GCC_CW_ASM_SYNTAX': 'NO', |
| 72 'GCC_DYNAMIC_NO_PIC': 'YES', |
| 73 'GCC_ENABLE_PASCAL_STRINGS': 'NO', |
| 74 'GCC_INLINES_ARE_PRIVATE_EXTERN': 'YES', |
| 75 'GCC_PRECOMPILE_PREFIX_HEADER': 'YES', |
| 76 'GCC_SYMBOLS_PRIVATE_EXTERN': 'YES', |
| 77 'GCC_TREAT_WARNINGS_AS_ERRORS': 'YES', |
| 78 'GCC_VERSION': '4.2', |
| 79 'GCC_WARN_ABOUT_MISSING_NEWLINE': 'YES', |
| 80 'MACOSX_DEPLOYMENT_TARGET': '10.5', |
| 81 'PREBINDING': 'NO', |
| 82 'SDKROOT': 'macosx10.5', |
| 83 'USE_HEADERMAP': 'NO', |
| 84 'WARNING_CFLAGS': ['-Wall', '-Wendif-labels'], |
| 85 }, |
| 86 'target_conditions': [ |
| 87 ['_type=="shared_library"', { |
| 88 'xcode_settings': {'GCC_DYNAMIC_NO_PIC': 'NO'}, |
| 89 }], |
| 90 ['_type!="static_library"', { |
| 91 'xcode_settings': {'OTHER_LDFLAGS': ['-Wl,-search_paths_first']}, |
| 92 }], |
| 93 ['_type=="application" or _type=="executable"', { |
| 94 'postbuilds': [ |
| 95 { |
| 96 'variables': { |
| 97 # Define strip_from_xcode in a variable ending in _path so |
| 98 # that gyp understands it's a path and performs proper |
| 99 # relativization during dict merging. |
| 100 'strip_from_xcode_path': 'mac/strip_from_xcode', |
| 101 }, |
| 102 'postbuild_name': 'Strip If Needed', |
| 103 'action': ['<(strip_from_xcode_path)'], |
| 104 }, |
| 105 ], |
| 106 }], |
| 107 ], |
| 108 }, |
| 109 }], |
| 110 ['OS=="win"', { |
| 111 'target_defaults': { |
| 112 'defines': [ |
| 113 '_WIN32_WINNT=0x0600', |
| 114 'WINVER=0x0600', |
| 115 'WIN32', |
| 116 '_WINDOWS', |
| 117 '_HAS_EXCEPTIONS=0', |
| 118 'NOMINMAX', |
| 119 '_CRT_RAND_S', |
| 120 'CERT_CHAIN_PARA_HAS_EXTRA_FIELDS', |
| 121 'WIN32_LEAN_AND_MEAN', |
| 122 '_SECURE_ATL', |
| 123 '_HAS_TR1=0', |
| 124 ], |
| 125 'include_dirs': [ |
| 126 '<(DEPTH)/third_party/platformsdk_win2008_6_1/files/Include', |
| 127 '$(VSInstallDir)/VC/atlmfc/include', |
| 128 ], |
| 129 'msvs_cygwin_dirs': ['../third_party/cygwin'], |
| 130 'msvs_disabled_warnings': [4503, 4819], |
| 131 'msvs_settings': { |
| 132 'VCCLCompilerTool': { |
| 133 'MinimalRebuild': 'false', |
| 134 'ExceptionHandling': '0', |
| 135 'BufferSecurityCheck': 'true', |
| 136 'EnableFunctionLevelLinking': 'true', |
| 137 'RuntimeTypeInfo': 'false', |
| 138 'WarningLevel': '3', |
| 139 'WarnAsError': 'true', |
| 140 'DebugInformationFormat': '3', |
| 141 }, |
| 142 'VCLibrarianTool': { |
| 143 'AdditionalOptions': '/ignore:4221', |
| 144 'OutputFile': '$(OutDir)\\lib\\$(ProjectName).lib', |
| 145 'AdditionalLibraryDirectories': |
| 146 '<(DEPTH)/third_party/platformsdk_win2008_6_1/files/Lib', |
| 147 }, |
| 148 'VCLinkerTool': { |
| 149 'AdditionalOptions': |
| 150 '/safeseh /dynamicbase /ignore:4199 /ignore:4221 /nxcompat', |
| 151 'AdditionalDependencies': [ |
| 152 'wininet.lib', |
| 153 'version.lib', |
| 154 'msimg32.lib', |
| 155 'ws2_32.lib', |
| 156 'usp10.lib', |
| 157 'psapi.lib', |
| 158 ], |
| 159 'AdditionalLibraryDirectories': |
| 160 '<(DEPTH)/third_party/platformsdk_win2008_6_1/files/Lib', |
| 161 'DelayLoadDLLs': 'dwmapi.dll,uxtheme.dll', |
| 162 'GenerateDebugInformation': 'true', |
| 163 'MapFileName': '$(OutDir)\\$(TargetName).map', |
| 164 'ImportLibrary': '$(OutDir)\\lib\\$(TargetName).lib', |
| 165 'TargetMachine': '1', |
| 166 'FixedBaseAddress': '1', |
| 167 }, |
| 168 'VCMIDLTool': { |
| 169 'GenerateStublessProxies': 'true', |
| 170 'TypeLibraryName': '$(InputName).tlb', |
| 171 'OutputDirectory': '$(IntDir)', |
| 172 'HeaderFileName': '$(InputName).h', |
| 173 'DLLDataFileName': 'dlldata.c', |
| 174 'InterfaceIdentifierFileName': '$(InputName)_i.c', |
| 175 'ProxyFileName': '$(InputName)_p.c', |
| 176 }, |
| 177 'VCResourceCompilerTool': { |
| 178 'Culture' : '1033', |
| 179 'AdditionalIncludeDirectories': '<(DEPTH)', |
| 180 }, |
| 181 }, |
| 182 }, |
| 183 }], |
| 184 ['chromium_code==0', { |
| 185 # This section must follow the other conditon sections above because |
| 186 # external_code.gypi expects to be merged into those settings. |
| 187 'includes': [ |
| 188 'external_code.gypi', |
| 189 ], |
| 190 }], |
| 191 ], |
| 192 'xcode_settings': { |
| 193 # The Xcode generator will look for an xcode_settings section at the root |
| 194 # of each dict and use it to apply settings on a file-wide basis. Most |
| 195 # settings should not be here, they should be in target-specific |
| 196 # xcode_settings sections, or better yet, should use non-Xcode-specific |
| 197 # settings in target dicts. SYMROOT is a special case, because many other |
| 198 # Xcode variables depend on it, including variables such as |
| 199 # PROJECT_DERIVED_FILE_DIR. When a source group corresponding to something |
| 200 # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the |
| 201 # files to appear (when present) in the UI as actual files and not red |
| 202 # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR, |
| 203 # and therefore SYMROOT, needs to be set at the project level. |
| 204 # |
| 205 # xcodebuild_gyp is a temporary name to avoid colliding with the xcodebuild |
| 206 # directory used by the non-gyp Xcode build system. When the gyp-based |
| 207 # Xcode build system replaces the older system, this should be changed to |
| 208 # simply "xcodebuild" or some other suitable name. |
| 209 'SYMROOT': '<(DEPTH)/xcodebuild_gyp', |
| 210 }, |
| 211 } |
OLD | NEW |