1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/media/webrtc/trunk/build/ios/mac_build.gypi Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,79 @@ 1.4 +# Copyright (c) 2012 The Chromium Authors. All rights reserved. 1.5 +# Use of this source code is governed by a BSD-style license that can be 1.6 +# found in the LICENSE file. 1.7 + 1.8 +# Xcode throws an error if an iOS target depends on a Mac OS X target. So 1.9 +# any place a utility program needs to be build and run, an action is 1.10 +# used to run ninja as script to work around this. 1.11 +# Example: 1.12 +# { 1.13 +# 'target_name': 'foo', 1.14 +# 'type': 'none', 1.15 +# 'variables': { 1.16 +# # The name of a directory used for ninja. This cannot be shared with 1.17 +# # another mac build. 1.18 +# 'ninja_output_dir': 'ninja-foo', 1.19 +# # The list of all the gyp files that contain the targets to run. 1.20 +# 're_run_targets': [ 1.21 +# 'foo.gyp', 1.22 +# ], 1.23 +# }, 1.24 +# 'includes': ['path_to/mac_build.gypi'], 1.25 +# 'actions': [ 1.26 +# { 1.27 +# 'action_name': 'compile foo', 1.28 +# 'inputs': [], 1.29 +# 'outputs': [], 1.30 +# 'action': [ 1.31 +# '<@(ninja_cmd)', 1.32 +# # All the targets to build. 1.33 +# 'foo1', 1.34 +# 'foo2', 1.35 +# ], 1.36 +# }, 1.37 +# ], 1.38 +# } 1.39 +{ 1.40 + 'variables': { 1.41 + # Convenience variable pointing to the ninja product directory. 1.42 + 'ninja_product_dir': 1.43 + '<(DEPTH)/xcodebuild/<(ninja_output_dir)/<(CONFIGURATION_NAME)', 1.44 + 1.45 + # Common ninja command line flags. 1.46 + 'ninja_cmd': [ 1.47 + # Bounce through clean_env to clean up the environment so things 1.48 + # set by the iOS build don't pollute the Mac build. 1.49 + '<(DEPTH)/build/ios/clean_env.py', 1.50 + # ninja must be found in the PATH. 1.51 + 'ADD_TO_PATH=<!(echo $PATH)', 1.52 + 'ninja', 1.53 + '-C', 1.54 + '<(ninja_product_dir)', 1.55 + ], 1.56 + 1.57 + # Common syntax to rerun gyp to generate the Mac projects. 1.58 + 're_run_gyp': [ 1.59 + 'build/gyp_chromium', 1.60 + # Don't use anything set for the iOS side of things. 1.61 + '--ignore-environment', 1.62 + # Generate for ninja 1.63 + '--format=ninja', 1.64 + # Generate files into xcodebuild/ninja 1.65 + '-Goutput_dir=xcodebuild/<(ninja_output_dir)', 1.66 + # nacl isn't in the iOS checkout, make sure it's turned off 1.67 + '-Ddisable_nacl=1', 1.68 + # Add a variable to handle specific cases for mac_build. 1.69 + '-Dios_mac_build=1', 1.70 + # Pass through the Mac SDK version. 1.71 + '-Dmac_sdk=<(mac_sdk)', 1.72 + ], 1.73 + 1.74 + # Rerun gyp for each of the projects needed. This is what actually 1.75 + # generates the projects on disk. 1.76 + 're_run_gyp_execution': 1.77 + '<!(cd <(DEPTH) && <@(re_run_gyp) <@(re_run_targets))', 1.78 + }, 1.79 + # Since these are used to generate things needed by other targets, make 1.80 + # them hard dependencies so they are always built first. 1.81 + 'hard_dependency': 1, 1.82 +}