Delphi 11 10 XE8 XE7 XE Seattle Berlin Tokyo Rio Firemonkey, Delphi Android, Delphi IOS

Get A Stacktrace With Backtrace Library For Delphi XE5 Firemonkey On Android

| Delphi 11 10 XE8 XE7 XE Seattle Berlin Tokyo Rio Firemonkey Delphi Android Delphi IOS

Delphi XE5 Firemonkey ARM Stacktrace Backtrace | Delphi 11 10 XE8 XE7 XE Seattle Berlin Tokyo Rio Firemonkey Delphi Android Delphi IOSHonza Rames has created a library that allows you to create a stacktrace for Delphi XE5 Firemonkey apps on Android ARM devices. The library is currently in the proof of concept phase but it does output line numbers in specific .pas files from the app running the ARM Delphi .so. It uses the TPosixProcEntryList object from the Posix.Proc, Posix.Backtrace, Posix.ExceptionUtil libraries with the LoadFromCurrentProcess and the ConvertStackTrace() function to accomplish it. Currently it does not work on ARM IOS but that may be added in the future and has only been tested on a Nexus 7 Android device. Here is some sample output from the backtrace:
0x00AC5AC6 (0x75A48AC6) /data/app-lib/com.embarcadero.BacktraceTestProj-1/libBacktraceTestProj.so
_ZN13Backtracetest9SomeFunc2Ei at D:\Documents\RAD Studio\Projects\ArmBacktrace\Tests/BacktraceTest.pas:57
0x00AC5E90 (0x75A48E90) /data/app-lib/com.embarcadero.BacktraceTestProj-1/libBacktraceTestProj.so
_ZN13Backtracetest9SomeFunc1Ei at D:\Documents\RAD Studio\Projects\ArmBacktrace\Tests/BacktraceTest.pas:92
0x00AC5EA8 (0x75A48EA8) /data/app-lib/com.embarcadero.BacktraceTestProj-1/libBacktraceTestProj.so

Head over and check out the library project for getting stacktrace info from Android ARM.

Exit mobile version