#include "gtypelib.h"
#include "config.h"
+#if defined(HAVE_BACKTRACE) && defined(HAVE_BACKTRACE_SYMBOLS)
+# include <execinfo.h>
+#endif
+
struct _GIrParser
{
gchar **includes;
{
#if defined(HAVE_BACKTRACE) && defined(HAVE_BACKTRACE_SYMBOLS)
void *array[50];
- int size;
+ int size, i;
char **strings;
- size_t i;
size = backtrace (array, 50);
strings = (char**) backtrace_symbols (array, size);
for (i = 0; i < size; i++)
fprintf (stderr, "%s\n", strings[i]);
- fprintf (stderr, "--- END BACKTRACE ---\n", size);
+ fprintf (stderr, "--- END BACKTRACE ---\n");
free (strings);
#endif