#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <ucontext.h>
#include <unistd.h>
#include <libunwind.h>
printf (" @ %lx", (unsigned long) uc->uc_mcontext.mc_rip);
#endif
#elif defined UNW_TARGET_ARM
+#if defined __linux__
printf (" @ %lx", (unsigned long) uc->uc_mcontext.arm_pc);
+#elif defined __FreeBSD__
+ printf (" @ %lx", (unsigned long) uc->uc_mcontext.__gregs[_REG_PC]);
+#endif
#endif
printf ("\n");
}