Last active
April 23, 2017 11:52
-
-
Save jessicah/f227fde7761141748ee10fcb36b8f6ef to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if ! $pc_field_found; then | |
pc_fields=" eip" # Haiku (i386) | |
pc_fields="$pc_fields rip" # Haiku (x86_64) | |
for pc_field in $pc_fields; do | |
if ! $pc_field_found; then | |
AC_TRY_COMPILE([#include <signal.h>], | |
[ucontext_t u; return u.uc_mcontext.$pc_field == 0;], | |
AC_DEFINE_UNQUOTED(PC_FROM_UCONTEXT, $pc_field, | |
How to access the PC from a struct ucontext) | |
AC_MSG_RESULT([$pc_field]) | |
pc_field_found=true) | |
fi | |
done | |
fi | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment