From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28275 invoked by alias); 7 Jul 2011 08:46:16 -0000 Received: (qmail 28264 invoked by uid 22791); 7 Jul 2011 08:46:15 -0000 X-SWARE-Spam-Status: No, hits=-0.1 required=5.0 tests=AWL,BAYES_00,RCVD_IN_SORBS_WEB X-Spam-Check-By: sourceware.org Received: from smtp.hosting.parsonline.net (HELO smtp.hosting.parsonline.net) (213.217.60.12) by sourceware.org (qpsmtpd/0.43rc1) with SMTP; Thu, 07 Jul 2011 08:45:57 +0000 Received: (qmail 41449 invoked from network); 7 Jul 2011 09:05:34 -0000 Received: from exit-node-readme.linuxfire.net (HELO ?127.0.0.1?) (mohsen@pahlevanzadeh.org@190.120.231.235) by 0 with SMTP; 7 Jul 2011 09:05:34 -0000 Subject: Re: binary debugging and generate source of which that running From: Mohsen Pahlevanzadeh To: harish badrinath Cc: gdb@sourceware.org In-Reply-To: References: <1309985511.4202.15.camel@debian> <1310013482.2302.9.camel@debian> Content-Type: multipart/signed; micalg="pgp-sha1"; protocol="application/pgp-signature"; boundary="=-z9oGVwIEim9nxJibaxGq" Date: Thu, 07 Jul 2011 08:46:00 -0000 Message-ID: <1310028334.2302.15.camel@debian> Mime-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2011-07/txt/msg00044.txt.bz2 --=-z9oGVwIEim9nxJibaxGq Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Content-length: 801 Yes, i'm using C and compiled with -g.I'm and run: gdb myprog (gdb)run --mohsen On Thu, 2011-07-07 at 12:50 +0530, harish badrinath wrote: > On Thu, Jul 7, 2011 at 10:08 AM, Mohsen Pahlevanzadeh > wrote: > > Dear all, > > > > I have a binary file what i compile it with -g.So i need to perform a > > set of action in my computer and see behavior of my file, This mean , i > > need to see functions of run when i perform those set of actions, So i > > need to tell to gdb : Please print source of which peace of program that > > running. > > How i do it? >=20 > You are using C ?? > I don=E2=80=99t think you can assume you have read access to a file that = you > are trying to executing, > apart from that why cant you just use GDB to do that whenever it is requi= red. --=-z9oGVwIEim9nxJibaxGq Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-length: 316 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iJwEAAECAAYFAk4Vci4ACgkQLL00bYOy4BY/dwP7B2kcdG8//O2dojZdhmOPfWJB Fg6B0IIm+ps9QD4omNhMCkGuueYw51Lh+1RoJEZGJEWwNC3jz9KBvZzcIKlgnchl QndyyR43CN7DgU6gacKSSfaAvzhWphmtg+pGOyX1MbjUkh/+muVl7q+4pf0ZTRb0 /YRqQ27xaVi6kSLdPSE= =kK1r -----END PGP SIGNATURE----- --=-z9oGVwIEim9nxJibaxGq--