From 27fca56f9885bd3c2364c3698475038954e26725 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Mon, 25 Sep 1995 16:22:43 +0000 Subject: * configure.in: Call AC_HEADER_SYS_WAIT. * configure: Rebuild. * config.in: Rebuild. * dlltool.c: Include "libiberty.h" and "bucomm.h". Don't include , , or . Don't include . Include . Use HAVE_SYS_WAIT_H to control whether to include or define the wait macros by hand. Don't declare xmalloc. (gen_lib_file): Don't assume that sprintf returns the number of characters; use strlen instead. --- binutils/configure | 50 +++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 45 insertions(+), 5 deletions(-) (limited to 'binutils/configure') diff --git a/binutils/configure b/binutils/configure index c23c094..c71b90b 100755 --- a/binutils/configure +++ b/binutils/configure @@ -785,6 +785,46 @@ else fi done +echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 +if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + cat > conftest.$ac_ext < +#include +#ifndef WEXITSTATUS +#define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8) +#endif +#ifndef WIFEXITED +#define WIFEXITED(stat_val) (((stat_val) & 255) == 0) +#endif +int main() { return 0; } +int t() { +int s; +wait (&s); +s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; +; return 0; } +EOF +if eval $ac_compile; then + rm -rf conftest* + ac_cv_header_sys_wait_h=yes +else + rm -rf conftest* + ac_cv_header_sys_wait_h=no +fi +rm -f conftest* + +fi +echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6 +if test $ac_cv_header_sys_wait_h = yes; then + cat >> confdefs.h <<\EOF +#define HAVE_SYS_WAIT_H 1 +EOF + +fi + for ac_func in sbrk utimes do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 @@ -792,7 +832,7 @@ if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&6 else cat > conftest.$ac_ext < int main() { return 0; } @@ -874,7 +914,7 @@ if eval "test \"`echo '$''{'bu_cv_decl_time_t_types_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < int main() { return 0; } @@ -908,7 +948,7 @@ if eval "test \"`echo '$''{'bu_cv_header_utime_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #ifdef HAVE_TIME_H @@ -944,7 +984,7 @@ if eval "test \"`echo '$''{'bu_cv_decl_needed_fprintf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < int main() { return 0; } -- cgit v1.1