LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 01-23-2008, 09:46 AM   #1
Hachaso
Member
 
Registered: May 2001
Posts: 42

Rep: Reputation: 15
Debuggin using Gnu tools


Hi!

I'm wondering if it's possible to do a debug like in Visual Studio, where you set a breakpoint and can trace different variables, using GNU tools???

I'm trying to use Emacs and gcc.

Thanks!
 
Old 01-23-2008, 11:02 AM   #2
alexagr
LQ Newbie
 
Registered: Jan 2008
Posts: 3

Rep: Reputation: 0
Sure - you'll need GDB (debugger) and some GUI front-end for it (e.g. DDD or KDBG). Also make sure that you compile and link your program with "-g" flag.
 
Old 01-23-2008, 11:29 AM   #3
bigearsbilly
Senior Member
 
Registered: Mar 2004
Location: england
Distribution: Mint, Armbian, NetBSD, Puppy, Raspbian
Posts: 3,515

Rep: Reputation: 239Reputation: 239Reputation: 239
ddd is good
 
Old 01-23-2008, 02:37 PM   #4
R00ts
Member
 
Registered: Mar 2004
Location: Austin TX, USA
Distribution: Ubuntu 11.10, Fedora 16
Posts: 547

Rep: Reputation: 30
Quote:
Originally Posted by bigearsbilly View Post
ddd is good
I personally hate ddd. I find the interface to be absolutely horrible, and although I forced myself numerous times to use it, I never really got much out of it.

kdbg I feel is a much, much nicer debugger. The interface is much more intuitive and you can learn how to use it pretty well in about ~5 minutes. The downside is that kdbg is incomplete (IMO) in a lot of respects, and could definitely use some improvements in certain areas. But I've been using it for the last few months and its helped me tremendously.
 
Old 01-23-2008, 03:13 PM   #5
ntubski
Senior Member
 
Registered: Nov 2005
Distribution: Debian, Arch
Posts: 3,780

Rep: Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081
Quote:
Originally Posted by Hachaso View Post
I'm trying to use Emacs and gcc.
Thanks!
Try M-x gdb.

see http://www.emacswiki.org/cgi-bin/wik...nifiedDebugger
and the Debuggers section in the Emacs manual
 
Old 01-24-2008, 03:09 AM   #6
Hachaso
Member
 
Registered: May 2001
Posts: 42

Original Poster
Rep: Reputation: 15
I forgot to say that I'm using Gnome.
So I suppose that Kdebug is for KDE.

I't a jungle out there of different tools.
I just want to find a good debug tool that does the job without to much effort spent on configuring etc.
 
Old 01-24-2008, 07:08 AM   #7
ntubski
Senior Member
 
Registered: Nov 2005
Distribution: Debian, Arch
Posts: 3,780

Rep: Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081Reputation: 2081
I think if you don't want to spend time configuring stuff you shouldn't use Emacs.

I believe Anjuta is the main Gnome IDE, and it has a debugger (gdb frontend). I've never actually used it though.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Microcross Releases GNU X-Tools v4.0 LXer Syndicated Linux News 1 01-06-2007 10:22 PM
GNU crosscompiler tools for ARM11 m.harshavardhan Linux - Hardware 0 07-21-2006 12:57 AM
gnu tools and mac os x Samsara Other *NIX 3 08-10-2005 12:00 PM
debuggin software drisay Slackware 1 10-13-2004 02:26 AM
modem debuggin normanty Linux - Newbie 1 10-27-2001 10:02 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:25 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration