From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24046 invoked by alias); 31 Aug 2005 17:30:16 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 23780 invoked by uid 22791); 31 Aug 2005 17:30:08 -0000 Received: from master.ies.hu (HELO master.ies.hu) (195.70.37.202) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Wed, 31 Aug 2005 17:30:08 +0000 Received: from localhost (master [127.0.0.1]) by master.ies.hu (Postfix) with ESMTP id E8A2C1B634 for ; Wed, 31 Aug 2005 19:35:28 +0200 (CEST) Received: from master.ies.hu ([127.0.0.1]) by localhost (master [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 11327-08 for ; Wed, 31 Aug 2005 19:35:28 +0200 (CEST) Received: from master.ies.hu (master [127.0.0.1]) by master.ies.hu (Postfix) with ESMTP id 2D0121B638 for ; Wed, 31 Aug 2005 19:35:28 +0200 (CEST) Received: from bp.ies.hu (server.ies-hungary.intra [192.168.2.1]) by master.ies.hu (Postfix) with ESMTP id 14CA41B634 for ; Wed, 31 Aug 2005 19:35:28 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by bp.ies.hu (Postfix) with ESMTP id 3EBB2175E6 for ; Wed, 31 Aug 2005 19:30:05 +0200 (CEST) Date: Wed, 31 Aug 2005 19:04:00 -0000 From: SZOKOVACS Robert X-X-Sender: To: Subject: meaningful error message in gdbserver Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SW-Source: 2005-08/txt/msg00265.txt.bz2 Hi, I had a long day fighting with remote debugging, until I found out that my libpthread and libthread_db versions didn't match. So I created the patch below that makes gdbserver more verbose when failing, maybe it can save some time for somebody in the future. br Szo ========================================================================== diff -ruw gdb-6.3.50.20050831-orig/gdb/gdbserver/thread-db.c gdb-6.3.50.20050831/gdb/gdbserver/thread-db.c --- gdb-6.3.50.20050831-orig/gdb/gdbserver/thread-db.c 2005-08-31 18:12:56.000000000 +0200 +++ gdb-6.3.50.20050831/gdb/gdbserver/thread-db.c 2005-08-31 18:27:18.000000000 +0200 @@ -351,6 +351,10 @@ /* No thread library was detected. */ return 0; + case TD_VERSION: + warning ("error initializing thread_db library:\nVersion of libpthread and libthread_db mismatch."); + return 0; + case TD_OK: /* The thread library was detected. */