File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change
1
+ declare_args () {
2
+ # Set to true if you don't have Xcode installed, but do have the commandline
3
+ # tools.
4
+ mac_use_commandline_tools_sdk = false
5
+ }
6
+
1
7
# Location of the mac sdk.
2
- # If that's not fixed, might want to shell out to xcrun at gn time to
3
- # retrieve this, but for now this seems to do the trick.
4
- mac_sdk_path = " /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
8
+ # The correct way to do this is to call xcrun (https://reviews.llvm.org/D70835),
9
+ # but that makes `gn gen` take twice as long and almost everyone has Xcode
10
+ # installed. So require that people who don't have it installed set a gn arg.
11
+ if (mac_use_commandline_tools_sdk ) {
12
+ mac_sdk_path = " /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk"
13
+ } else {
14
+ mac_sdk_path = " /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
15
+ }
You can’t perform that action at this time.
0 commit comments