X-Recipient: archive-cygwin@delorie.com
X-Spam-Check-By: sourceware.org
Message-ID: <20071004202558.gn6sv47ayockk8s8@webmail.udc.es>
Date: Thu, 04 Oct 2007 20:25:58 +0200
From: Alberto Luaces =?iso-8859-1?b?RmVybuFuZGV6?= <aluaces@udc.es>
To: cygwin@cygwin.com
Subject: RE: Debugging with cygwin tools
References: <4704CA0F.9010907@udc.es> <fe302e$8t3$1@sea.gmane.org> 	<016801c806a4$501cd850$2e08a8c0@CAM.ARTIMI.COM>
In-Reply-To: <016801c806a4$501cd850$2e08a8c0@CAM.ARTIMI.COM>
MIME-Version: 1.0
Content-Type: text/plain; 	charset=ISO-8859-1; 	DelSp="Yes"; 	format="flowed"
Content-Disposition: inline
User-Agent: Internet Messaging Program (IMP) H3 (4.1.1)
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id l94IQPYC015255

Dave Korn <dave.korn@artimi.com>:

> On 04 October 2007 16:15, René Berber wrote:
>
>> Alberto Luaces wrote:
>>
>>> I am just starting to learn how to use the debugging tools available in
>>> Cygwin. To do so, I have a test program deliberately designed to crash:
>>> [snip] I have compiled it with debugging information:
>>>
>>> g++ -g -O0 -o core core.cpp
>>>
>>> Then I try to run it with gdb:
>>>
>>> gdb core.exe
>>>
>>> (gdb) b main
>>> Breakpoint 1 at 0x401175: file core.cpp, line 4.
>>> (gdb) r
>>> Starting program: /home/Demostración/testsC++/core.exe
>>> Error: dll starting at 0x77d41000 not found.
>> --^^^^^
>> Isn't this clear?
>>
>> [snip]
>>> How can I finally debug my program?
>>
>> You probably have a problem with your PATH, take a look at it with `echo
>> $PATH`,
>
>   Hey, I think you don't really mean to use backtick quotes there... :)
>
>> it should include /usr/bin and /cygdrive/c/WINDOWS/system32 or
>> similar if you renamed the root, it should NOT have syntax errors... which
>> is probably the cause of your problem.
>
>   Also, running "cygcheck core.exe" should show up any missing DLL straight
> away.

Dave, René,

thanks for the tips, I will check the PATH and look for missing DLLs  
then, although my program is nothing more than a main function  
dereferencing a null pointer, so it should not have any special  
dependencies.

The missing DLL message was a bit misleading because gdb crashes after  
printing it, so I thought it was an error message from gdb.exe and not  
from my program.

Maybe the non 7-bit ASCII character found on my user name  
(Demostración) is causing some issues with PATH, could I try to rename  
my home directory directly or would I need to change something more?

At least I have now several things to try...

Alberto



----------------------------------------------------------------
Correo enviado usando el servicio de Webmail de la UDC.



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


