File: acsite.m4

package info (click to toggle)
parser 3.4.4-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 7,104 kB
  • ctags: 7,425
  • sloc: cpp: 32,302; sh: 11,487; ansic: 10,845; yacc: 1,411; makefile: 247; awk: 5
file content (51 lines) | stat: -rw-r--r-- 965 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# paf@design.ru
# included in configure.ac

AC_DEFUN([PA_CHECK_MATH_FUNC_ONE_ARG],[
AC_MSG_CHECKING(for (maybe built-in) math function $1)
AC_TRY_COMPILE([
#ifdef HAVE_MATH_H
#       include <math.h>
#endif
],[
        double result=$1(1.6);
],
[AC_MSG_RESULT(yes)
$2],
[AC_MSG_RESULT(no)
$3])
]
)


AC_DEFUN([PA_CHECK_MATH_FUNCS_ONE_ARG],[
AC_FOREACH([AC_Func], [$1],
  [AH_TEMPLATE(AS_TR_CPP([HAVE_]AC_Func),
               [Define to 1 if you have the `]AC_Func[' (maybe built-in) math function function.])])dnl

for pa_func in $1
do
PA_CHECK_MATH_FUNC_ONE_ARG($pa_func,
	      [AC_DEFINE_UNQUOTED(AS_TR_CPP([HAVE_$pa_func]) $2)],
              [$3])dnl
done
])


AC_DEFUN([PA_CHECK_SIGSETJMP],[
pa_func=sigsetjmp
AC_MSG_CHECKING(for (maybe built-in) function $pa_func)
AC_TRY_COMPILE([
#ifdef HAVE_SETJMP_H
#	include <setjmp.h>
#endif
],[
        $pa_func(0,0);
],
[AC_MSG_RESULT(yes)
AC_DEFINE_UNQUOTED(AS_TR_CPP([HAVE_$pa_func]))
],
[AC_MSG_RESULT(no)
])
]
)