升级到Xcode 7后Ar缺失

我正在使用优胜美地 刚刚升级了Xcode 7和命令行

iOS交叉编译C项目时出现此错误。

/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar:没有这样的文件或目录

Xcode 7.0似乎已经改变了这些工具的默认位置:

 nm size libtool pagestuff ar codesign_allocate dsymutil install_name_tool ld ctf_insert as otool strings strip redo_prebinding lipo nmedit 

工具链位置

 /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ 

它可能不包括所有命令行工具,所以你也可以尝试下载它们:

用于Xcode 7的命令行工具OS X 10.10

现在在以前的地方唯一的工具是:

 texturetool csent unwinddump dyldinfo dsymutil-classic rebase pngcrush dwarfdump PackageApplication iphoneos-optimize