1752786 Members
6129 Online
108789 Solutions
New Discussion юеВ

GDB64 on HPUX 11.11

 
Prasath
New Member

GDB64 on HPUX 11.11

Hi,

I have experienced some debugging related issues with C++ executables compiled with +DA2.0W option ( 64 bit ).

Setup:
aCC version used: HP ANSI C++ B3910B A.03.50.
aCC compiler option used: -g0
gdb64 version used: HP gdb 3.2 for PA-RISC 2.0 (wide), HP-UX 11.00.

Problem:
I have a shared library compiled with 64 bit ( +DA2.0W) and g0 options enbaled. This library is linked to a executable compiled with the same options.

When I use the debugger gdb64 and try to step into a function defined in the shared library, gdb64 ignores the command and goes to the next statement in the executable.

Can some one provide the solution?

Thanks.
3 REPLIES 3
Auxilia Jansi Rani
New Member

Re: GDB64 on HPUX 11.11

I guess the problem is due to deferred binding of shared libraries. This is a known problem.

If the function is called once (i.e., once the function is binded) then from next call, gdb will be able to step into the function.

You can either set a breakpoint to the function and step/continue for the first function call in gdb.
(or)
Compile the executable with -Wl,-Bimmediate option to allow immediate binding of shared libraries.

**Provide a testcase/snippet of your session to understand the problem if this not the problem you are seeing.
Prasath
New Member

Re: GDB64 on HPUX 11.11

Thanks for the solution. I used the -Wl,-Bimmediate option while linking and was able to step into the code present in shared library.
Prasath
New Member

Re: GDB64 on HPUX 11.11

Thanks.