Re: [xml] Using libiconv

On Tue, Jul 03, 2001 at 12:06:16PM +0100, Brian Stafford wrote:
On Mon,  2 July 20:06 xml thewrittenword com wrote:
  2. If you have both libiconv in /usr/lib and /usr/local/lib
     and you wish the one in /usr/local/lib to win, set
     LDFLAGS="-L/usr/local/lib" before running configure.

I know this but this has nothing to do with the point.  You have
misunderstood the problem.  libiconv *replaces* the iconv.h from glibc.
The replacement iconv.h redefines the iconv_xxx functions to libiconv_xxx.  
Since AC_TRY_FUNC finds iconv in glibc but the compiler includes
the replacement iconv.h linking is guaranteed to fail.  But as you say,
you haven't tried it so you wouldn't know.

You are correct. The only solution is to AC_TRY_LINK and #include
<iconv.h> to get the redefinitions before checking for iconv in $LIBS
or -liconv.

albert chin (china thewrittenword com)

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]