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 # Xcode throws an error if an iOS target depends on a Mac OS X target. So | 5 # Xcode throws an error if an iOS target depends on a Mac OS X target. So |
6 # any place a utility program needs to be build and run, an action is | 6 # any place a utility program needs to be build and run, an action is |
7 # used to run ninja as script to work around this. | 7 # used to run ninja as script to work around this. |
8 # Example: | 8 # Example: |
9 # { | 9 # { |
10 # 'target_name': 'foo', | 10 # 'target_name': 'foo', |
(...skipping 21 matching lines...) Expand all Loading... | |
32 # '<@(ninja_cmd)', | 32 # '<@(ninja_cmd)', |
33 # # All the targets to build. | 33 # # All the targets to build. |
34 # 'foo1', | 34 # 'foo1', |
35 # 'foo2', | 35 # 'foo2', |
36 # ], | 36 # ], |
37 # }, | 37 # }, |
38 # ], | 38 # ], |
39 # } | 39 # } |
40 { | 40 { |
41 'variables': { | 41 'variables': { |
42 'variables': { | |
43 'conditions' : [ | |
44 ['"<(GENERATOR)"=="ninja"', { | |
45 'include_dir': '<(DEPTH)/out/<(CONFIGURATION_NAME)/gen', | |
46 }, { | |
47 'include_dir': '<(DEPTH)/xcodebuild/DerivedSources/<(CONFIGURATION_NAM E)', | |
48 }], | |
49 ], | |
50 }, | |
51 'include_dir%': '<(include_dir)', | |
52 }, | |
Mark Mentovai
2013/05/02 13:19:22
This line doesn’t belong.
justincohen
2013/05/02 13:21:41
Done.
| |
42 # Common ninja command line flags. | 53 # Common ninja command line flags. |
43 'ninja_cmd': [ | 54 'ninja_cmd': [ |
44 # Bounce through clean_env to clean up the environment so things | 55 # Bounce through clean_env to clean up the environment so things |
45 # set by the iOS build don't pollute the Mac build. | 56 # set by the iOS build don't pollute the Mac build. |
46 '<(DEPTH)/build/ios/clean_env.py', | 57 '<(DEPTH)/build/ios/clean_env.py', |
47 # ninja must be found in the PATH. | 58 # ninja must be found in the PATH. |
48 'ADD_TO_PATH=<!(echo $PATH)', | 59 'ADD_TO_PATH=<!(echo $PATH)', |
49 'ninja', | 60 'ninja', |
50 '-C', | 61 '-C', |
51 '<(ninja_product_dir)', | 62 '<(ninja_product_dir)', |
52 ], | 63 ], |
53 | 64 |
54 # Common syntax to rerun gyp to generate the Mac projects. | 65 # Common syntax to rerun gyp to generate the Mac projects. |
55 're_run_gyp': [ | 66 're_run_gyp': [ |
56 'build/gyp_chromium', | 67 'build/gyp_chromium', |
57 '--depth=.', | 68 '--depth=.', |
58 # Don't use anything set for the iOS side of things. | 69 # Don't use anything set for the iOS side of things. |
59 '--ignore-environment', | 70 '--ignore-environment', |
60 # Generate for ninja | 71 # Generate for ninja |
61 '--format=ninja', | 72 '--format=ninja', |
62 # Generate files into xcodebuild/ninja | 73 # Generate files into xcodebuild/ninja |
63 '-Goutput_dir=xcodebuild/<(ninja_output_dir)', | 74 '-Goutput_dir=xcodebuild/<(ninja_output_dir)', |
64 # nacl isn't in the iOS checkout, make sure it's turned off | 75 # nacl isn't in the iOS checkout, make sure it's turned off |
65 '-Ddisable_nacl=1', | 76 '-Ddisable_nacl=1', |
66 # Add a variable to handle specific cases for mac_build. | 77 # Add a variable to handle specific cases for mac_build. |
67 '-Dios_mac_build=1', | 78 '-Dios_mac_build=1', |
68 # Pass through the Mac SDK version. | 79 # Pass through the Mac SDK version. |
69 '-Dmac_sdk=<(mac_sdk)', | 80 '-Dmac_sdk=<(mac_sdk)', |
81 '-Dinclude_dir=<(include_dir)' | |
70 ], | 82 ], |
71 | 83 |
72 # Rerun gyp for each of the projects needed. This is what actually | 84 # Rerun gyp for each of the projects needed. This is what actually |
73 # generates the projects on disk. | 85 # generates the projects on disk. |
74 're_run_gyp_execution': | 86 're_run_gyp_execution': |
75 '<!(cd <(DEPTH) && <@(re_run_gyp) <@(re_run_targets))', | 87 '<!(cd <(DEPTH) && <@(re_run_gyp) <@(re_run_targets))', |
76 }, | 88 }, |
77 # Since these are used to generate things needed by other targets, make | 89 # Since these are used to generate things needed by other targets, make |
78 # them hard dependencies so they are always built first. | 90 # them hard dependencies so they are always built first. |
79 'hard_dependency': 1, | 91 'hard_dependency': 1, |
80 } | 92 } |
OLD | NEW |