-dnl Copyright (C) 2012-2015 Free Software Foundation, Inc.
+dnl Copyright (C) 2012-2019 Free Software Foundation, Inc.
dnl
dnl This file is part of GDB.
dnl
AC_CACHE_CHECK([types of arguments for ptrace], gdb_cv_func_ptrace_args, [
AC_TRY_COMPILE($gdb_ptrace_headers,
[extern long ptrace (enum __ptrace_request, ...);],
- [gdb_cv_func_ptrace_args='int,int,long,long'],[
+ [gdb_cv_func_ptrace_args='enum __ptrace_request,int,long,long'],[
for gdb_arg1 in 'int' 'long'; do
for gdb_arg2 in 'pid_t' 'int' 'long'; do
for gdb_arg3 in 'int *' 'caddr_t' 'int' 'long' 'void *'; do
set dummy `echo "$gdb_cv_func_ptrace_args" | sed 's/\*/\*/g'`
IFS=$ac_save_IFS
shift
+AC_DEFINE_UNQUOTED(PTRACE_TYPE_ARG1, $[1],
+ [Define to the type of arg 1 for ptrace.])
AC_DEFINE_UNQUOTED(PTRACE_TYPE_ARG3, $[3],
[Define to the type of arg 3 for ptrace.])
AC_DEFINE_UNQUOTED(PTRACE_TYPE_ARG4, $[4],