51 lines
1.3 KiB
Diff
51 lines
1.3 KiB
Diff
--- src/plugins/qmldesigner/designercore/exceptions/exception.cpp 2015-04-21 17:56:56.000000000 +0200
|
|
+++ src/plugins/qmldesigner/designercore/exceptions/exception.cpp 2015-06-26 13:17:08.600350791 +0200
|
|
@@ -31,7 +31,9 @@
|
|
#include "exception.h"
|
|
|
|
#ifdef Q_OS_LINUX
|
|
+#if defined(__GLIBC__)
|
|
#include <execinfo.h>
|
|
+#endif
|
|
#include <cxxabi.h>
|
|
#endif
|
|
|
|
@@ -107,6 +109,7 @@
|
|
m_file(file)
|
|
{
|
|
#ifdef Q_OS_LINUX
|
|
+#ifdef __GLIBC__
|
|
void * array[50];
|
|
int nSize = backtrace(array, 50);
|
|
char ** symbols = backtrace_symbols(array, nSize);
|
|
@@ -118,6 +121,7 @@
|
|
|
|
free(symbols);
|
|
#endif
|
|
+#endif
|
|
|
|
if (s_shouldAssert)
|
|
Q_ASSERT_X(false, function.toUtf8(), QString("%1:%2 - %3").arg(file).arg(line).arg(function).toUtf8());
|
|
--- src/plugins/debugger/shared/backtrace.cpp 2015-04-21 17:56:56.000000000 +0200
|
|
+++ src/plugins/debugger/shared/backtrace.cpp 2015-06-26 13:14:54.295358053 +0200
|
|
@@ -35,8 +35,10 @@
|
|
#if defined(Q_OS_LINUX)
|
|
#include <stdio.h>
|
|
#include <signal.h>
|
|
+#if defined(__GLIBC__)
|
|
#include <execinfo.h>
|
|
#endif
|
|
+#endif
|
|
|
|
namespace Debugger {
|
|
namespace Internal {
|
|
@@ -45,7 +47,7 @@
|
|
{
|
|
if (maxdepth == -1)
|
|
maxdepth = 200;
|
|
-#if defined(Q_OS_LINUX)
|
|
+#if defined(Q_OS_LINUX) && defined(__GLIBC__)
|
|
void *bt[200] = {0};
|
|
qDebug() << "BACKTRACE:";
|
|
int size = backtrace(bt, sizeof(bt) / sizeof(bt[0]));
|