diff options
author | Ian Lance Taylor <ian@airs.com> | 1995-09-08 15:50:29 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@airs.com> | 1995-09-08 15:50:29 +0000 |
commit | 1dff79026a659ca1ae5613cf98c2b62a5c0f98a4 (patch) | |
tree | f9b96639d95fbff4f350de752a901f7707f0a1c7 /bfd/configure | |
parent | 824155e843914bf6c1d8269030f9f6442333f065 (diff) | |
download | gdb-1dff79026a659ca1ae5613cf98c2b62a5c0f98a4.zip gdb-1dff79026a659ca1ae5613cf98c2b62a5c0f98a4.tar.gz gdb-1dff79026a659ca1ae5613cf98c2b62a5c0f98a4.tar.bz2 |
* configure.in: Only check for <sys/procfs.h> on a native system,
and make sure it defines prstatus_t.
* configure: Rebuild.
Diffstat (limited to 'bfd/configure')
-rwxr-xr-x | bfd/configure | 38 |
1 files changed, 37 insertions, 1 deletions
diff --git a/bfd/configure b/bfd/configure index f54e1be..4459986 100755 --- a/bfd/configure +++ b/bfd/configure @@ -801,7 +801,7 @@ else fi done -for ac_hdr in fcntl.h sys/file.h sys/procfs.h +for ac_hdr in fcntl.h sys/file.h do ac_safe=`echo "$ac_hdr" | tr './\055' '___'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 @@ -1170,6 +1170,42 @@ EOF rs6000-core.o) COREFLAG="$COREFLAG -DAIX_CORE" ;; trad-core.o) COREFLAG="$COREFLAG -DTRAD_CORE" ;; esac + + # The ELF code uses the native <sys/procfs.h> to handle core files. + # Define HAVE_SYS_PROCFS_H if the file exists and defines + # prstatus_t. + echo $ac_n "checking for sys/procfs.h""... $ac_c" 1>&6 + if eval "test \"`echo '$''{'bfd_cv_header_sys_procfs_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext <<EOF +#line 1183 "configure" +#include "confdefs.h" +#include <sys/procfs.h> +int main() { return 0; } +int t() { +prstatus_t t; +; return 0; } +EOF +if eval $ac_compile; then + rm -rf conftest* + bfd_cv_header_sys_procfs_h=yes +else + rm -rf conftest* + bfd_cv_header_sys_procfs_h=no +fi +rm -f conftest* + +fi + + echo "$ac_t""$bfd_cv_header_sys_procfs_h" 1>&6 + if test $bfd_cv_header_sys_procfs_h = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_SYS_PROCFS_H 1 +EOF + + fi + fi |