mirror of
https://github.com/void-linux/void-packages.git
synced 2025-08-02 02:42:56 +02:00
freecad: fix 002-execinfo.patch
Signed-off-by: Jürgen Buchmüller <pullmoll@t-online.de>
This commit is contained in:
parent
e91be7be35
commit
5f6add3c22
1 changed files with 27 additions and 27 deletions
|
@ -1,30 +1,30 @@
|
||||||
--- src/App/Application.cpp
|
--- src/App/Application.cpp 2018-04-06 10:48:37.000000000 +0200
|
||||||
+++ src/App/Application.cpp
|
+++ src/App/Application.cpp 2018-04-22 15:04:11.876136151 +0200
|
||||||
@@ -1063,7 +1063,9 @@
|
@@ -1063,7 +1063,9 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(FC_OS_LINUX)
|
#if defined(FC_OS_LINUX)
|
||||||
+#ifdef __GLIBC__
|
+#ifdef __GLIBC__
|
||||||
#include <execinfo.h>
|
#include <execinfo.h>
|
||||||
+#endif
|
+#endif
|
||||||
#include <dlfcn.h>
|
#include <dlfcn.h>
|
||||||
#include <cxxabi.h>
|
#include <cxxabi.h>
|
||||||
|
|
||||||
@@ -1075,6 +1077,7 @@
|
@@ -1075,6 +1077,7 @@
|
||||||
// This function produces a stack backtrace with demangled function & method names.
|
// This function produces a stack backtrace with demangled function & method names.
|
||||||
void printBacktrace(size_t skip=0)
|
void printBacktrace(size_t skip=0)
|
||||||
{
|
{
|
||||||
+#ifdef __GLIBC__
|
+#ifdef __GLIBC__
|
||||||
void *callstack[128];
|
void *callstack[128];
|
||||||
size_t nMaxFrames = sizeof(callstack) / sizeof(callstack[0]);
|
size_t nMaxFrames = sizeof(callstack) / sizeof(callstack[0]);
|
||||||
size_t nFrames = backtrace(callstack, nMaxFrames);
|
size_t nFrames = backtrace(callstack, nMaxFrames);
|
||||||
@@ -1105,6 +1108,9 @@
|
@@ -1105,6 +1108,9 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
free(symbols);
|
free(symbols);
|
||||||
+#else
|
+#else
|
||||||
+ std::cerr << "sorry, no backtrace on musl libc";
|
+ std::cerr << "sorry, no backtrace on musl libc";
|
||||||
+#endif
|
+#endif
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue