-option('function-trace', type: 'boolean', value: false, description: 'enable function trace: (default=false)')
option('tests', type: 'boolean', value: true, description: 'Compile Enlightenment tests')
-if get_option('function-trace')
- config_h.set('ENABLE_FUNCTION_TRACE', '1')
-endif
-
cc.check_header('fnmatch.h', required: true)
if cc.has_header('features.h')
#undef PRCTL_BACKTRACE
#undef DLOG_BACKTRACE
-#ifdef ENABLE_FUNCTION_TRACE
-# include <sys/prctl.h>
-# undef PR_TASK_PERF_USER_TRACE
-# define PR_TASK_PERF_USER_TRACE 666
-# define PRCTL(str, x...) \
+#include <sys/prctl.h>
+#undef PR_TASK_PERF_USER_TRACE
+#define PR_TASK_PERF_USER_TRACE 666
+#define PRCTL(str, x...) \
({ \
char __buf__[256]; \
snprintf(__buf__, sizeof(__buf__), str, ##x); \
prctl(PR_TASK_PERF_USER_TRACE, __buf__, strlen(__buf__)); \
})
-# include <execinfo.h>
-# define PRCTL_BACKTRACE() \
+#include <execinfo.h>
+#define PRCTL_BACKTRACE() \
({ \
void *__buf__[256]; \
char **__strings__; \
} \
})
-# ifdef HAVE_DLOG
-# define DLOG_BACKTRACE() \
+#ifdef HAVE_DLOG
+# define DLOG_BACKTRACE() \
({ \
void *__buf__[256]; \
char **__strings__; \
free(__strings__); \
} \
})
-# endif
-#else
-# define PRCTL
-# define PRCTL_BACKTRACE
-# define DLOG_BACKTRACE
#endif
static inline Ecore_Window