mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-03 02:41:24 +08:00
Define OL_DECL_STRDUP, the current declaration conflicts with GLIBC 2.1's
macro definition. If the declaration errors, then we don't declare it in ac/string.h
This commit is contained in:
parent
8654f340cb
commit
da5444cee5
@ -412,7 +412,7 @@ AC_MSG_RESULT($ol_cv_dcl_sys_errlist)
|
||||
# It's possible (for near-UNIX clones) that sys_errlist doesn't exist
|
||||
if test $ol_cv_dcl_sys_errlist = no ; then
|
||||
AC_DEFINE(DECL_SYS_ERRLIST,1,
|
||||
[define if sys_errlist is declared in stdio.h or errno.h])
|
||||
[define if sys_errlist is not declared in stdio.h or errno.h])
|
||||
AC_MSG_CHECKING([existence of sys_errlist])
|
||||
AC_CACHE_VAL(ol_cv_have_sys_errlist,[
|
||||
AC_TRY_LINK([#include <errno.h>],
|
||||
@ -426,6 +426,25 @@ if test $ol_cv_dcl_sys_errlist = no ; then
|
||||
fi
|
||||
fi
|
||||
])dnl
|
||||
dnl
|
||||
dnl ====================================================================
|
||||
dnl Check to see if we should not declare strdup if we have it
|
||||
dnl
|
||||
AC_DEFUN([OL_DECL_STRDUP],
|
||||
[
|
||||
AC_MSG_CHECKING([strdup decleration])
|
||||
AC_CACHE_VAL(ol_cv_dcl_strdup,[
|
||||
AC_TRY_COMPILE([
|
||||
#include <string.h> ],
|
||||
[extern char *strdup()],
|
||||
[ol_cv_dcl_strdup=yes],
|
||||
[ol_cv_dcl_strdup=no])])
|
||||
AC_MSG_RESULT($ol_cv_dcl_strdup)
|
||||
if test $ol_cv_dcl_strdup = yes ; then
|
||||
AC_DEFINE(DECL_STRDUP,1,
|
||||
[define if you have strdup() but it's not declared])
|
||||
fi
|
||||
])dnl
|
||||
|
||||
dnl ====================================================================
|
||||
dnl Early MIPS compilers (used in Ultrix 4.2) don't like
|
||||
|
Loading…
Reference in New Issue
Block a user