diff options
author | fluxgen <fluxgen> | 2004-08-31 21:25:33 (GMT) |
---|---|---|
committer | fluxgen <fluxgen> | 2004-08-31 21:25:33 (GMT) |
commit | 622af75c929bfc3f49e3a13775f356be1fd17ee6 (patch) | |
tree | e1a25437e7330e9fa3e28e0f3d36189274dfbb43 /configure.in | |
parent | 82de6ace6d64b95ec495a3a9df57d5729029825f (diff) | |
download | fluxbox-622af75c929bfc3f49e3a13775f356be1fd17ee6.zip fluxbox-622af75c929bfc3f49e3a13775f356be1fd17ee6.tar.bz2 |
checking for const msg in iconv
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/configure.in b/configure.in index 3bb27b2..cfacf35 100644 --- a/configure.in +++ b/configure.in | |||
@@ -63,7 +63,7 @@ size_t x = strftime(s, 5, "%a", localtime(&t)); | |||
63 | ], | 63 | ], |
64 | [AC_MSG_RESULT(no)]) | 64 | [AC_MSG_RESULT(no)]) |
65 | 65 | ||
66 | AC_MSG_CHECKING([iconv]) | 66 | AC_MSG_CHECKING([for iconv]) |
67 | AC_TRY_COMPILE( | 67 | AC_TRY_COMPILE( |
68 | [#include <iconv.h>], | 68 | [#include <iconv.h>], |
69 | [iconv_t cd = iconv_open("", "")], | 69 | [iconv_t cd = iconv_open("", "")], |
@@ -72,7 +72,18 @@ HAVE_ICONV=no) | |||
72 | 72 | ||
73 | if test x"$HAVE_ICONV" = x"yes"; then | 73 | if test x"$HAVE_ICONV" = x"yes"; then |
74 | AC_DEFINE(HAVE_ICONV, 1, "iconv") | 74 | AC_DEFINE(HAVE_ICONV, 1, "iconv") |
75 | AC_MSG_RESULT([yes]) | 75 | dnl now check for const char *msg argument in iconv(..) |
76 | AC_TRY_COMPILE( | ||
77 | [#include <iconv.h>], | ||
78 | [ | ||
79 | char **msg, **new_msg; | ||
80 | size_t result, inleft, outleft; | ||
81 | result = iconv((iconv_t)(-1), msg, &inleft, new_msg, &outleft); | ||
82 | return 0; | ||
83 | ], | ||
84 | [ AC_MSG_RESULT([yes (non const msg)])], | ||
85 | [ AC_DEFINE(HAVE_CONST_ICONV, 1, "iconv") | ||
86 | AC_MSG_RESULT([yes (const msg)])]) | ||
76 | else | 87 | else |
77 | AC_MSG_RESULT([no]) | 88 | AC_MSG_RESULT([no]) |
78 | fi | 89 | fi |