在终端中输入的命令:
lipo -create
Release-iphoneos/BaiduMapAPI.framework/BaiduMapAPI
Release-iphonesimulator/BaiduMapAPI.framework/BaiduMapAPI
-output
Release-iphoneos/BaiduMapAPI.framework/BaiduMapAPI
注意:
Release-iphoneos/BaiduMapAPI.framework/BaiduMapAPI 为真机 framework 的路径 ;
Release-iphonesimulator/BaiduMapAPI.framework/BaiduMapAPI 为模拟器 framework 的路径 ;
-output 后面的 Release-iphoneos/BaiduMapAPI.framework/BaiduMapAPI 为合并之后的路径。
在终端中输入上述命令行后会遇到例如以下错误:
xcrun: error: active developer path (“/Applications/Xcode 2.app/Contents/Developer”) does not exist, use
xcode-select --switch path/to/Xcode.app
to specify the Xcode that you wish to use for command line developer tools (or seeman xcode-select
)
解决方式:
在终端里运行例如以下命令就可以解决:
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer