OLD | NEW |
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 # IMPORTANT: | 5 # IMPORTANT: |
6 # Please don't directly include this file if you are building via gyp_chromium, | 6 # Please don't directly include this file if you are building via gyp_chromium, |
7 # since gyp_chromium is automatically forcing its inclusion. | 7 # since gyp_chromium is automatically forcing its inclusion. |
8 { | 8 { |
9 # Variables expected to be overriden on the GYP command line (-D) or by | 9 # Variables expected to be overriden on the GYP command line (-D) or by |
10 # ~/.gyp/include.gypi. | 10 # ~/.gyp/include.gypi. |
(...skipping 4182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4193 '-Wno-unnamed-type-template-args', | 4193 '-Wno-unnamed-type-template-args', |
4194 # Match OS X clang C++11 warning settings. | 4194 # Match OS X clang C++11 warning settings. |
4195 '-Wno-c++11-narrowing', | 4195 '-Wno-c++11-narrowing', |
4196 ], | 4196 ], |
4197 }, | 4197 }, |
4198 'target_conditions': [ | 4198 'target_conditions': [ |
4199 ['_toolset=="host"', { | 4199 ['_toolset=="host"', { |
4200 'xcode_settings': { | 4200 'xcode_settings': { |
4201 'SDKROOT': 'macosx<(mac_sdk)', # -isysroot | 4201 'SDKROOT': 'macosx<(mac_sdk)', # -isysroot |
4202 'MACOSX_DEPLOYMENT_TARGET': '<(mac_deployment_target)', | 4202 'MACOSX_DEPLOYMENT_TARGET': '<(mac_deployment_target)', |
4203 'ARCHS': [ | |
4204 'x86_64' | |
4205 ], | |
4206 }, | 4203 }, |
| 4204 'conditions': [ |
| 4205 ['"<(GENERATOR)"!="xcode"', { |
| 4206 'xcode_settings': { 'ARCHS': [ 'x86_64' ] }, |
| 4207 }], |
| 4208 ], |
4207 }], | 4209 }], |
4208 ['_toolset=="target"', { | 4210 ['_toolset=="target"', { |
4209 'xcode_settings': { | 4211 'xcode_settings': { |
4210 # This section should be for overriding host settings. But, | 4212 # This section should be for overriding host settings. But, |
4211 # since we can't negate the iphone deployment target above, we | 4213 # since we can't negate the iphone deployment target above, we |
4212 # instead set it here for target only. | 4214 # instead set it here for target only. |
4213 'IPHONEOS_DEPLOYMENT_TARGET': '<(ios_deployment_target)', | 4215 'IPHONEOS_DEPLOYMENT_TARGET': '<(ios_deployment_target)', |
4214 }, | 4216 }, |
| 4217 'conditions': [ |
| 4218 ['target_arch=="armv7" and "<(GENERATOR)"!="xcode"', { |
| 4219 'xcode_settings': { 'ARCHS': [ 'armv7' ]}, |
| 4220 }, { |
| 4221 'xcode_settings': { 'ARCHS': [ 'i386' ] }, |
| 4222 }], |
| 4223 ], |
4215 }], | 4224 }], |
4216 ['_type=="executable"', { | 4225 ['_type=="executable"', { |
4217 'configurations': { | 4226 'configurations': { |
4218 'Release_Base': { | 4227 'Release_Base': { |
4219 'xcode_settings': { | 4228 'xcode_settings': { |
4220 'DEPLOYMENT_POSTPROCESSING': 'YES', | 4229 'DEPLOYMENT_POSTPROCESSING': 'YES', |
4221 'STRIP_INSTALLED_PRODUCT': 'YES', | 4230 'STRIP_INSTALLED_PRODUCT': 'YES', |
4222 }, | 4231 }, |
4223 }, | 4232 }, |
4224 'Debug_Base': { | 4233 'Debug_Base': { |
4225 'xcode_settings': { | 4234 'xcode_settings': { |
4226 # Remove dSYM to reduce build time. | 4235 # Remove dSYM to reduce build time. |
4227 'DEBUG_INFORMATION_FORMAT': 'dwarf', | 4236 'DEBUG_INFORMATION_FORMAT': 'dwarf', |
4228 }, | 4237 }, |
4229 }, | 4238 }, |
4230 }, | 4239 }, |
4231 'xcode_settings': { | 4240 'conditions': [ |
4232 'conditions': [ | 4241 ['"<(GENERATOR)"=="xcode"', { |
4233 ['chromium_ios_signing', { | 4242 'xcode_settings': { |
4234 # iOS SDK wants everything for device signed. | 4243 # TODO(justincohen): ninja builds don't support signing yet. |
4235 'CODE_SIGN_IDENTITY[sdk=iphoneos*]': 'iPhone Developer', | 4244 'conditions': [ |
4236 }, { | 4245 ['chromium_ios_signing', { |
4237 'CODE_SIGNING_REQUIRED': 'NO', | 4246 # iOS SDK wants everything for device signed. |
4238 'CODE_SIGN_IDENTITY[sdk=iphoneos*]': '', | 4247 'CODE_SIGN_IDENTITY[sdk=iphoneos*]': 'iPhone Developer', |
4239 }], | 4248 }, { |
4240 ], | 4249 'CODE_SIGNING_REQUIRED': 'NO', |
4241 }, | 4250 'CODE_SIGN_IDENTITY[sdk=iphoneos*]': '', |
| 4251 }], |
| 4252 ], |
| 4253 }, |
| 4254 }], |
| 4255 ['"<(GENERATOR)"=="xcode" and clang!=1', { |
| 4256 'xcode_settings': { |
| 4257 # It is necessary to link with the -fobjc-arc flag to use |
| 4258 # subscripting on iOS < 6. |
| 4259 'OTHER_LDFLAGS': [ |
| 4260 '-fobjc-arc', |
| 4261 ], |
| 4262 }, |
| 4263 }], |
| 4264 ['clang==1', { |
| 4265 'target_conditions': [ |
| 4266 ['_toolset=="target"', { |
| 4267 'variables': { |
| 4268 'developer_dir': '<!(xcode-select -print-path)', |
| 4269 'arc_toolchain_path': '<(developer_dir)/Toolchains/XcodeDe
fault.xctoolchain/usr/lib/arc', |
| 4270 }, |
| 4271 # It is necessary to force load libarclite from Xcode for |
| 4272 # third_party/llvm-build because libarclite_* is only |
| 4273 # distributed by Xcode. |
| 4274 'conditions': [ |
| 4275 ['"<(GENERATOR)"=="ninja" and target_arch=="armv7"', { |
| 4276 'xcode_settings': { |
| 4277 'OTHER_LDFLAGS': [ |
| 4278 '-force_load', |
| 4279 '<(arc_toolchain_path)/libarclite_iphoneos.a', |
| 4280 ], |
| 4281 }, |
| 4282 }], |
| 4283 ['"<(GENERATOR)"=="ninja" and target_arch!="armv7"', { |
| 4284 'xcode_settings': { |
| 4285 'OTHER_LDFLAGS': [ |
| 4286 '-force_load', |
| 4287 '<(arc_toolchain_path)/libarclite_iphonesimulator.a'
, |
| 4288 ], |
| 4289 }, |
| 4290 }], |
| 4291 # Xcode sets target_arch at compile-time. |
| 4292 ['"<(GENERATOR)"=="xcode"', { |
| 4293 'xcode_settings': { |
| 4294 'OTHER_LDFLAGS[arch=armv7]': [ |
| 4295 '$(inherited)', |
| 4296 '-force_load', |
| 4297 '<(arc_toolchain_path)/libarclite_iphoneos.a', |
| 4298 ], |
| 4299 'OTHER_LDFLAGS[arch=i386]': [ |
| 4300 '$(inherited)', |
| 4301 '-force_load', |
| 4302 '<(arc_toolchain_path)/libarclite_iphonesimulator.a'
, |
| 4303 ], |
| 4304 }, |
| 4305 }], |
| 4306 ], |
| 4307 }], |
| 4308 ], |
| 4309 }], |
| 4310 ], |
4242 }], | 4311 }], |
4243 ], # target_conditions | 4312 ], # target_conditions |
4244 }, # target_defaults | 4313 }, # target_defaults |
4245 }], # OS=="ios" | 4314 }], # OS=="ios" |
4246 ['OS=="win"', { | 4315 ['OS=="win"', { |
4247 'target_defaults': { | 4316 'target_defaults': { |
4248 'defines': [ | 4317 'defines': [ |
4249 '_WIN32_WINNT=0x0602', | 4318 '_WIN32_WINNT=0x0602', |
4250 'WINVER=0x0602', | 4319 'WINVER=0x0602', |
4251 'WIN32', | 4320 'WIN32', |
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4587 }], | 4656 }], |
4588 ['OS=="linux" and target_arch=="mipsel"', { | 4657 ['OS=="linux" and target_arch=="mipsel"', { |
4589 'make_global_settings': [ | 4658 'make_global_settings': [ |
4590 ['CC', '<(sysroot)/../bin/mipsel-linux-gnu-gcc'], | 4659 ['CC', '<(sysroot)/../bin/mipsel-linux-gnu-gcc'], |
4591 ['CXX', '<(sysroot)/../bin/mipsel-linux-gnu-g++'], | 4660 ['CXX', '<(sysroot)/../bin/mipsel-linux-gnu-g++'], |
4592 ['CC.host', '<!(which gcc)'], | 4661 ['CC.host', '<!(which gcc)'], |
4593 ['CXX.host', '<!(which g++)'], | 4662 ['CXX.host', '<!(which g++)'], |
4594 ], | 4663 ], |
4595 }], | 4664 }], |
4596 ], | 4665 ], |
| 4666 'configurations': { |
| 4667 # DON'T ADD ANYTHING NEW TO THIS BLOCK UNLESS YOU REALLY REALLY NEED IT! |
| 4668 # This block adds *project-wide* configuration settings to each project |
| 4669 # file. It's almost always wrong to put things here. Specify your |
| 4670 # custom |configurations| in target_defaults to add them to targets instead. |
| 4671 'conditions': [ |
| 4672 ['OS=="ios"', { |
| 4673 'Debug': { |
| 4674 'xcode_settings': { |
| 4675 # Enable 'Build Active Architecture Only' for Debug. This |
| 4676 # avoids a project-level warning in Xcode. |
| 4677 # Note that this configuration uses the default VALID_ARCHS value |
| 4678 # because if there is a device connected Xcode sets the active arch |
| 4679 # to the arch of the device. In cases where the device's arch is not |
| 4680 # in VALID_ARCHS (e.g. iPhone5 is armv7s) Xcode complains because it |
| 4681 # can't determine what arch to compile for. |
| 4682 'ONLY_ACTIVE_ARCH': 'YES', |
| 4683 }, |
| 4684 }, |
| 4685 'Release': { |
| 4686 'xcode_settings': { |
| 4687 # Override VALID_ARCHS and omit armv7s. Otherwise Xcode compiles for |
| 4688 # both armv7 and armv7s, doubling the binary size. |
| 4689 'VALID_ARCHS': 'armv7 i386', |
| 4690 }, |
| 4691 }, |
| 4692 }], |
| 4693 ], |
| 4694 }, |
4597 'xcode_settings': { | 4695 'xcode_settings': { |
4598 # DON'T ADD ANYTHING NEW TO THIS BLOCK UNLESS YOU REALLY REALLY NEED IT! | 4696 # DON'T ADD ANYTHING NEW TO THIS BLOCK UNLESS YOU REALLY REALLY NEED IT! |
4599 # This block adds *project-wide* configuration settings to each project | 4697 # This block adds *project-wide* configuration settings to each project |
4600 # file. It's almost always wrong to put things here. Specify your | 4698 # file. It's almost always wrong to put things here. Specify your |
4601 # custom xcode_settings in target_defaults to add them to targets instead. | 4699 # custom xcode_settings in target_defaults to add them to targets instead. |
4602 | 4700 |
4603 'conditions': [ | 4701 'conditions': [ |
4604 # In an Xcode Project Info window, the "Base SDK for All Configurations" | 4702 # In an Xcode Project Info window, the "Base SDK for All Configurations" |
4605 # setting sets the SDK on a project-wide basis. In order to get the | 4703 # setting sets the SDK on a project-wide basis. In order to get the |
4606 # configured SDK to show properly in the Xcode UI, SDKROOT must be set | 4704 # configured SDK to show properly in the Xcode UI, SDKROOT must be set |
4607 # here at the project level. | 4705 # here at the project level. |
4608 ['OS=="mac"', { | 4706 ['OS=="mac"', { |
4609 'conditions': [ | 4707 'conditions': [ |
4610 ['mac_sdk_path==""', { | 4708 ['mac_sdk_path==""', { |
4611 'SDKROOT': 'macosx<(mac_sdk)', # -isysroot | 4709 'SDKROOT': 'macosx<(mac_sdk)', # -isysroot |
4612 }, { | 4710 }, { |
4613 'SDKROOT': '<(mac_sdk_path)', # -isysroot | 4711 'SDKROOT': '<(mac_sdk_path)', # -isysroot |
4614 }], | 4712 }], |
4615 ], | 4713 ], |
4616 }], | 4714 }], |
4617 ['OS=="ios"', { | 4715 ['OS=="ios"', { |
4618 'conditions': [ | 4716 'conditions': [ |
4619 ['ios_sdk_path==""', { | 4717 ['ios_sdk_path==""', { |
4620 'conditions': [ | 4718 'conditions': [ |
4621 # TODO(justincohen): Ninja only supports simulator for now. | 4719 # TODO(justincohen): Ninja only supports simulator for now. |
4622 ['"<(GENERATOR)"=="xcode"', { | 4720 ['"<(GENERATOR)"=="xcode" or ("<(GENERATOR)"=="ninja" and target_a
rch=="armv7")', { |
4623 'SDKROOT': 'iphoneos<(ios_sdk)', # -isysroot | 4721 'SDKROOT': 'iphoneos<(ios_sdk)', # -isysroot |
4624 }, { | 4722 }, { |
4625 'SDKROOT': 'iphonesimulator<(ios_sdk)', # -isysroot | 4723 'SDKROOT': 'iphonesimulator<(ios_sdk)', # -isysroot |
4626 }], | 4724 }], |
4627 ], | 4725 ], |
4628 }, { | 4726 }, { |
4629 'SDKROOT': '<(ios_sdk_path)', # -isysroot | 4727 'SDKROOT': '<(ios_sdk_path)', # -isysroot |
4630 }], | 4728 }], |
4631 ], | 4729 ], |
4632 }], | 4730 }], |
4633 ['OS=="ios"', { | 4731 ['OS=="ios"', { |
4634 # Target both iPhone and iPad. | 4732 # Target both iPhone and iPad. |
4635 'TARGETED_DEVICE_FAMILY': '1,2', | 4733 'TARGETED_DEVICE_FAMILY': '1,2', |
4636 'VALID_ARCHS': 'armv7 i386', | |
4637 }], | 4734 }], |
4638 ['target_arch=="x64"', { | 4735 ['target_arch=="x64"', { |
4639 'ARCHS': [ | 4736 'ARCHS': [ |
4640 'x86_64' | 4737 'x86_64' |
4641 ], | 4738 ], |
4642 }], | 4739 }], |
4643 ], | 4740 ], |
4644 | 4741 |
4645 # The Xcode generator will look for an xcode_settings section at the root | 4742 # The Xcode generator will look for an xcode_settings section at the root |
4646 # of each dict and use it to apply settings on a file-wide basis. Most | 4743 # of each dict and use it to apply settings on a file-wide basis. Most |
4647 # settings should not be here, they should be in target-specific | 4744 # settings should not be here, they should be in target-specific |
4648 # xcode_settings sections, or better yet, should use non-Xcode-specific | 4745 # xcode_settings sections, or better yet, should use non-Xcode-specific |
4649 # settings in target dicts. SYMROOT is a special case, because many other | 4746 # settings in target dicts. SYMROOT is a special case, because many other |
4650 # Xcode variables depend on it, including variables such as | 4747 # Xcode variables depend on it, including variables such as |
4651 # PROJECT_DERIVED_FILE_DIR. When a source group corresponding to something | 4748 # PROJECT_DERIVED_FILE_DIR. When a source group corresponding to something |
4652 # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the | 4749 # like PROJECT_DERIVED_FILE_DIR is added to a project, in order for the |
4653 # files to appear (when present) in the UI as actual files and not red | 4750 # files to appear (when present) in the UI as actual files and not red |
4654 # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR, | 4751 # red "missing file" proxies, the correct path to PROJECT_DERIVED_FILE_DIR, |
4655 # and therefore SYMROOT, needs to be set at the project level. | 4752 # and therefore SYMROOT, needs to be set at the project level. |
4656 'SYMROOT': '<(DEPTH)/xcodebuild', | 4753 'SYMROOT': '<(DEPTH)/xcodebuild', |
4657 }, | 4754 }, |
4658 } | 4755 } |
OLD | NEW |