Mirror of the gdb mailing list
 help / color / mirror / Atom feed
* no attribute '_handle_missing_debuginfo'
@ 2024-10-07 22:53 Robert Dubner
  2024-10-08  6:13 ` Aktemur, Tankut Baris via Gdb
  0 siblings, 1 reply; 3+ messages in thread
From: Robert Dubner @ 2024-10-07 22:53 UTC (permalink / raw)
  To: gdb

I admit defeat, and I throw myself on the mercy of the court.

I really tried.  I searched the internet.  I spent some time digging
through the GDB source code.  But I have been thwarted by the sheer number
of moving parts.

One line background as to why I am compiling GDB:  I am part of an effort
to build a COBOL front end for GCC, and I am making modifications to GDB
to handle the idiosyncracies of COBOL executables.

That said: When I compile and run GDB, I am getting the following
announcement on stderr:

===
Python Exception <class 'AttributeError'>: module 'gdb' has no attribute
'_handle_missing_debuginfo'
===

I believe in my heart that this has to have a simple cause, and I believe
that somewhere there is a switch that can be moved from "broken" to
"fixed" and the message will go away.

But I haven't been able to find it.

I hope some kind soul can embarrass me with a fix.  Go ahead.  I can take
it.

Thanks!

I just now built and compiled the GDB master branch 3f30f11f6d5, which was
committed on 2024-10-07

bob@doobie:~/repos/gdb-cobol/gcobol$ GDB --configuration
This GDB was configured as follows:
   configure --host=x86_64-linux-gnu --target=x86_64-linux-gnu
             --with-auto-load-dir=$debugdir:$datadir/auto-load
             --with-auto-load-safe-path=$debugdir:$datadir/auto-load
             --with-expat
             --with-gdb-datadir=/usr/share/gdb
             --with-jit-reader-dir=/usr/lib/gdb
             --without-libunwind-ia64
             --with-lzma
             --with-babeltrace
             --with-intel-pt
             --with-xxhash
             --with-python=/usr
             --with-python-libdir=/usr/lib
             --with-debuginfod
             --with-curses
             --without-guile
             --without-amd-dbgapi
             --enable-source-highlight
             --enable-threading
             --enable-tui
             --without-system-readline
             --with-separate-debug-dir=/usr/lib/debug
             --with-system-gdbinit=/etc/gdb/gdbinit
             --with-system-gdbinit-dir=/etc/gdb/gdbinit.d

bob@doobie:~/repos/gdb-cobol/gcobol$ GDB --version
GNU gdb (GDB-COBOL 14.0.7 (debuggable)) 16.0.50.20241007-git

bob@doobie:~/repos/gdb-cobol/gcobol$ GDB -q
(gdb) python
>print(sys.version)
>end
3.10.12 (main, Sep 11 2024, 15:47:36) [GCC 11.4.0]

(gdb) file ctest
Reading symbols from ctest...
(gdb) start
Temporary breakpoint 1 at 0x122a: file ctest.c, line 19.
Starting program: /home/bob/repos/gdb-cobol/gcobol/ctest
Python Exception <class 'AttributeError'>: module 'gdb' has no attribute
'_handle_missing_debuginfo'
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".

Temporary breakpoint 1, main (argc=1, argv=0x7fffffffe328) at ctest.c:19


^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: no attribute '_handle_missing_debuginfo'
  2024-10-07 22:53 no attribute '_handle_missing_debuginfo' Robert Dubner
@ 2024-10-08  6:13 ` Aktemur, Tankut Baris via Gdb
  2024-10-08 18:15   ` Robert Dubner
  0 siblings, 1 reply; 3+ messages in thread
From: Aktemur, Tankut Baris via Gdb @ 2024-10-08  6:13 UTC (permalink / raw)
  To: Robert Dubner, gdb

On Tuesday, October 8, 2024 12:54 AM, Robert Dubner wrote:
> bob@doobie:~/repos/gdb-cobol/gcobol$ GDB --version
> GNU gdb (GDB-COBOL 14.0.7 (debuggable)) 16.0.50.20241007-git
> 
> bob@doobie:~/repos/gdb-cobol/gcobol$ GDB -q
> (gdb) python
> >print(sys.version)
> >end
> 3.10.12 (main, Sep 11 2024, 15:47:36) [GCC 11.4.0]
> 
> (gdb) file ctest
> Reading symbols from ctest...
> (gdb) start
> Temporary breakpoint 1 at 0x122a: file ctest.c, line 19.
> Starting program: /home/bob/repos/gdb-cobol/gcobol/ctest
> Python Exception <class 'AttributeError'>: module 'gdb' has no attribute
> '_handle_missing_debuginfo'
> [Thread debugging using libthread_db enabled]
> Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
> 
> Temporary breakpoint 1, main (argc=1, argv=0x7fffffffe328) at ctest.c:19

What is 'GDB' in the commands above?  Is it an alias to the gdb binary 
in your build folder?  If you're using your locally-built gdb binary
from the build folder and not the install folder, please try passing
the data-directory flag.  Otherwise, a data-directory in a more default
location takes precedence.

  $ /<path-to-build-folder>/gdb/gdb -q --data-directory=/<path-to-build-folder>/gdb/data-directory

You can run the "show data-directory" command to check if it is pointing
to the right folder.

-Baris


Intel Deutschland GmbH
Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
Tel: +49 89 99 8853-0, www.intel.de
Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany Doon Silva
Chairperson of the Supervisory Board: Nicole Lau
Registered Office: Munich
Commercial Register: Amtsgericht Muenchen HRB 186928


^ permalink raw reply	[flat|nested] 3+ messages in thread

* RE: no attribute '_handle_missing_debuginfo'
  2024-10-08  6:13 ` Aktemur, Tankut Baris via Gdb
