From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24882 invoked by alias); 18 Apr 2002 18:51:38 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 24862 invoked from network); 18 Apr 2002 18:51:36 -0000 Received: from unknown (HELO anchor-post-31.mail.demon.net) (194.217.242.89) by sources.redhat.com with SMTP; 18 Apr 2002 18:51:36 -0000 Received: from mailgate.softwire.co.uk ([62.49.203.138] helo=polarbear) by anchor-post-31.mail.demon.net with esmtp (Exim 3.35 #1) id 16yH0J-000Adq-0V; Thu, 18 Apr 2002 19:51:35 +0100 From: "Rupert Wood" To: Cc: Subject: RE: build cross gcc for ppc-linux Date: Thu, 18 Apr 2002 17:15:00 -0000 Message-ID: <616BE6A276E3714788D2AC35C40CD18D120075@whale.softwire.co.uk> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal In-Reply-To: <616BE6A276E3714788D2AC35C40CD18D5B2A8F@whale.softwire.co.uk> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 X-SW-Source: 2002-04/txt/msg00199.txt.bz2 Harry Lin wrote: > On host : i686-pc-linux-gnu (Redhat 7.1) > to build powerpc-linux-gnu cross gcc 3.0.4, with binutils 2.12 > ./configure --target=powerpc-ibm-linux-gnu --with-newlib You shouldn't use newlib if you're targeting a specific OS; you should install or build headers and libraries specific to the OS. In this case, you should build glibc for your target or extract the headers and basic libraries from a binary PPC gnu/linux distribution. I'm afraid I don't know the specifics of doing this; you might have to build a powerpc-elf cross-compiler using newlib and then use that to build glibc for powerpc-linux-gnu, or there might be an easier way (integrate glibc into the sources tree and build in parallel?) but I'm not sure. In addition to glibc, you'll also need the linux/ and asm/ headers from the kernel source. > seeing errors of files not exist while compiling in rs6000/linux.h > about and , while there are such files > right there under /usr/include. These headers belong to the compile host and should not be used for the cross target. In you case, it's using only the headers provided with newlib. Good luck, Rup.