mirror of
https://github.com/samba-team/samba.git
synced 2025-01-27 14:04:05 +03:00
r18127: Add macro AC_CHECK_DECL() for systems that don't have it.
This commit is contained in:
parent
ce31b736a9
commit
589a1c2509
@ -1,3 +1,16 @@
|
||||
dnl see if a declaration exists for a function or variable
|
||||
dnl defines HAVE_function_DECL if it exists
|
||||
dnl AC_HAVE_DECL(var, includes)
|
||||
AC_DEFUN(AC_HAVE_DECL,
|
||||
[
|
||||
AC_CACHE_CHECK([for $1 declaration],ac_cv_have_$1_decl,[
|
||||
AC_TRY_COMPILE([$2],[int i = (int)$1],
|
||||
ac_cv_have_$1_decl=yes,ac_cv_have_$1_decl=no)])
|
||||
if test x"$ac_cv_have_$1_decl" = x"yes"; then
|
||||
AC_DEFINE([HAVE_]translit([$1], [a-z], [A-Z])[_DECL],1,[Whether $1() is available])
|
||||
fi
|
||||
])
|
||||
|
||||
dnl find the libreplace sources. This is meant to work both for
|
||||
dnl libreplace standalone builds, and builds of packages using libreplace
|
||||
libreplacedir=""
|
||||
|
Loading…
x
Reference in New Issue
Block a user