[LC++]Line by Line debug in linux.

Shaul Karl shaulk at 013.net
Sat Oct 2 18:33:01 UTC 2004

On Sat, Oct 02, 2004 at 10:17:27AM +0330, mojtaba mahdavi wrote:
> Hi. All. 
> As I told before I am ( want not to be ) a windows programmer (not expert). 
> There (in windows) I could debug my program line by line and watch
> execution of my program line by line and could see variables and
> more...
> 1- Now how can I use same approach in Linux. ( Is there any tutorials on web? ) 

  You need a debugger or an IDE, which is probably what you are used to
in Windows. IDE stands for Integrated Development Environment. I believe
gdb is one of the most popular debuggers in the Linux world. It is text
based but there are many GUI front ends. As for a gdb tutorial, there
should be some introductory texts available, both on the net and within
the gdb documentation. You might want to try a google search.

> 2- Should I use some more option when compile my codes ?? 

  For compiling with g++, it could be that you also need the -g flag.
IIRC, this flag has something to do with preserving the symbols name
within the executable. You might want to look in gcc documentation.

> Now I am using cygwin since I am in a migration cycle for my project ?? 

  I do believe those tools are included in cygwin too. Yet I have no
experience with cygwin.

> Sincerely all Linux programmers 

  Hopefully you will get better replies.

More information about the tuxCPProgramming mailing list