From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Greg Troxel Newsgroups: gmane.lisp.guile.devel Subject: Re: Guile 1.8 success on `i386-apple-darwin9.6.0' Date: Fri, 27 Mar 2009 14:34:01 -0400 Message-ID: References: <87prg49ppn.fsf@gnu.org> <87ocvo875p.fsf@gnu.org> <87r60kq9bc.fsf@arudy.ossau.uklinux.net> <87skl0vuex.fsf@gnu.org> <87iqlv2eyx.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Trace: ger.gmane.org 1238178905 19061 80.91.229.12 (27 Mar 2009 18:35:05 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 27 Mar 2009 18:35:05 +0000 (UTC) Cc: guile-devel@gnu.org To: ludo@gnu.org (Ludovic =?iso-8859-1?Q?Court=E8s?=) Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Fri Mar 27 19:36:22 2009 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.50) id 1LnGuj-0001gh-5O for guile-devel@m.gmane.org; Fri, 27 Mar 2009 19:36:21 +0100 Original-Received: from localhost ([127.0.0.1]:55673 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LnGtM-0006Ap-1a for guile-devel@m.gmane.org; Fri, 27 Mar 2009 14:34:56 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LnGsc-0005hT-IG for guile-devel@gnu.org; Fri, 27 Mar 2009 14:34:10 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LnGsW-0005a1-PV for guile-devel@gnu.org; Fri, 27 Mar 2009 14:34:09 -0400 Original-Received: from [199.232.76.173] (port=59864 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LnGsW-0005Zw-Fr for guile-devel@gnu.org; Fri, 27 Mar 2009 14:34:04 -0400 Original-Received: from fnord.ir.bbn.com ([192.1.100.210]:53488) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LnGsT-0005Kp-T3; Fri, 27 Mar 2009 14:34:02 -0400 Original-Received: by fnord.ir.bbn.com (Postfix, from userid 10853) id 19A8C53E7; Fri, 27 Mar 2009 14:34:01 -0400 (EDT) X-Hashcash: 1:20:090327:guile-devel@gnu.org::YjSu7XUTJ1xXsd51:0000000000000000000000000000000000000000000DOb X-Hashcash: 1:20:090327:ludo@gnu.org::WTgvFK6D1ChPRkeR:000005rRw In-Reply-To: <87iqlv2eyx.fsf@gnu.org> ("Ludovic =?iso-8859-1?Q?Court=E8s?= =?iso-8859-1?Q?=22's?= message of "Fri, 27 Mar 2009 15:54:46 +0100") User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/22.3 (berkeley-unix) X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. 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:8342 Archived-At: --=-=-= Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable ludo@gnu.org (Ludovic Court=E8s) writes: > Hi Greg, > > Greg Troxel writes: > >> I don't think that's true at all. It could be that for running Linux on >> arm pdas that's what most people do, but for the far more general case >> there is normal cross compiling as autoconf has supported for years. >> >> I am working on a project that does cross builds of a lot of software; >> none of it uses scratchbox. > > You may well have more experience than I have. Or maybe just different... I don't really understand the compiler. >> I can certainly see the point of something like scratchbox, to ease the >> process and work around software that has non-cross-clean build systems. >> But I wouldn't say it's time to give up on the normal/traditional way. > > How would you handle this particular case in a "cross-clean" way? The > problem is that we need a Guile to compile the compiler. Do we just need a (reasonable) guile, or do we need to run the target just-built guile itself? I saw some discussion about finding stack offsets, and that's perhaps different. I will use the terms 'host' and 'target' to describe the system one is doing the build on, and the the system that the resulting guile runs on. autoconf would call this 'build' and 'host'; 'host' refers to the machine for which a compiler is built, and target to what the compiler outputs. But we aren't really building a compiler in that sense, maybe. > I think it's not unusual to use just-built binaries to produce some > intermediate source files, especially in the area of interpreters and > compilers. How do others handle it? Yes, this is normal. I'll point out that some of my experience comes From=20the netbsd build system (to build the OS), and that experience affects my opinions. In NetBSD, basically all builds are cross, even if host=3D=3Dtarget, in that the host toolchain is used to build the NetBSD toolchain with the desired target, and then that is used to compile the system. One can build for other architectures, and from different host platforms in the same way. One of the things that has to be worked out to make a cross system function is the notion of 'host tool', which is a program that is compiled for the host. An example from netbsd is the time zone compiler, which shows up as nbzic in tools/bin. There's only one such binary even if you build for sparc64, i386, and alpha on an amd64 host. There are three compilers, though; each runs on amd64 and produces separate output. > IIRC GCC stage N uses `xgcc' from stage N-1 in the non-cross case. How > does it work in the cross-compilation case? There's a separate bootstrapping problem for compilers, which I think is about building gcc with host cc, and then building gcc with gcc, so that you get a gcc-compiled binary in the end. With cross, I think you have to build a gcc with target=3Dhost and then use that to build gcc with target=3Dtarget, but I'm not sure. So, building guile probably needs either to build guile as a host tool if host !=3D target, preferably in an objdir, and then that can be used. take a --with-guile that points to a working host guile, and people doing cross builds will have to build guile first. This is not really all that differnet from having to build a cross gcc first, and would be ok with me (as a cross user - my system doesn't have guile, but if it worked that way it would be fine). This can be the default behavior if autoconf's build and host (my host and target) differ. I suppose the host=3Dtarget case can use the same guile as the tool and the output, because the compiler is additional to the interpreter. If people use scratchbox, then the build is apparently not cross, even if the gcc that is invoked is cross. So this shouldn't hurt. --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (NetBSD) iEYEARECAAYFAknNHBkACgkQ+vesoDJhHiUNFwCdEWuD48cKiqSrLWCVgB8GqMB5 BhUAn0QU2JuJt1Z0yFsZlxl0qU9I7O9R =4pJv -----END PGP SIGNATURE----- --=-=-=--