Return-Path: Delivered-To: apmail-apr-dev-archive@apr.apache.org Received: (qmail 82162 invoked by uid 500); 21 Jul 2002 08:08:14 -0000 Mailing-List: contact dev-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Delivered-To: mailing list dev@apr.apache.org Delivered-To: moderator for dev@apr.apache.org Received: (qmail 33193 invoked from network); 21 Jul 2002 05:20:01 -0000 Date: Sun, 21 Jul 2002 00:20:02 -0500 From: Albert Chin To: Branko Cibej Cc: Justin Erenkrantz , Ben Collins-Sussman , dev@apr.apache.org, dev@subversion.tigris.org Subject: Re: [PATCH] link againt iconv on bsd Message-ID: <20020721002002.A83532@oolong.il.thewrittenword.com> Reply-To: dev@subversion.tigris.org References: <86lm87o42z.fsf@kepler.ch.collab.net> <20020719213435.GM17660@apache.org> <3D3892DA.7050608@xbc.nu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <3D3892DA.7050608@xbc.nu>; from brane@xbc.nu on Sat, Jul 20, 2002 at 12:29:46AM +0200 X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N On Sat, Jul 20, 2002 at 12:29:46AM +0200, Branko Cibej wrote: > Probably should check for the libc iconv first, and have_iconv must > always have a value; so tis would become: > > AC_CHECK_FUNCS(iconv, [ have_iconv="1" ], [ > AC_CHECK_LIB(iconv, iconv, [ > APR_ADDTO(APRUTIL_EXPORT_LIBS,[-liconv]) > APR_ADDTO(APRUTIL_LIBS,[-liconv]) > have_iconv="1" > ], > [ have_iconv="0" ] > ]) This won't work with GNU libiconv. Pull down the source for libxml and look at how they do it then steal it. Don't assume that "iconv" is the name of a valid function in -liconv. #include first to handle redefinitions of iconv. >From libiconv 1.8 build on Solaris 7: $ nm libiconv.so | grep iconv ... [801] | 131348| 56|FUNC |GLOB |0 |8 |libiconv [811] | 131420| 20|FUNC |GLOB |0 |8 |libiconv_close [803] | 130096| 1252|FUNC |GLOB |0 |8 |libiconv_open [828] | 131456| 308|FUNC |GLOB |0 |8 |libiconvctl [817] | 131940| 404|FUNC |GLOB |0 |8 |libiconvlist >From ... #ifndef LIBICONV_PLUG #define iconv libiconv #endif ... -- albert chin (china@thewrittenword.com)