22 lines
626 B
Diff
22 lines
626 B
Diff
--- a/v8/src/codegen/external-reference-table.cc.orig
|
|
+++ b/v8/src/codegen/external-reference-table.cc
|
|
@@ -11,7 +11,9 @@
|
|
|
|
#if defined(DEBUG) && defined(V8_OS_LINUX) && !defined(V8_OS_ANDROID)
|
|
#define SYMBOLIZE_FUNCTION
|
|
+#if defined(__GLIBC__)
|
|
#include <execinfo.h>
|
|
+#endif
|
|
|
|
#include <vector>
|
|
|
|
@@ -96,7 +98,7 @@
|
|
}
|
|
|
|
const char* ExternalReferenceTable::ResolveSymbol(void* address) {
|
|
-#ifdef SYMBOLIZE_FUNCTION
|
|
+#if defined(SYMBOLIZE_FUNCTION) && defined(__GLIBC__)
|
|
char** names = backtrace_symbols(&address, 1);
|
|
const char* name = names[0];
|
|
// The array of names is malloc'ed. However, each name string is static
|