Solved

DDD GDB HELP needed

Posted on 2004-04-13
8
331 Views
Last Modified: 2010-04-15
Hi, I am trying to debug my program using gdb, but I am getting this error for some reason:

(gdb) run test1.init /dev/null
Starting program: /auto/home-scf-27/chunchen/csci565/Lab3/test /dev/null

Program exited normally.
warning: Unable to find dynamic linker breakpoint function.
warning: GDB will be unable to debug shared library initializers
warning: and track explicitly loaded dynamic code.
You can't do that without a process to debug
(gdb)

I know the warning should not matter to my program but I am not sure why it says you can't do that without a process to debug.

The program i am loading is simply a program that prints 0 to 9.
I just wanted to test whether i can see the output in gdb or not.
As you can see, it does not print the output for some reason..

I did compile with -g flag.

Any help would be appreciated ..
thanks
0
Comment
Question by:lordiano
  • 3
  • 2
8 Comments
 
LVL 45

Expert Comment

by:sunnycoder
Comment Utility
What is the OS ? What version of gdb are you using ?
0
 
LVL 8

Expert Comment

by:ssnkumar
Comment Utility
I think the reason I is that the (dynamic) library you are using is stripped. Try a "nm /lib/libc.so.0" and if it doesn't display
any symbols you need to get a non-stripped version.

Mandrake 7.1 was shipped with some stripped libraries.
Hope you are not using that OS.

-ssnkumar
0
 

Author Comment

by:lordiano
Comment Utility
Problem solved, its some settings in my .cshrc file..
i will award points to those who answered nontheless!
thanks again guys
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 

Author Comment

by:lordiano
Comment Utility
sunnycoder, the problem was that i was soucing a non-default set of parameters in my .cshrc  
its actually kinda irrevelent to ddd or gdb... but rather environment setting issues.
0
 

Author Comment

by:lordiano
Comment Utility
source /usr/local/lib/master.cshrc

I think this parameter line is gonna be meaningless unless you are in USC heh
0
 
LVL 45

Accepted Solution

by:
sunnycoder earned 0 total points
Comment Utility
Question PAQed and 125 points refunded

sunnycoder
Page Editor
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

An Outlet in Cocoa is a persistent reference to a GUI control; it connects a property (a variable) to a control.  For example, it is common to create an Outlet for the text field GUI control and change the text that appears in this field via that Ou…
This is a short and sweet, but (hopefully) to the point article. There seems to be some fundamental misunderstanding about the function prototype for the "main" function in C and C++, more specifically what type this function should return. I see so…
The goal of this video is to provide viewers with basic examples to understand opening and reading files in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to create, access, and change arrays in the C programming language.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now