From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20433 invoked by alias); 23 Jun 2003 04:22:50 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 20386 invoked from network); 23 Jun 2003 04:22:48 -0000 Received: from unknown (HELO crack.them.org) (146.82.138.56) by sources.redhat.com with SMTP; 23 Jun 2003 04:22:48 -0000 Received: from dsl093-172-017.pit1.dsl.speakeasy.net ([66.93.172.17] helo=nevyn.them.org ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 19UIrW-0003Vm-00; Sun, 22 Jun 2003 23:23:26 -0500 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 19UIqd-0005BT-00; Mon, 23 Jun 2003 00:22:31 -0400 Date: Mon, 23 Jun 2003 13:01:00 -0000 From: Daniel Jacobowitz To: Peter Barada Cc: dank@kegel.com, zack@codesourcery.com, pinskia@physics.uc.edu, wilson@tuliptree.org, gcc@gcc.gnu.org Subject: Re: cross-compilation documentation Message-ID: <20030623042231.GA19910@nevyn.them.org> Mail-Followup-To: Peter Barada , dank@kegel.com, zack@codesourcery.com, pinskia@physics.uc.edu, wilson@tuliptree.org, gcc@gcc.gnu.org References: <02F74B2F-A4D6-11D7-AD8C-000393A6D2F2@physics.uc.edu> <878yruf1pl.fsf@egil.codesourcery.com> <3EF5FACA.9020400@kegel.com> <87znkadj94.fsf@egil.codesourcery.com> <20030622193607.98A4D98DFD@baradas.org> <20030622194204.GA7163@nevyn.them.org> <20030623024805.6D3E998DFD@baradas.org> <3EF66E11.3080509@kegel.com> <20030623025952.CE49398DFD@baradas.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030623025952.CE49398DFD@baradas.org> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-06/txt/msg01903.txt.bz2 On Sun, Jun 22, 2003 at 10:59:52PM -0400, Peter Barada wrote: > > >Well, sure! My script at http://kegel.com/crosstool does this: > >1) configure glibc and do 'make install-headers'; a wee bit of hackery > > circumvents its urge to build everything > >2) build and install bootstrap compiler > >3) build and install real glibc > >4) build and install real gcc > > > >My step #1 isn't pretty, but it only takes a couple minutes, and I'm > >sure it's faster than what you described. I thought you knew about > >that already... > > Yes I did. I use the following Makefile fragment to get the headers: > > glibc1: ${GLIBC_BUILDDIR1} glibc1-fix > export PATH=${INSTALL_DIR}/bin:${HOST_INSTALL_DIR}/bin:$$PATH; \ > cd ${GLIBC_BUILDDIR1}; \ > CC=${TARGET}-gcc AR=${TARGET}-ar RANLIB=${TARGET}-ranlib \ > ${GLIBC_SOURCE_PATH}/configure --host=${TARGET} \ > --prefix=/usr --without-cvs --disable-sanity-checks \ > --with-headers=${INSTALL_DIR}/${TARGET}/include ; \ > make cross-compiling=yes install_root=${INSTALL_DIR}/${TARGET} prefix="" install-headers > > glibc1-fix: > mkdir -p ${INSTALL_DIR}/${TARGET}/include/gnu ; \ > touch ${INSTALL_DIR}/${TARGET}/include/gnu/stubs.h ; \ > cp -f ${GLIBC_SOURCE_PATH}/include/features.h ${INSTALL_DIR}/include/features.h > > > But this fragment *requires* a cross-compiler to build it. I'm sure I Not really. I do it with a sufficiently new native compiler to run configure. Configure determines $target by the command line arguments, not by querying the $CC you specify. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer