From owner-freebsd-hackers@FreeBSD.ORG Mon May 4 18:44:55 2009 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EA6AD1065678 for ; Mon, 4 May 2009 18:44:54 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from mail.netplex.net (mail.netplex.net [204.213.176.10]) by mx1.freebsd.org (Postfix) with ESMTP id 4B7188FC41 for ; Mon, 4 May 2009 18:44:54 +0000 (UTC) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.netplex.net (8.14.3/8.14.3/NETPLEX) with ESMTP id n44IiqHt015336; Mon, 4 May 2009 14:44:52 -0400 (EDT) X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.netplex.net) X-Greylist: Message whitelisted by DRAC access database, not delayed by milter-greylist-4.0 (mail.netplex.net [204.213.176.10]); Mon, 04 May 2009 14:44:53 -0400 (EDT) Date: Mon, 4 May 2009 14:44:52 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: xorquewasp@googlemail.com In-Reply-To: <20090504182714.GA52480@logik.internal.network> Message-ID: References: <20090504182714.GA52480@logik.internal.network> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-hackers@freebsd.org Subject: Re: bootstrapping gnat GCC on amd64 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 May 2009 18:44:57 -0000 On Mon, 4 May 2009, xorquewasp@googlemail.com wrote: > Hello. > > I'm attempting to compile GNAT on AMD64 with an eye to > extending support to the platform (the gnat-gcc43 port > is ONLY_FOR_ARCH=i386). > > GNAT obviously requires an Ada compiler to bootstrap. > > What are my options here? > > I suspect that I need to create an i386 jail to build > a cross compiler but am not sure. Is that your only system (amd64)? I originally ported GNAT to FreeBSD x86 from a solaris-sparc32 system. I built a sparc-sun-freebsd GNAT cross compiler using the native Solaris GNAT binary and its associated sources. I also (first) had to cross build binutils similarly. This made a cross compiler that ran on Solaris and built ELF binaries for FreeBSD. I then used this cross compiler to rebuild GNAT as a FreeBSD binary. So it was 2 major steps: build a cross compiler, then use the cross to build a native compiler. It's been years since I've done that. I don't know how much has changed, but you probably have to do something similar. -- DE