diff options
author | bruvzg <7645683+bruvzg@users.noreply.github.com> | 2021-11-15 15:04:01 +0200 |
---|---|---|
committer | bruvzg <7645683+bruvzg@users.noreply.github.com> | 2021-11-16 08:45:34 +0200 |
commit | c8037ef2e5b065c1fe5e0241e4cde0376a367ed0 (patch) | |
tree | 01a95170a77dd78b24b050d399cce920e3ee7dbc | |
parent | 53ae45f657b63a7e9c122f8db27f5f9b5f8dda98 (diff) |
[macOS] Fix crash handler not printing function names on M1 Macs.
-rw-r--r-- | platform/osx/crash_handler_osx.mm | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/platform/osx/crash_handler_osx.mm b/platform/osx/crash_handler_osx.mm index 2252d5eb4f..57bca7a5b9 100644 --- a/platform/osx/crash_handler_osx.mm +++ b/platform/osx/crash_handler_osx.mm @@ -134,8 +134,13 @@ static void handle_crash(int sig) { args.push_back("-o"); args.push_back(_execpath); +#if defined(__x86_64) || defined(__x86_64__) || defined(__amd64__) args.push_back("-arch"); args.push_back("x86_64"); +#elif defined(__aarch64__) + args.push_back("-arch"); + args.push_back("arm64"); +#endif args.push_back("-l"); snprintf(str, 1024, "%p", load_addr); args.push_back(str); |