]> CyberLeo.Net >> Repos - FreeBSD/releng/9.2.git/blob - crypto/heimdal/cf/proto-compat.m4
- Copy stable/9 to releng/9.2 as part of the 9.2-RELEASE cycle.
[FreeBSD/releng/9.2.git] / crypto / heimdal / cf / proto-compat.m4
1 dnl $Id: proto-compat.m4 14166 2004-08-26 12:35:42Z joda $
2 dnl
3 dnl
4 dnl Check if the prototype of a function is compatible with another one
5 dnl
6
7 dnl AC_PROTO_COMPAT(includes, function, prototype)
8
9 AC_DEFUN([AC_PROTO_COMPAT], [
10 AC_CACHE_CHECK([if $2 is compatible with system prototype],
11 ac_cv_func_$2_proto_compat,
12 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[$1]],[[$3]])],
13 [eval "ac_cv_func_$2_proto_compat=yes"],
14 [eval "ac_cv_func_$2_proto_compat=no"]))
15 define([foo], translit($2, [a-z], [A-Z])[_PROTO_COMPATIBLE])
16 if test "$ac_cv_func_$2_proto_compat" = yes; then
17         AC_DEFINE(foo, 1, [define if prototype of $2 is compatible with
18         $3])
19 fi
20 undefine([foo])
21 ])