Source
9
9
# found, and sets @ICONV_LDFLAGS@ and @ICONV_CFLAGS@ to the necessary
10
10
# values.
11
11
#
12
12
# This macro is distributed in the hope that it will be useful,
13
13
# but WITHOUT ANY WARRANTY; without even the implied warranty of
14
14
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15
15
16
16
AC_DEFUN([LIBICONV_TRY_LINK],
17
17
[
18
18
found_iconv=$1
19
-
AC_TRY_LINK(
20
-
[
19
+
AC_LINK_IFELSE([AC_LANG_PROGRAM([[
21
20
#include <stdlib.h>
22
21
#include <iconv.h>
23
-
],
24
-
[
22
+
]], [[
25
23
iconv_t cd = iconv_open("","");
26
24
iconv(cd, NULL, NULL, NULL, NULL);
27
25
iconv_close(cd);
28
-
],
29
-
found_iconv="yes")
26
+
]])],[found_iconv="yes"],[])
30
27
])dnl
31
28
32
29
AC_DEFUN([LIBICONV_CHECK_CONFIG],
33
30
[
34
31
AC_ARG_WITH([iconv],[
35
32
If you want to specify iconv installation directories:
36
33
AS_HELP_STRING([--with-iconv@<:@=DIR@:>@], [use iconv from given base install directory (DIR), default is to search through a number of common places for the iconv files.])],
37
34
[
38
35
if test "$withval" = "yes"; then
39
36
ICONV_CFLAGS="-I/usr/include"