OLD | NEW |
1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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 declare_args() { | 5 declare_args() { |
6 # SDK path to use. When empty this will use the default SDK based on the | 6 # SDK path to use. When empty this will use the default SDK based on the |
7 # value of use_ios_simulator. | 7 # value of use_ios_simulator. |
8 ios_sdk_path = "" | 8 ios_sdk_path = "" |
9 ios_sdk_name = "" | 9 ios_sdk_name = "" |
10 ios_sdk_version = "" | 10 ios_sdk_version = "" |
(...skipping 16 matching lines...) Expand all Loading... |
27 | 27 |
28 if (ios_sdk_path == "") { | 28 if (ios_sdk_path == "") { |
29 # Compute default target. | 29 # Compute default target. |
30 if (use_ios_simulator) { | 30 if (use_ios_simulator) { |
31 ios_sdk_name = "iphonesimulator" | 31 ios_sdk_name = "iphonesimulator" |
32 ios_sdk_platform = "iPhoneSimulator" | 32 ios_sdk_platform = "iPhoneSimulator" |
33 } else { | 33 } else { |
34 ios_sdk_name = "iphoneos" | 34 ios_sdk_name = "iphoneos" |
35 ios_sdk_platform = "iPhoneOS" | 35 ios_sdk_platform = "iPhoneOS" |
36 } | 36 } |
37 _ios_sdk_result = exec_script("ios_sdk.py", [ ios_sdk_name ], "scope") | 37 _ios_sdk_result = |
38 ios_sdk_path = _ios_sdk_result.ios_sdk_path | 38 exec_script("//build/config/mac/sdk_info.py", [ ios_sdk_name ], "scope") |
39 ios_sdk_version = _ios_sdk_result.ios_sdk_version | 39 ios_sdk_path = _ios_sdk_result.sdk_path |
40 ios_sdk_build = _ios_sdk_result.ios_sdk_build | 40 ios_sdk_version = _ios_sdk_result.sdk_version |
| 41 ios_sdk_build = _ios_sdk_result.sdk_build |
41 xcode_version = _ios_sdk_result.xcode_version | 42 xcode_version = _ios_sdk_result.xcode_version |
42 xcode_build = _ios_sdk_result.xcode_build | 43 xcode_build = _ios_sdk_result.xcode_build |
43 machine_os_build = _ios_sdk_result.machine_os_build | 44 machine_os_build = _ios_sdk_result.machine_os_build |
44 if (use_ios_simulator) { | 45 if (use_ios_simulator) { |
45 # This is weird, but Xcode sets DTPlatformBuild to an empty field for | 46 # This is weird, but Xcode sets DTPlatformBuild to an empty field for |
46 # simulator builds. | 47 # simulator builds. |
47 ios_platform_build = "" | 48 ios_platform_build = "" |
48 } else { | 49 } else { |
49 ios_platform_build = ios_sdk_build | 50 ios_platform_build = ios_sdk_build |
50 } | 51 } |
51 } | 52 } |
52 | 53 |
53 if (use_ios_simulator) { | 54 if (use_ios_simulator) { |
54 # Always disable code signing on the simulator | 55 # Always disable code signing on the simulator |
55 ios_enable_code_signing = false | 56 ios_enable_code_signing = false |
56 ios_code_signing_identity = "" | 57 ios_code_signing_identity = "" |
57 } | 58 } |
58 | 59 |
59 if (ios_enable_code_signing) { | 60 if (ios_enable_code_signing) { |
60 # If an identity is not provided, look for one on the host | 61 # If an identity is not provided, look for one on the host |
61 if (ios_code_signing_identity == "") { | 62 if (ios_code_signing_identity == "") { |
62 _ios_identities = exec_script("find_signing_identity.py", [], "list lines") | 63 _ios_identities = exec_script("find_signing_identity.py", [], "list lines") |
63 ios_code_signing_identity = _ios_identities[0] | 64 ios_code_signing_identity = _ios_identities[0] |
64 } | 65 } |
65 | 66 |
66 if (ios_code_signing_identity == "") { | 67 if (ios_code_signing_identity == "") { |
67 print("Tried to prepare a device build without specifying a code signing") | 68 print("Tried to prepare a device build without specifying a code signing") |
68 print("identity and could not detect one automatically either.") | 69 print("identity and could not detect one automatically either.") |
69 print("TIP: Simulator builds dont require code signing...") | 70 print("TIP: Simulator builds don't require code signing...") |
70 assert(false) | 71 assert(false) |
71 } | 72 } |
72 } | 73 } |
OLD | NEW |