From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Jan Nieuwenhuizen Newsgroups: gmane.lisp.guile.devel Subject: Re: cross building 1.9.14 for mingw Date: Tue, 15 Feb 2011 11:20:59 +0100 Organization: www.AvatarAcademy.nl Message-ID: <1297765259.2325.283.camel@vuurvlieg> References: <1296330082.8111.371.camel@vuurvlieg> <874o8r8kdn.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1297765295 4932 80.91.229.12 (15 Feb 2011 10:21:35 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 15 Feb 2011 10:21:35 +0000 (UTC) Cc: guile-devel@gnu.org To: Ludovic =?ISO-8859-1?Q?Court=E8s?= Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Tue Feb 15 11:21:31 2011 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PpI2F-0002Vr-9r for guile-devel@m.gmane.org; Tue, 15 Feb 2011 11:21:31 +0100 Original-Received: from localhost ([127.0.0.1]:59321 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PpI2E-0008R5-Ni for guile-devel@m.gmane.org; Tue, 15 Feb 2011 05:21:30 -0500 Original-Received: from [140.186.70.92] (port=49316 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PpI1s-0008HC-I2 for guile-devel@gnu.org; Tue, 15 Feb 2011 05:21:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PpI1r-0005Z9-As for guile-devel@gnu.org; Tue, 15 Feb 2011 05:21:08 -0500 Original-Received: from smtp-vbr19.xs4all.nl ([194.109.24.39]:2862) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PpI1r-0005Yz-00; Tue, 15 Feb 2011 05:21:07 -0500 Original-Received: from [192.168.1.112] (peder.onsbrabantnet.nl [88.159.206.46] (may be forged)) (authenticated bits=0) by smtp-vbr19.xs4all.nl (8.13.8/8.13.8) with ESMTP id p1FAKx2d087534; Tue, 15 Feb 2011 11:21:06 +0100 (CET) (envelope-from janneke-list@xs4all.nl) In-Reply-To: <874o8r8kdn.fsf@gnu.org> X-Mailer: Evolution 2.30.3 X-Virus-Scanned: by XS4ALL Virus Scanner X-MIME-Autoconverted: from 8bit to quoted-printable by smtp-vbr19.xs4all.nl id p1FAKx2d087534 X-detected-operating-system: by eggs.gnu.org: FreeBSD 4.6-4.9 X-Received-From: 194.109.24.39 X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:11635 Archived-At: Ludovic Court=C3=A8s schreef op za 29-01-2011 om 22:34 [+0100]: > > From 4aeb4bb48423d87001b598030afed0a2dc03e747 Mon Sep 17 00:00:00 200= 1 > > From: Jan Nieuwenhuizen > > Date: Sat, 29 Jan 2011 19:42:46 +0100 > > Subject: [PATCH 2/4] Use AC_CHECK_LIB rather than AC_LIB_HAVE_LINKFLA= GS. Fixes cross configuring. > > > > AC_LIB_HAVE_LINKFLAGS blondly looks in $prefix etc. for libraries. > > Not only is that unnecessary, it also breaks cross building. > > > > Here's what config.log says: > > > > configure:33053: i686-mingw32-gcc -mms-bitfields -std=3Dgnu99 -o = conftest.exe -O2 -DHAVE_CONFIG_H=3D1 -I/home/janneke/vc/gub/target/mingw/= build/guile-1.9.14 -I/home/janneke/vc/gub/target/mingw/root/usr/include -= L/home/janneke/vc/gub/target/mingw/root/usr/lib -L/home/janneke/vc/gub/ta= rget/mingw/root/usr/bin -L/home/janneke/vc/gub/target/mingw/root/usr/lib/= w32api conftest.c /usr/lib/libltdl.a /usr/lib/libdl.a >&5 > > /tmp/cc5v8vq5.o:conftest.c:(.text+0x1e): undefined reference to `= _lt_dlopenext' > > > > note that using -lltdl -ldl instead of /usr/lib/libltdl.a > > /usr/lib/libdl.la works fine. >=20 > Ouch. May I suggest reporting it to bug-gnulib@gnu.org? :-) I think > people there would be happy to provide an appropriate fix and we > wouldn=E2=80=99t even have to worry. ;-) I did, and Bruno Haible does not really care about this brokenness or about cross compiling; he throws the towel on fixing this and defends it by arguing that there are more users with a broken compiler/linker, installed in /usr, which must be helped to find libs in /usr/lib, than there are cross build users who have a sane setup and=20 suffer by this. In fact he thinks it's a feature that configure breaks when you "upgrade" from autoconf's AC_CHECK_LIB to gnulib's AC_LIB_HAVE_LINKFLAGS. So I would suggest to take my patch and not use AC_LIB_HAVE_LINKFLAGS, and possibly work with Ralf Wildenhues from autotools to provide any extra autoconf functionality in autoconf itself, rather than working through gnulib. Ralf does have a good understandng about cross building. Bruno suggests that cross build environments (or more accurately, build environments that install in another or clean DESTDIR than where the buildtools are), should now start using or introduce special configure flags, so that what worked previously, now can be fixed by a tedious manual process, he writes For example, gettext's "configure --help" contains: --without-libpth-prefix don't search for PACKLIBS in includedir and= libdir --without-libiconv-prefix don't search for PACKLIBS in includedir a= nd libdir --without-libintl-prefix don't search for PACKLIBS in includedir an= d libdir --without-libglib-2.0-prefix don't search for PACKLIBS in includedi= r and libdir --without-libcroco-0.6-prefix don't search for PACKLIBS in included= ir and libdir --without-libunistring-prefix don't search for PACKLIBS in included= ir and libdir --without-libxml2-prefix don't search for PACKLIBS in includedir an= d libdir --without-libncurses-prefix don't search for PACKLIBS in includedir= and libdir --without-libtermcap-prefix don't search for PACKLIBS in includedir= and libdir --without-libxcurses-prefix don't search for PACKLIBS in includedir= and libdir --without-libcurses-prefix don't search for PACKLIBS in includedir = and libdir --without-libexpat-prefix don't search for PACKLIBS in includedir a= nd libdir Greetings, Jan. --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.= nl =20