From owner-freebsd-hackers Thu Jul 31 07:45:41 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id HAA12756 for hackers-outgoing; Thu, 31 Jul 1997 07:45:41 -0700 (PDT) Received: from eurogate.nortel.co.uk (eurogate.nortel.co.uk [192.100.101.3]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id HAA12713 for ; Thu, 31 Jul 1997 07:44:31 -0700 (PDT) Received: from hedera.bnr.co.uk (actually eharg1e1.nortel.co.uk) by eurogate.nortel.co.uk with SMTP (PP); Thu, 31 Jul 1997 14:00:52 +0000 Received: from bhars8cd.europe.nortel.com by hedera.bnr.co.uk with SMTP (PP); Thu, 31 Jul 1997 14:00:20 +0000 Received: from bharh4d4.europe.nortel.com by bhars8cd.europe.nortel.com (5.61++/UK-2.1-MX-nortel-(19970425)) with SMTP id AA03075; Thu, 31 Jul 97 15:00:11 +0100 Date: Thu, 31 Jul 1997 14:58:19 +0100 (BST) From: "Andy J. Smith" X-Sender: ajsmith@bharh4d4.europe.nortel.com To: "Daniel M. Eischen" Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Cross compiling for FreeBSD 3.0 In-Reply-To: <199707301555.KAA18490@iworks.InterWorks.org> Message-Id: Organisation: Nortel Technology Ltd. Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk On Wed, 30 Jul 1997, Daniel M. Eischen wrote: I have the source for binutils and gcc on my Linux developer's kit CDs, so presumably I just need to go ahead and: > Start with getting the Elfkit from: > > ftp://ftp.polstra.com/pub/FreeBSD/elfkit-1.2.1.tar.gz > ftp://ftp.polstra.com/pub/FreeBSD/elfkit-1.2.1.patch1 > > You'll need elfkit-1.2.1.patch1 and binutils-2.6.0.12.patch (the latter > patch coming from the elfkit tarball). Apply these patches to binutils-2.7 > (or 2.8). Read the READMEs in John Polstras elfkit if you are unsure > how to build a cross compiler - you don't need the elfkit for anything > other than the READMEs and patch. > > Pick a directory in which to want your cross-compilation system to > be installed (/usr/local/freebsdelf?) and build the patched binutils > with this prefix. Is there more info in the bin utils about doing this? I've never built binutils or gcc myself, having previously relied on the installed binaries. > Get the include files from a 3.0 FreeBSd system > and install them in /i386-unknown-freebsdelf/include. Do I need to take everything in /usr/include and below? > Grab > the necessary libraries from a 3.0 FreeBSD system and place them in > /i386-unknown-freebsdelf/lib. (I am assuming you're configuring > binutils/gcc for i386-unknown-freebsdelf). Yes. Again, is this everything from /usr/lib? I have a feeling this will be a somewhat massive set of files... > Configure gcc-2.7.2 for i386-unknown-freebsdelf and your chosen prefix. > Build and install gcc. I believe I've seen gcc documentation on this: Setting up gcc as a cross compiler, the gcc --target etc., is this the right stuff? > You're now ready to start cross compiling. I know I left out some > of the details - I have more precise notes at home if you need them. On the areas I mentioned above, yes please! Thanks, Andy Ways to annoy your roommate #8: Always flush the toilet three times.