From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,e34c1fdf4f2b4b3 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-06-06 13:00:25 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!proxad.net!nerim.net!newsspool.nerim.net!not-for-mail From: Stephane Carrez Newsgroups: comp.lang.ada Subject: Re: Building GCC 3.3 cross compiler Date: Fri, 06 Jun 2003 22:00:23 +0200 Organization: Nerim -- xDSL Internet Provider Message-ID: <3EE0F2D7.3070405@nerim.fr> References: <5ad0dd8a.0306060826.4a691bb3@posting.google.com> NNTP-Posting-Host: stcarrez.net1.nerim.net Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Trace: biggoron.nerim.net 1054929624 87614 62.212.108.40 (6 Jun 2003 20:00:24 GMT) X-Complaints-To: abuse@nerim.net NNTP-Posting-Date: Fri, 6 Jun 2003 20:00:24 +0000 (UTC) To: Wojtek Narczynski User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.2) Gecko/20030208 Netscape/7.02 X-Accept-Language: en-us, en Xref: archiver1.google.com comp.lang.ada:38771 Date: 2003-06-06T22:00:23+02:00 List-Id: Hi! Wojtek Narczynski wrote: > Hello, > > Has anybody managed to build GCC 3.3-release cross compiler with Ada > support? I'm getting various errors. My host = i686-linux, target = > arm-linux. I'm trying to build it for Sharp Zaurus. > > For example: > > make[2]: Entering directory `/usr/src/packages/BUILD/gcc-3.3-obj/gcc' > ./gengenrtl -h > tmp-genrtl.h > /bin/sh: line 1: ./gengenrtl: cannot execute binary file > > linux:/usr/src/packages/BUILD/gcc-3.3-obj # file gcc/gengenrtl > gcc/gengenrtl: ELF 32-bit LSB executable, ARM, version 1 (ARM), > dynamically linked (uses shared libs), not stripped > > Would CVS sources from ACT or GNU give me a better chance for success? > > Regards, > Wojtek How did you configured and built gcc? It seems that it uses the target compiler (arm) to create the host gcc tools. gengenrtl and the like should be compiled by the native compiler. Not the cross compiler. I can't tell much about arm-linux but to create the 68HC11 cross compiler I use the following: 1/ I make sure that the native Ada compiler is in my path (I'm using gcc 3.3, compiled with --enable-languages=c,c++,ada) Check this with 'gcc -v', you should see something like: /usr/local/3.3/bin/gcc -v Reading specs from /usr/local/3.3/lib/gcc-lib/i686-pc-linux-gnu/3.3/specs Configured with: ../gcc-3.3/configure --enable-languages=c,c++,ada --prefix=/usr/local/3.3 Thread model: posix gcc version 3.3 2/ I make sure that the target (68HC11) binutils are available in my path too 3/ Configure the cross compiler: ./configure --target=m6811-elf --enable-languages=c,ada --prefix=m6811-elf- 4/ Build the stuff make or make bootstrap [Note: I don't remember if 'make bootstrap' works for building a cross compiler; It is absolutely mandatory when building a native compiler] For an arm, it should be fairly similar, Hope this helps, Stephane -- Home Office E-mail: stcarrez@nerim.fr Stephane.Carrez@solsoft.com WWW: http://stcarrez.nerim.net http://www.solsoft.com Free the Software! Simplifying Security Policy Management