This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cannot find iconv() function


Dave Korn wrote:

  The standard autoconf library function detection test, for the sake of
simplicity, declares the function prototype itself rather than including the
header, so the name doesn't get translated and the function isn't found at
link time.

  A patch such as the attached makes the configure test check if it's
running on cygwin and look for libiconv() rather than iconv() in that case.
It made gtmess build for me.

Or, instead of using the AC_CHECK_FUNC([ ... iconv ...]) method in your configure.ac or configure.in file, you instead use AM_ICONV defined in /usr/share/iconv.m4. This file is part of the gettext-devel pacakge.


This solution assumes that gtmess is using the automake and aclocal tools, and not just autoconf. Otherwise, you could cut-n-paste the contents of /usr/share/iconv.m4 into gtmess's aclocal.m4 file -- and then use AM_ICONV in your configure.ac|configure.in file.

--
Chuck

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]