* configure.ac: Use AC_CHECK_DECLS instead of gcc_AC_CHECK_DECLS

and BFD_NEED_DECLARATION.  Don't check if a declaration of strdup
is necessary.
* configure, config.in: Regenerate.
* utils.c: Adjust for usage of AC_CHECK_DECLS instead of
BFD_NEED_DECLARATION.  Never provide a prototype for
caninicalize_file_name.
* gdb_string.h: Adjust for usage of AC_CHECK_DECLS instead of
BFD_NEED_DECLARATION.
This commit is contained in:
Mark Kettenis
2005-01-21 13:14:02 +00:00
parent b717d30eb5
commit a3828db05a
6 changed files with 433 additions and 629 deletions

View File

@@ -424,7 +424,9 @@ AC_CHECK_HEADERS(ctype.h time.h)
# Checks for declarations. #
# ------------------------- #
gcc_AC_CHECK_DECLS(getopt)
AC_CHECK_DECLS([free, malloc, realloc])
AC_CHECK_DECLS([strerror, strstr])
AC_CHECK_DECLS(getopt)
# ----------------------- #
# Checks for structures. #
@@ -477,7 +479,7 @@ gdb_ptrace_headers='
#endif
'
# There is no point in checking if we don't have a prototype.
gcc_AC_CHECK_DECLS(ptrace, , [
AC_CHECK_DECLS(ptrace, [], [
: ${gdb_cv_func_ptrace_ret='int'}
: ${gdb_cv_func_ptrace_args='int,int,long,long'}
], $gdb_ptrace_headers)
@@ -694,14 +696,6 @@ if test $gdb_cv_have_uintptr_t = yes; then
AC_DEFINE(HAVE_UINTPTR_T, 1, [Define if <stdint.h> provides the uintptr_t type.])
fi
BFD_NEED_DECLARATION(malloc)
BFD_NEED_DECLARATION(realloc)
BFD_NEED_DECLARATION(free)
BFD_NEED_DECLARATION(strerror)
BFD_NEED_DECLARATION(strdup)
BFD_NEED_DECLARATION(strstr)
BFD_NEED_DECLARATION(canonicalize_file_name)
# If we are configured native on GNU/Linux, work around problems with
# sys/procfs.h
# Also detect which type of /proc is in use, such as for Unixware or Solaris.