projects
/
quassel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Various buildsystem improvements:
[quassel.git]
/
src
/
common
/
main.cpp
diff --git
a/src/common/main.cpp
b/src/common/main.cpp
index
daca412
..
aa1c75a
100644
(file)
--- a/
src/common/main.cpp
+++ b/
src/common/main.cpp
@@
-54,7
+54,7
@@
#include <signal.h>
#include <signal.h>
-#if
def Q_OS_LINUX
+#if
defined(HAVE_EXECINFO) and not defined(Q_OS_MAC)
#include <execinfo.h>
#include <dlfcn.h>
#include <cxxabi.h>
#include <execinfo.h>
#include <dlfcn.h>
#include <cxxabi.h>
@@
-66,8
+66,9
@@
void handle_signal(int sig) {
QCoreApplication::quit();
}
QCoreApplication::quit();
}
-#if
def Q_OS_LINUX
+#if
defined(HAVE_EXECINFO) and not defined(Q_OS_MAC)
void handle_crash(int sig) {
void handle_crash(int sig) {
+ Q_UNUSED(sig)
void* callstack[128];
int i, frames = backtrace(callstack, 128);
void* callstack[128];
int i, frames = backtrace(callstack, 128);
@@
-128,7
+129,7
@@
void handle_crash(int sig) {
dumpFile.close();
exit(27);
}
dumpFile.close();
exit(27);
}
-#endif // #if
def Q_OS_LINUX
+#endif // #if
defined(HAVE_EXECINFO) and not defined(Q_OS_MAC)
int main(int argc, char **argv) {
int main(int argc, char **argv) {
@@
-136,11
+137,11
@@
int main(int argc, char **argv) {
signal(SIGTERM, handle_signal);
signal(SIGINT, handle_signal);
signal(SIGTERM, handle_signal);
signal(SIGINT, handle_signal);
-#if
def Q_OS_LINUX
+#if
defined(HAVE_EXECINFO) and not defined(Q_OS_MAC)
signal(SIGABRT, handle_crash);
signal(SIGBUS, handle_crash);
signal(SIGSEGV, handle_crash);
signal(SIGABRT, handle_crash);
signal(SIGBUS, handle_crash);
signal(SIGSEGV, handle_crash);
-#endif // #if
def Q_OS_LINUX
+#endif // #if
defined(HAVE_EXECINFO) and not defined(Q_OS_MAC)
Global::registerMetaTypes();
Global::setupVersion();
Global::registerMetaTypes();
Global::setupVersion();
@@
-168,8
+169,6
@@
int main(int argc, char **argv) {
QtUiApplication app(argc, argv);
#endif
QtUiApplication app(argc, argv);
#endif
-
-
Global::parser = CliParser(QCoreApplication::arguments());
#ifndef BUILD_QTUI
Global::parser = CliParser(QCoreApplication::arguments());
#ifndef BUILD_QTUI