How to manually symbolicate a crash log with atos

强颜欢笑 提交于 2019-11-30 10:06:16
Matt Hudson

My guess is that you saw the Stackoverflow question with the atos information in it (like I did), but are not calculating the address correctly to put into atos. See here:

iOS crash reports: atos not working as expected

symbol address = slide + stack address - load address

Use otool to get your slide address (usually 0x001000)

otool -arch ARCHITECTURE -l "APP_BUNDLE/APP_EXECUTABLE" | grep -B 3 -A 8 -m 2 "__TEXT"

Scroll to the bottom of your crash log to get your stack address from the binary images section (first address in the list under Binary Images).

Then add it up using the HEX calculator that comes with your mac (use programmer view). Lastly subtract your load address from the stack trace in your crash log (in your case it looks like 0x00012efe).

Put this in atos to get the line that causes the crash:

atos -arch armv7 -o YOURAPP.app'/'yourapp' 0xADDRESSFROMABOVE
IdoT

You can try and use my script to achieve this: https://github.com/IdoTene/MacosSymbolicateCrash/blob/master/symbolicate.py

It encapsulates the atos command

Or the updated version: https://github.com/samrayner/MacosSymbolicateCrash/blob/master/symbolicate.py.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!