From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18572 invoked by alias); 12 Apr 2007 15:00:47 -0000 Received: (qmail 18563 invoked by uid 22791); 12 Apr 2007 15:00:45 -0000 X-Spam-Check-By: sourceware.org Received: from oola.is.scarlet.be (HELO oola.is.scarlet.be) (193.74.71.23) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 12 Apr 2007 16:00:35 +0100 Received: from (ip-62-235-147-154.dsl.scarlet.be [62.235.147.154] (may be forged)) by oola.is.scarlet.be with ESMTP id l3CF0JM29743; Thu, 12 Apr 2007 17:00:19 +0200 Received: from [10.1.1.2] (dannypc [10.1.1.2]) by fw.local (Postfix) with ESMTP id B39B73683A; Thu, 12 Apr 2007 17:00:19 +0200 (CEST) Subject: Re: [PATCH] enabling gprof for cross builds From: Danny Backx To: Ben Elliston Cc: Sanjay Chadha , binutils@sourceware.org In-Reply-To: <1176338749.5535.8.camel@localhost> References: <000301c77ace$ee740120$1f28a8c0@Alps> <1176338749.5535.8.camel@localhost> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-E+l6Qhd/VV2Ws0MjvWjK" Date: Thu, 12 Apr 2007 15:13:00 -0000 Message-Id: <1176390019.14038.54.camel@dannypc> Mime-Version: 1.0 X-Mailer: Evolution 2.8.0-1mdv2007.0 X-DCC-scarlet.be-Metrics: oola 20001; Body=4 Fuz1=4 Fuz2=4 X-IsSubscribed: yes Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org X-SW-Source: 2007-04/txt/msg00148.txt.bz2 --=-E+l6Qhd/VV2Ws0MjvWjK Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Content-length: 1603 I played with this a while ago for cegcc, and got it to work. (Host environment is either linux or cygwin, target is Windows CE on ARM.) I have a patch that allows you to specify a different directory than the host source directory. That means : - you compile on a PC, sources in e.g. /home/danny/src/prog.c - by default, gcc compiles in a path /home/danny/src in which the executable will try to store its profile information - that is not always present on the mobile device - there is a way to change this directory at run time, but that isn't always easy (it isn't on CE) - so I've added a way to specify a different directory at compile time, meaning I can override the directory that gcc puts in the object file I've been wanting to submit the code but didn't get around to it yet. Should I clean it up and submit ? Danny On Thu, 2007-04-12 at 10:45 +1000, Ben Elliston wrote: > On Mon, 2007-04-09 at 13:45 -0400, Sanjay Chadha wrote: >=20 > > [schadha@devjava1-fc4 binutils-2.15.91.0.2]$ ./configure > > --target=3Dmipsel-linux --host=3D=3Dmipsel-linux > > [schadha@devjava1-fc4 binutils-2.15.91.0.2]$ make > >=20 > > However the compiled gprof was compiled for the host (i386) machine. Any > > ideas of what other changes may be required to cross compile gprof for > > the mips machine. >=20 > gprof runs on the host, not on the target (but it reads target object > code, of course). In your configure command line above, I see you used > =3D=3D, not =3D. Perhaps that is your problem. >=20 > Ben >=20 --=20 Danny Backx ; danny.backx - at - scarlet.be ; http://danny.backx.info --=-E+l6Qhd/VV2Ws0MjvWjK Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part Content-length: 189 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (GNU/Linux) iD8DBQBGHkmDNEE+KCROU2kRAtamAJ95H/nKQPw0N1S58BQBI+ZcmtwrlgCeIpu9 NFmAxM3JPW75qUIOXl6q8dg= =wfzp -----END PGP SIGNATURE----- --=-E+l6Qhd/VV2Ws0MjvWjK--