@ 2024-10-08 18:15   ` Robert Dubner
  0 siblings, 0 replies; 3+ messages in thread
From: Robert Dubner @ 2024-10-08 18:15 UTC (permalink / raw)
  To: Aktemur, Tankut Baris, gdb

Baris, thank you for responding.

Your speculation is correct; GDB is my alias to the
"<build_folder>/gdb/gdb" executable in my build tree.  I am in the
position of using the system-installed 'gdb' to debug my locally-built
gdb, so for now I don't want to install the locally-built version.

Your suggestion was accurate.  My locally-built GDB was using the
/usr/share/gdb data directory of the system-installed gdb-12.1

When I specify --data-directory as you described, the " no attribute
'_handle_missing_debuginfo'" message no longer appears.

Fun fact: When --data-directory=misspelled-directory-path is used, a
number of new and exciting error messages appear!

Thank you so much for taking the time to answer my question.

Bob Dubner

> -----Original Message-----
> From: Aktemur, Tankut Baris <tankut.baris.aktemur@intel.com>
> Sent: Tuesday, October 8, 2024 02:14
> To: Robert Dubner <rdubner@symas.com>; gdb@sourceware.org
> Subject: RE: no attribute '_handle_missing_debuginfo'
> 
> On Tuesday, October 8, 2024 12:54 AM, Robert Dubner wrote:
> > bob@doobie:~/repos/gdb-cobol/gcobol$ GDB --version GNU gdb (GDB-COBOL
> > 14.0.7 (debuggable)) 16.0.50.20241007-git
> >
> > bob@doobie:~/repos/gdb-cobol/gcobol$ GDB -q
> > (gdb) python
> > >print(sys.version)
> > >end
> > 3.10.12 (main, Sep 11 2024, 15:47:36) [GCC 11.4.0]
> >
> > (gdb) file ctest
> > Reading symbols from ctest...
> > (gdb) start
> > Temporary breakpoint 1 at 0x122a: file ctest.c, line 19.
> > Starting program: /home/bob/repos/gdb-cobol/gcobol/ctest
> > Python Exception <class 'AttributeError'>: module 'gdb' has no
> > attribute '_handle_missing_debuginfo'
> > [Thread debugging using libthread_db enabled] Using host libthread_db
> > library "/lib/x86_64-linux-gnu/libthread_db.so.1".
> >
> > Temporary breakpoint 1, main (argc=1, argv=0x7fffffffe328) at
> > ctest.c:19
> 
> What is 'GDB' in the commands above?  Is it an alias to the gdb binary
in
> your build folder?  If you're using your locally-built gdb binary from
the
> build folder and not the install folder, please try passing the data-
> directory flag.  Otherwise, a data-directory in a more default location
> takes precedence.
> 
>   $ /<path-to-build-folder>/gdb/gdb -q --data-directory=/<path-to-build-
> folder>/gdb/data-directory
> 
> You can run the "show data-directory" command to check if it is pointing
> to the right folder.
> 
> -Baris
> 
> 
> Intel Deutschland GmbH
> Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
> Tel: +49 89 99 8853-0, www.intel.de
> Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany Doon
> Silva Chairperson of the Supervisory Board: Nicole Lau Registered
Office:
> Munich Commercial Register: Amtsgericht Muenchen HRB 186928


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-10-08 18:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-10-07 22:53 no attribute '_handle_missing_debuginfo' Robert Dubner
2024-10-08  6:13 ` Aktemur, Tankut Baris via Gdb
2024-10-08 18:15   ` Robert Dubner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox