added execinfo support for FreeBSD

This commit is contained in:
roberto@freebsd9
2012-04-05 12:28:10 +02:00
parent 9ff6be783a
commit add7e2ee0e
2 changed files with 6 additions and 1 deletions
+1 -1
View File
@@ -1104,7 +1104,7 @@ void uwsgi_plugins_atexit(void) {
void uwsgi_backtrace(int depth) {
#if defined(__linux__) || defined(__APPLE__)
#if defined(__linux__) || defined(__APPLE__) || defined(UWSGI_HAS_EXECINFO)
#include <execinfo.h>
+5
View File
@@ -383,6 +383,11 @@ class uConf(object):
if self.has_include('ifaddrs.h'):
self.cflags.append('-DUWSGI_HAS_IFADDRS')
if uwsgi_os == 'FreeBSD':
if self.has_include('execinfo.h') or os.path.exists('/usr/local/include/execinfo.h'):
self.cflags.append('-DUWSGI_HAS_EXECINFO')
self.libs.append('-lexecinfo')
if uwsgi_os == 'SunOS':
self.libs.append('-lsendfile')
self.gcc_list.append('lib/sun_fixes')