public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug server/14748] New: Failed to check the existence of libthread_db
@ 2012-10-21 15:46 brian.wang.0721 at gmail dot com
  2015-09-26  5:01 ` [Bug server/14748] " xdje42 at gmail dot com
  2015-09-26  5:02 ` xdje42 at gmail dot com
  0 siblings, 2 replies; 3+ messages in thread
From: brian.wang.0721 at gmail dot com @ 2012-10-21 15:46 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=14748

             Bug #: 14748
           Summary: Failed to check the existence of libthread_db
           Product: gdb
           Version: 7.4
            Status: NEW
          Severity: normal
          Priority: P2
         Component: server
        AssignedTo: unassigned@sourceware.org
        ReportedBy: brian.wang.0721@gmail.com
    Classification: Unclassified


Hello all,

I tried cross compiling gdbserver with a musl (non-glibc) ARM toolchain, which
does not provide libthread_db.  The compilation failed with the following
messages, mostly regarding libthread_db.  Commenting out the complained parts
will make it compile and the resulting gdbserver runs fine on the ARM target,
at least for my single thread program.  Is it possible to detect the existence
of libthread_db and make it optional so that the majority part of gdbserver
would work without libthread_db?

Thanks in advance.
------------------------

thread-db.c: In function ‘find_one_thread’:
thread-db.c:292:7: error: format ‘%ld’ expects argument of type ‘long
int’, but argument 3 has type ‘thread_t’ [-Werror=format]
thread-db.c:315:6: error: ‘struct lwp_info’ has no member named ‘th’
thread-db.c: In function ‘attach_thread’:
thread-db.c:329:7: error: format ‘%ld’ expects argument of type ‘long
int’, but argument 3 has type ‘thread_t’ [-Werror=format]
thread-db.c:335:9: error: format ‘%ld’ expects argument of type ‘long
int’, but argument 2 has type ‘thread_t’ [-Werror=format]
thread-db.c:340:6: error: ‘struct lwp_info’ has no member named ‘th’
thread-db.c: In function ‘thread_db_get_tls_address’:
thread-db.c:513:47: error: ‘struct lwp_info’ has no member named ‘th’
thread-db.c: In function ‘dladdr_to_soname’:
thread-db.c:652:3: error: passing argument 1 of ‘dladdr’ discards
‘const’ qualifier from pointer target type [-Werror]
In file included from thread-db.c:33:0:
/opt/cross/arm-linux-musleabi/lib/gcc/arm-linux-musleabi/4.7.1/../../../../arm-linux-musleabi/include/dlfcn.h:30:5:
note: expected ‘void *’ but argument is of type ‘const void *’
thread-db.c: In function ‘try_thread_db_load_from_sdir’:
thread-db.c:708:30: error: ‘LIBTHREAD_DB_SO’ undeclared (first use in
this function)
thread-db.c:708:30: note: each undeclared identifier is reported only
once for each function it appears in
thread-db.c: In function ‘try_thread_db_load_from_dir’:
thread-db.c:719:29: error: ‘LIBTHREAD_DB_SO’ undeclared (first use in
this function)
thread-db.c: In function ‘thread_db_load_search’:
thread-db.c:748:41: error: ‘LIBTHREAD_DB_SEARCH_PATH’ undeclared
(first use in this function)
thread-db.c: In function ‘thread_db_handle_monitor_command’:
thread-db.c:971:7: error: ‘LIBTHREAD_DB_SEARCH_PATH’ undeclared (first
use in this function)
thread-db.c: In function ‘try_thread_db_load_from_sdir’:
thread-db.c:709:1: error: control reaches end of non-void function
[-Werror=return-type]
cc1: all warnings being treated as errors

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


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

* [Bug server/14748] Failed to check the existence of libthread_db
  2012-10-21 15:46 [Bug server/14748] New: Failed to check the existence of libthread_db brian.wang.0721 at gmail dot com
@ 2015-09-26  5:01 ` xdje42 at gmail dot com
  2015-09-26  5:02 ` xdje42 at gmail dot com
  1 sibling, 0 replies; 3+ messages in thread
From: xdje42 at gmail dot com @ 2015-09-26  5:01 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=14748

Doug Evans <xdje42 at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |xdje42 at gmail dot com

--- Comment #1 from Doug Evans <xdje42 at gmail dot com> ---
This should no longer be an issue.
gdb/gdbserver support (trying to) statically link or dlopen libthread_db.

There's a plethora of other issues, but the build succeeds.
[with a few minor patches to gdb, not libthread_db related]

-- 
You are receiving this mail because:
You are on the CC list for the bug.


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

* [Bug server/14748] Failed to check the existence of libthread_db
  2012-10-21 15:46 [Bug server/14748] New: Failed to check the existence of libthread_db brian.wang.0721 at gmail dot com
  2015-09-26  5:01 ` [Bug server/14748] " xdje42 at gmail dot com
@ 2015-09-26  5:02 ` xdje42 at gmail dot com
  1 sibling, 0 replies; 3+ messages in thread
From: xdje42 at gmail dot com @ 2015-09-26  5:02 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=14748

Doug Evans <xdje42 at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #2 from Doug Evans <xdje42 at gmail dot com> ---
feel free to reopen if there's still an issue

-- 
You are receiving this mail because:
You are on the CC list for the bug.


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

end of thread, other threads:[~2015-09-26  5:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-21 15:46 [Bug server/14748] New: Failed to check the existence of libthread_db brian.wang.0721 at gmail dot com
2015-09-26  5:01 ` [Bug server/14748] " xdje42 at gmail dot com
2015-09-26  5:02 ` xdje42 at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).