From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32190 invoked by alias); 13 May 2009 02:56:53 -0000 Received: (qmail 32181 invoked by uid 22791); 13 May 2009 02:56:52 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org Received: from ti-out-0910.google.com (HELO ti-out-0910.google.com) (209.85.142.190) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 13 May 2009 02:56:45 +0000 Received: by ti-out-0910.google.com with SMTP id a1so27190tib.12 for ; Tue, 12 May 2009 19:56:42 -0700 (PDT) MIME-Version: 1.0 Received: by 10.110.69.5 with SMTP id r5mr26495tia.22.1242183401998; Tue, 12 May 2009 19:56:41 -0700 (PDT) In-Reply-To: <8ac60eac0905120942ycd19a5fha5d0fe89cb9865ea@mail.gmail.com> References: <8ac60eac0904201019g7ba8056bx5e84e6bfdf5935d8@mail.gmail.com> <8ac60eac0904301618j61051e9du38b34afbc7ed64a3@mail.gmail.com> <8ac60eac0904301719w33175de2w8d1d0fd80bf0feb4@mail.gmail.com> <200905111412.59493.pedro@codesourcery.com> <8ac60eac0905111108g26096302lb902cd414b5a6790@mail.gmail.com> <8ac60eac0905120942ycd19a5fha5d0fe89cb9865ea@mail.gmail.com> Date: Wed, 13 May 2009 02:56:00 -0000 Message-ID: Subject: Re: [patch][rfc] Allow GDB to search for the right libthread_db.so.1 From: Hui Zhu To: Paul Pluzhnikov Cc: Pedro Alves , gdb-patches@sourceware.org, Joel Brobecker , tromey@redhat.com, Thiago Jung Bauermann , Eli Zaretskii , Daniel Jacobowitz Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2009-05/txt/msg00258.txt.bz2 On Wed, May 13, 2009 at 00:42, Paul Pluzhnikov wro= te: > On Tue, May 12, 2009 at 12:16 AM, Hui Zhu wrote: > >> 1. =A0Could you please add a debug interface like "set debug >> linux-thread 1" to let linux-thread-db.c output some debug message? > > This will already happen with 'set verbose on': > > =A0try_thread_db_load_1 (void *handle) > =A0... > =A0 =A0 =A0 =A0if (info_verbose) > =A0 =A0 =A0 =A0 =A0printf_unfiltered (_("td_ta_new failed: %s\n"), > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 thread_db_err_str= (err)); > > =A0try_thread_db_load (const char *library) > =A0... > =A0 =A0if (info_verbose) > =A0 =A0 =A0printf_unfiltered (_("Trying host libthread_db library: %s.\n"= ), > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 library); > > etc, etc. > > I don't think a separate "debug linux-thread" is really necessary, > though it is trivial to add if others "vote" for it. This part is OK with me. > >> 2. =A0I still peddle my idea: let libthread-db-search-path can support >> single file. =A0And a make a patch follow your patch. Wish you like it. >> :) > > I don't object to the idea per se; but I believe it really solves > a non-existant problem, and makes documentation more confusing. > In a linux that use readonly filesystem and don't config tmpfs with kernel, user will more like this function than regenerate the image and write it to flash. >> --- >> =A0linux-thread-db.c | =A0 13 +++++++++++-- >> =A01 file changed, 11 insertions(+), 2 deletions(-) >> >> --- a/linux-thread-db.c >> +++ b/linux-thread-db.c >> @@ -642,6 +642,7 @@ thread_db_load_search (void) > > Unrelated question: how did you generate above diff? > Do you maintain a separate git mirror? > I use quilt, a very powerful patch manage tools. Thanks, Hui