From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 98F9E38485B6 for ; Tue, 7 Jun 2022 22:56:22 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 98F9E38485B6 Received: from mail-qk1-f197.google.com (mail-qk1-f197.google.com [209.85.222.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-18-JI3DQOIKNF6VzWoJFQwyrg-1; Tue, 07 Jun 2022 18:56:21 -0400 X-MC-Unique: JI3DQOIKNF6VzWoJFQwyrg-1 Received: by mail-qk1-f197.google.com with SMTP id bs39-20020a05620a472700b006a6772a6cb3so13338779qkb.14 for ; Tue, 07 Jun 2022 15:56:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:organization:in-reply-to :content-transfer-encoding; bh=P5N887tc0KJNuElreq9OWDLaCrszseEQGyRHN+JJh/E=; b=MAU37As5iGdN9alOg2n6z//nm5ZBMt7VvxifkHphIU/FxeaocKW86D/y1iyAs9Bhil j0OxEdQpPMCFpuMCLIAZfcurQu28s3i+ribNAlKNkHYuoy1Jvi7QW8N+G2ruotc0Ov4E NlZfAjdPtyNSxTSow7I1/MEDveWUo10Y0LAZw94jEGkzDXl+/n9djKSINYKBiEvFoI4G 2PErJm3HWk4Fz7Nwt12H4hIFOO8eVgNMzgsv33FbhwXGfhnGjU0k33W0q3k5h1QaPEXa b2fGj5e9XIBWFI+TfkOwdcv89EDbNlb9n0QLyKlsEwOiYt9GQwAVvCCSwWHkioRwjKWm hDww== X-Gm-Message-State: AOAM532OpVohPSIyAEJA9BpPgkODDxXImEGzSMmZH9zcewUinnT8yzX7 T/r7ibcHk8wCv72siaGL04D4fXylElGWLRKB6tF3R0+fsKITOetTvhoM1mNXXj0tQxk61Oniwpa N+ZPlkaf5lKWszU4x5ut+ X-Received: by 2002:a37:5e87:0:b0:6a6:b45d:8e48 with SMTP id s129-20020a375e87000000b006a6b45d8e48mr10752413qkb.730.1654642580354; Tue, 07 Jun 2022 15:56:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzOn9xKEsU+sTuCWq0PD1OSkkAcpR/D1jkl2YaU13wwwm237rOCDcm4WHP5K7hg4U0qC2yz/Q== X-Received: by 2002:a37:5e87:0:b0:6a6:b45d:8e48 with SMTP id s129-20020a375e87000000b006a6b45d8e48mr10752397qkb.730.1654642580079; Tue, 07 Jun 2022 15:56:20 -0700 (PDT) Received: from [192.168.0.241] (135-23-175-80.cpe.pppoe.ca. [135.23.175.80]) by smtp.gmail.com with ESMTPSA id m3-20020a375803000000b006a3696c4739sm14737022qkb.19.2022.06.07.15.56.17 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 07 Jun 2022 15:56:18 -0700 (PDT) Message-ID: <207e5e80-3b82-5ebd-9a7a-f2b8739f315f@redhat.com> Date: Tue, 7 Jun 2022 18:56:17 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH v2] nptl_db: disable DT_RELR on libthread_db.so To: "Paul E. Murphy" , libc-alpha@sourceware.org References: <20220603145037.126797-1-murphyp@linux.ibm.com> From: Carlos O'Donell Organization: Red Hat In-Reply-To: <20220603145037.126797-1-murphyp@linux.ibm.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-17.2 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Jun 2022 22:56:24 -0000 On 6/3/22 10:50, Paul E. Murphy via Libc-alpha wrote: > Continued from > > https://sourceware.org/pipermail/libc-alpha/2022-June/139357.html LGTM. Reviewed-by: Carlos O'Donell > ---8<--- > > Some nptl tests inadvertently use the host's gdb to verify > libthread_db.so, which is loaded with the host's runtime. This causes > a couple of test failures when the host glibc does not support DT_RELR. > > The not correct, but simple, workaround is to build without DT_RELR > as this library is otherwise likely to load on glibc 2.17 and newer > today. > > This allows tst-pthread-gdb-attach{,-static} to continue working > when testing on a gdb loaded with an older glibc. OK. > > This avoids a failure in tst-pthread-gdb-attach similar to: > > Trying host libthread_db library: .../build/glibc/nptl_db/libthread_db.so.1. > dlopen failed: /lib64/libc.so.6: version `GLIBC_ABI_DT_RELR' not found (required by .../build/glibc/nptl_db/libthread_db.so.1). OK. > --- > nptl_db/Makefile | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/nptl_db/Makefile b/nptl_db/Makefile > index ed923a41e5..2360e53c88 100644 > --- a/nptl_db/Makefile > +++ b/nptl_db/Makefile > @@ -49,6 +49,12 @@ libthread_db-inhibit-o = $(filter-out .os,$(object-suffixes)) > # The ps_* callback functions are not defined. > libthread_db.so-no-z-defs = yes > > +# This is a hack. This is not the correct solution. When this glibc > +# is tested, the gdb used could be loaded by the host glibc, which > +# may not support DT_RELR, and report a failure instead of unsupported. > +# For now, build this without DT_RELR support to avoid this situation. OK. *Great* comment :-) > +libthread_db.so-no-dt-relr = yes > + > tests-special += $(objpfx)db-symbols.out > > include ../Rules -- Cheers, Carlos.