Source
12
12
#
13
13
# Users may override the detected values by doing something like:
14
14
# GNUTLS_LIBS="-lgnutls" GNUTLS_CFLAGS="-I/usr/myinclude" ./configure
15
15
#
16
16
# This macro is distributed in the hope that it will be useful,
17
17
# but WITHOUT ANY WARRANTY; without even the implied warranty of
18
18
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
19
19
20
20
AC_DEFUN([LIBGNUTLS_TRY_LINK],
21
21
[
22
-
AC_TRY_LINK(
23
-
[
22
+
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
24
23
#include <gnutls/gnutls.h>
25
-
],
26
-
[
24
+
]], [[
27
25
gnutls_global_init();
28
-
],
29
-
found_gnutls="yes",)
26
+
]])],[found_gnutls="yes"],[])
30
27
])dnl
31
28
32
29
AC_DEFUN([LIBGNUTLS_ACCEPT_VERSION],
33
30
[
34
31
# Zabbix minimal supported version of libgnutls:
35
32
minimal_gnutls_version_major=3
36
33
minimal_gnutls_version_minor=1
37
34
minimal_gnutls_version_patch=18
38
35
39
36
# get version
53
50
accept_gnutls_version="yes"
54
51
else
55
52
accept_gnutls_version="no"
56
53
fi;
57
54
])dnl
58
55
59
56
AC_DEFUN([LIBGNUTLS_CHECK_CONFIG],
60
57
[
61
58
AC_ARG_WITH(gnutls,[
62
59
If you want to use encryption provided by GnuTLS library:
63
-
AC_HELP_STRING([--with-gnutls@<:@=DIR@:>@],[use GnuTLS package @<:@default=no@:>@, DIR is the libgnutls install directory.])],
60
+
AS_HELP_STRING([--with-gnutls@<:@=DIR@:>@],[use GnuTLS package @<:@default=no@:>@, DIR is the libgnutls install directory.])],
64
61
[
65
62
if test "$withval" = "no"; then
66
63
want_gnutls="no"
67
64
_libgnutls_dir="no"
68
65
elif test "$withval" = "yes"; then
69
66
want_gnutls="yes"
70
67
_libgnutls_dir="no"
71
68
else
72
69
want_gnutls="yes"
73
70
_libgnutls_dir=$withval