From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS17314 8.43.84.0/22 X-Spam-Status: No, score=-3.4 required=3.0 tests=AWL,BAYES_00,BODY_8BITS, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 4383A1F8C6 for ; Mon, 16 Aug 2021 17:04:06 +0000 (UTC) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 21A3C395182D for ; Mon, 16 Aug 2021 17:04:05 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 21A3C395182D DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1629133445; bh=E5+m0sHR7PKl3JGZGGENtKfmSh+h3VnG820IcfvqUyI=; h=References:In-Reply-To:Date:Subject:To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=A+cx4tYrxP1UctgfzM0Dq1536kf0LnueeJFh8VUu7gNKAlA3sN2KzYjpj3teDNqOq 0lGmUEh+CRJFE0CzgOTWgTNEOjCeQ4ToZm55suFs/z7d+UGJiK4yt5bFaDyvntV/nq hGnoJTf5B/rWImUKF/4GZRmIBCkxw7GcjfMWYy+k= Received: from mail-yb1-xb33.google.com (mail-yb1-xb33.google.com [IPv6:2607:f8b0:4864:20::b33]) by sourceware.org (Postfix) with ESMTPS id 0F392385742B for ; Mon, 16 Aug 2021 17:03:45 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 0F392385742B Received: by mail-yb1-xb33.google.com with SMTP id l144so8628177ybl.12 for ; Mon, 16 Aug 2021 10:03:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:content-transfer-encoding; bh=E5+m0sHR7PKl3JGZGGENtKfmSh+h3VnG820IcfvqUyI=; b=KjmOAQ3eNW9MfB+pO5k8taJ6tRR7c5MdwnMghEMhPFAFrgv9QHjwAR3qSrqUskgegS zWMRpDz7NyyYtxq50tb860Rcaj77skEmtt92lN5hPqvjuNLMb8XQqwQ1GtIbOVCrrJSn icdGUWCjym+y8A8QVrovb3vWhC+4FOlNHzReh6HIkzGy014mCIbf6CBNi1+W7YLRQFpp 74SgSoZzH4euj+vQZy/ASOBNaJYWFev5ug0cNeY70L5Ig03a/n0IhDdfCHJ0j4s74CDQ yBVPWOdnKPmV05DxaDDmxElCizjv3VWfoG0dSdQdq06VitsWL2m+fYzhKh/aVKnrp8TY cCiA== X-Gm-Message-State: AOAM531NB2RWJynkxdmGfj+VWKf8fnZPVx/noGgK4X3ngezd4RLw0Y4v 8w8/tiCtIj0MRNCHb2k4mjoRoQ1Qvw2msJTmG8pFKniRaas= X-Google-Smtp-Source: ABdhPJxJZB6W7FNsX8lQrNgUXWBg0Vx+RG5gWYwuYTsvesLMELTp9jXXHTzAnJR9fLsFrw5Jg5nNL6FCuOblte5HTGk= X-Received: by 2002:a25:da03:: with SMTP id n3mr21570254ybf.507.1629133424298; Mon, 16 Aug 2021 10:03:44 -0700 (PDT) MIME-Version: 1.0 References: <20210807051211.1018349-1-maskray@google.com> In-Reply-To: <20210807051211.1018349-1-maskray@google.com> Date: Mon, 16 Aug 2021 10:03:32 -0700 Message-ID: Subject: Re: [PATCH] elf: Delete obsoleted DISTINGUISH_LIB_VERSIONS To: libc-alpha@sourceware.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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: , From: =?utf-8?q?F=C4=81ng-ru=C3=AC_S=C3=B2ng_via_Libc-alpha?= Reply-To: =?UTF-8?B?RsSBbmctcnXDrCBTw7JuZw==?= Errors-To: libc-alpha-bounces+e=80x24.org@sourceware.org Sender: "Libc-alpha" Ping On Fri, Aug 6, 2021 at 10:12 PM Fangrui Song wrote: > > and its only definition in i386/dl-librecon.h which essentially > hasn't been updated since 2004. > --- > elf/rtld.c | 4 ---- > sysdeps/unix/sysv/linux/i386/dl-librecon.h | 25 ---------------------- > 2 files changed, 29 deletions(-) > > diff --git a/elf/rtld.c b/elf/rtld.c > index d733359eaf..4196bae703 100644 > --- a/elf/rtld.c > +++ b/elf/rtld.c > @@ -1637,10 +1637,6 @@ dl_main (const ElfW(Phdr) *phdr, > if (main_map->l_ld =3D=3D NULL) > _exit (1); > > - /* We allow here some platform specific code. */ > -#ifdef DISTINGUISH_LIB_VERSIONS > - DISTINGUISH_LIB_VERSIONS; > -#endif > _exit (has_interp ? 0 : 2); > } > > diff --git a/sysdeps/unix/sysv/linux/i386/dl-librecon.h b/sysdeps/unix/sy= sv/linux/i386/dl-librecon.h > index 7efe0679b3..e4d90529b8 100644 > --- a/sysdeps/unix/sysv/linux/i386/dl-librecon.h > +++ b/sysdeps/unix/sysv/linux/i386/dl-librecon.h > @@ -21,31 +21,6 @@ > > #include > > -#define DISTINGUISH_LIB_VERSIONS \ > - do = \ > - { = \ > - /* We have to find out whether the binary is linked against = \ > - libc 5 or glibc. We do this by looking at all the DT_NEEDED = \ > - entries. If one is libc.so.5 this is a libc 5 linked binary. *= / \ > - if (main_map->l_info[DT_NEEDED]) = \ > - { = \ > - /* We have dependencies. */ = \ > - const ElfW(Dyn) *d; = \ > - const char *strtab; = \ > - = \ > - strtab =3D (const char *) D_PTR (main_map, l_info[DT_STRTAB]); = \ > - = \ > - for (d =3D main_map->l_ld; d->d_tag !=3D DT_NULL; ++d) = \ > - if (d->d_tag =3D=3D DT_NEEDED = \ > - && strcmp (strtab + d->d_un.d_val, "libc.so.5") =3D=3D 0)= \ > - break; = \ > - = \ > - /* We print a `5' or `6' depending on the outcome. */ = \ > - _dl_printf (d->d_tag !=3D DT_NULL ? "5\n" : "6\n"); = \ > - } = \ > - } = \ > - while (0) > - > /* Recognizing extra environment variables. */ > #define EXTRA_LD_ENVVARS \ > case 15: = \ > -- > 2.32.0.605.g8dce9f2422-goog > --=20 =E5=AE=8B=E6=96=B9=E7=9D=BF