- bugfixes for mingw compilers
This commit is contained in:
parent
83ff486e21
commit
fabf42c807
|
@ -32,7 +32,11 @@ IF(CMAKE_COMPILER_IS_GNUCXX OR MINGW)
|
||||||
|
|
||||||
# Default compiler flags
|
# Default compiler flags
|
||||||
#SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -s") ## Strip binary
|
#SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -s") ## Strip binary
|
||||||
ADD_DEFINITIONS("-fno-strict-aliasing -frounding-math -fsignaling-nans -mfpmath=sse -msse -rdynamic")
|
IF(NOT MINGW)
|
||||||
|
ADD_DEFINITIONS("-fno-strict-aliasing -frounding-math -fsignaling-nans -mfpmath=sse -msse -rdynamic")
|
||||||
|
ELSE()
|
||||||
|
ADD_DEFINITIONS("-fno-strict-aliasing -frounding-math -fsignaling-nans -mfpmath=sse -msse")
|
||||||
|
ENDIF()
|
||||||
#SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")
|
#SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")
|
||||||
|
|
||||||
# Debug compiler flags
|
# Debug compiler flags
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
#include "cache_manager.h"
|
#include "cache_manager.h"
|
||||||
|
|
||||||
// For gcc backtrace on crash!
|
// For gcc backtrace on crash!
|
||||||
#ifdef __GNUC__
|
#if defined(__GNUC__) && !defined(__MINGW32__)
|
||||||
#include <execinfo.h>
|
#include <execinfo.h>
|
||||||
#include <cxxabi.h>
|
#include <cxxabi.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
@ -259,7 +259,7 @@ public:
|
||||||
|
|
||||||
string errMsg = (msg != NULL ? msg : "null");
|
string errMsg = (msg != NULL ? msg : "null");
|
||||||
|
|
||||||
#ifdef __GNUC__
|
#if defined(__GNUC__) && !defined(__MINGW32__)
|
||||||
errMsg += "\nStack Trace:\n";
|
errMsg += "\nStack Trace:\n";
|
||||||
//errMsg += "To find line #'s use:\n";
|
//errMsg += "To find line #'s use:\n";
|
||||||
//errMsg += "readelf --debug-dump=decodedline %s | egrep 0xaddress-of-stack\n";
|
//errMsg += "readelf --debug-dump=decodedline %s | egrep 0xaddress-of-stack\n";
|
||||||
|
@ -1463,7 +1463,7 @@ __try {
|
||||||
#endif
|
#endif
|
||||||
application_binary=argv[0];
|
application_binary=argv[0];
|
||||||
|
|
||||||
#ifdef __GNUC__
|
#if defined(__GNUC__) && !defined(__MINGW32__)
|
||||||
signal(SIGSEGV, handleSIGSEGV);
|
signal(SIGSEGV, handleSIGSEGV);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue