xcode 尝试获取 iOS .crash 文件的符号
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/11682789/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Trying to get symbols for an iOS .crash file
提问by Roger Gilbrat
I'm stumped on how to get symbols for a .crash file out of xcode.
我很难过如何从 xcode 中获取 .crash 文件的符号。
I have the .crash file, the .app file, the .ipa file and the .dSYM file. I drag the crash log into the xcode organizer and I see the crash log with symbols for system calls, but no symbols for my app.
我有 .crash 文件、.app 文件、.ipa 文件和 .dSYM 文件。我将崩溃日志拖到 xcode 管理器中,我看到带有系统调用符号的崩溃日志,但我的应用程序没有符号。
The .app/.ipa was built by our build machine, so it was not archived via xcode.
.app/.ipa 是由我们的构建机器构建的,所以它没有通过 xcode 存档。
I tried placing all three files (well, two are actually directories but look like files to the Mac) in the same folder and nothing. I tried running symbolicatecrash from the command line while in that directory and I get this error:
我尝试将所有三个文件(嗯,两个实际上是目录,但在 Mac 上看起来像文件)放在同一个文件夹中,什么也没有。我尝试在该目录中从命令行运行symbolicatecrash,但出现此错误:
Error: "DEVELOPER_DIR" is not defined at /Applications/Xcode.app/[snip]Resources/symbolicatecrash line 53.
I tried setting DEVELOPER_DIR to /Applications/Xcode.app and it gets further, but now I see a slew of errors that read:
我尝试将 DEVELOPER_DIR 设置为 /Applications/Xcode.app 并且它变得更进一步,但现在我看到了一系列错误,内容如下:
sh: /Applications/Xcode.app/usr/bin/xcrun: No such file or directory
I'm stumped. You'd think this would be easier given all 4 needed files are in same directory.
我难住了。你会认为这会更容易,因为所有 4 个需要的文件都在同一个目录中。
I am running xcode 4.4, but was experiencing the same issues last night with 4.3. I was hope upgrading would help.
我正在运行 xcode 4.4,但昨晚在 4.3 上遇到了同样的问题。我希望升级会有所帮助。
回答by utopalex
Make sure you set the right DEVELOPER_DIR:
确保设置正确的 DEVELOPER_DIR:
export DEVELOPER_DIR="/Applications/Xcode.app/Contents/Developer"
Xcode is written with capital X. Tested on Mountain Lion (10.8).
Xcode 用大写 X 编写。在 Mountain Lion (10.8) 上测试。
回答by Mikael Bartlett
First set correct Xcode location:
首先设置正确的Xcode位置:
sudo /usr/bin/xcode-select -switch /Applications/Xcode.app/Contents/Developer/
I set this variable and got it working.
我设置了这个变量并让它工作。
export DEVELOPER_DIR=/Applications/Xcode.app
Then and I ran the symbolicatecrash in this directory:
然后我在这个目录中运行了symbolicatecrash:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/PrivateFrameworks/DTDeviceKit.framework/Versions/A/Resources
回答by trojanfoe
(Sorry my answer was written before properly reading your question).
(对不起,我的回答是在正确阅读您的问题之前写的)。
Use xcode-select
to set the correct location of your Xcode install. More precisely:
使用xcode-select
设置您的Xcode的正确位置安装。更确切地说:
$ sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer