Building with libiconv



When building with libiconv things are a pain.

If libiconv is installed in /usr/local the supplied iconv.h overrides the
one with glibc.  This causes problems building some apps, e.g. GCC 3.0.
OTOH if libiconv is installed elsewhere balsa fails to build.

The following patch to configure.in fixes this

Index: configure.in
===================================================================
RCS file: /cvs/gnome/balsa/configure.in,v
retrieving revision 1.145
diff -u -r1.145 configure.in
--- configure.in        2001/08/08 15:44:53     1.145
+++ configure.in        2001/08/09 14:46:49
@@ -492,6 +492,13 @@
 dnl Link with iconv for charset translation, if not found
 dnl without library.  Needed for libmutt.
 dnl #############################################################
+AC_ARG_WITH(iconv,
+            [  --with-iconv=DIR           Where libiconv is installed ],
+           [if test "$with_iconv" != yes -a "$with_iconv" != no ; then
+                   CPPFLAGS="-I${with_iconv}/include $CPPFLAGS"
+                   LDFLAGS="-L${with_iconv}/lib $LDFLAGS"
+            fi])
+
 AC_CHECK_LIB(iconv, iconv_open, , [
        AC_CHECK_FUNC(iconv_open, , [
                        AC_MSG_ERROR([*** You need iconv for libmutt.])


Regards
Brian Stafford




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