From patchwork Mon Mar 13 21:46:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Romain Geissler X-Patchwork-Id: 66328 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id DDD803858C5F for ; Mon, 13 Mar 2023 21:48:37 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DDD803858C5F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1678744117; bh=fuFlfqaHV58WiVRvIue5xO3av10+wX1aQBlMzOXiCBI=; h=Date:To:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=fnzMx0ctZWf5HJ3xZ0tLwn8BzhvW2kOrQTIWT5sjoYpe8u0k3+eLTyb0abq0mLd08 LrMPo9ScEDq1fyaSoztM6EGpA2aZvSRbeDht9KA4q3WTPEF/UdGD+hx6UQHIC3JV2k rqLfTFmUftMU2vHnDSMN+3liZwpzSsPOghYjitNY= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-wm1-x32b.google.com (mail-wm1-x32b.google.com [IPv6:2a00:1450:4864:20::32b]) by sourceware.org (Postfix) with ESMTPS id 75EC63858C5F for ; Mon, 13 Mar 2023 21:48:15 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 75EC63858C5F Received: by mail-wm1-x32b.google.com with SMTP id fm20-20020a05600c0c1400b003ead37e6588so11865909wmb.5 for ; Mon, 13 Mar 2023 14:48:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678744094; h=content-transfer-encoding:subject:from:to:user-agent:mime-version :date:message-id:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=fuFlfqaHV58WiVRvIue5xO3av10+wX1aQBlMzOXiCBI=; b=mhGVDuhxmZ3nqL36M+EEWrbYPsGX9lTlDMeUNszDmiMBUQz3m+cxswMOvkA8dM6TZD By2SUR9xbEuW9GykFL3nNDq/qktlV0AhqnhU21ipW8zHzXhZcUsAh0lC7XzCcHsrdFHX sSn+DqEtc6/VWQGon0iL51L2r4bCAkTJZq1bn8uWKWzwU2+jMsBRtQuI8o3Ucv7L572y lmeDNVIiBkchGtAwUaxzg0ZVXFawe1DmMBVZr/pVZU1YefuG7O/4R4X/sHldG2B/cI5a d9MldlFRctwUo81qv8WI+DjcbY+4odU1S05VnlKeIqRVLJxz6CwWKXL5xb36uG8KLmYT AZKA== X-Gm-Message-State: AO0yUKXlnYqWViAN5UkJHGnu+OWMDDMtYcg705bFm1WPGTxOfksGfCsw yJ7cfwVwE+HtlFGsT6K02D2iFYgw8SDiuA== X-Google-Smtp-Source: AK7set+HG9kcb+1mWEVJUj73m6p/XH0WEuuMkIJJ+/oLGg+EeM2jDk1/DXiqHVfmkdxoXbUUHl5NlQ== X-Received: by 2002:a05:600c:3d89:b0:3eb:42f6:ac55 with SMTP id bi9-20020a05600c3d8900b003eb42f6ac55mr11523323wmb.1.1678744093734; Mon, 13 Mar 2023 14:48:13 -0700 (PDT) Received: from [192.168.1.2] ([82.66.26.140]) by smtp.gmail.com with ESMTPSA id s7-20020a7bc387000000b003e7f1086660sm903295wmj.15.2023.03.13.14.48.13 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 13 Mar 2023 14:48:13 -0700 (PDT) Message-ID: <586cec0c-4497-1029-da8f-e55d1967bba7@gmail.com> Date: Mon, 13 Mar 2023 22:46:57 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.8.0 To: libc-alpha@sourceware.org Subject: [PATCH] Take into account ${sysconfdir} in elf/tst-ldconfig-p.sh X-Spam-Status: No, score=-11.0 required=5.0 tests=BAYES_00, BODY_8BITS, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP 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-Patchwork-Original-From: Romain Geissler via Libc-alpha From: Romain Geissler Reply-To: Romain Geissler Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" Hi, While upgrading to the latest commit of the release branch 2.37, with an exotic glibc installation (I override explicitly the --prefix destination, the test tst-ldconfig-p.sh failed. Here is a small patch to take into account ${sysconfdir} so we don't hardcode it to /etc. PS: I hope the patch will be well formed, I have just setup Thunderbird to write this mail using gmail.com's smtp, unfortunately my employer forbids using anything else than Outlook to send mails, and almost no open source tools support the Exchange protocol... Cheers, Romain commit ad491ee678026eea33e4654da4ce86d4835bd240 Author: Romain Geissler Date:   Mon Mar 13 20:04:48 2023 +0000     Take into account ${sysconfdir} in elf/tst-ldconfig-p.sh. diff --git a/elf/Makefile b/elf/Makefile index 4d0e04b2a20..262fbd1770c 100644 --- a/elf/Makefile +++ b/elf/Makefile @@ -2421,7 +2421,7 @@ $(objpfx)tst-ldconfig-X.out : tst-ldconfig-X.sh $(objpfx)ldconfig      $(evaluate-test)    $(objpfx)tst-ldconfig-p.out : tst-ldconfig-p.sh $(objpfx)ldconfig -    $(SHELL) $< '$(common-objpfx)' '$(test-wrapper-env)' \ +    $(SHELL) $< '$(common-objpfx)' '$(sysconfdir)' '$(test-wrapper-env)' \           '$(run-program-env)' > $@; \      $(evaluate-test)   diff --git a/elf/tst-ldconfig-p.sh b/elf/tst-ldconfig-p.sh index ec937bf4ec0..e966c4d1241 100644 --- a/elf/tst-ldconfig-p.sh +++ b/elf/tst-ldconfig-p.sh @@ -23,11 +23,12 @@  # involves emulation when running ldconfig).    common_objpfx=$1 -test_wrapper_env=$2 -run_program_env=$3 +sysconfdir=$2 +test_wrapper_env=$3 +run_program_env=$4   -if ! test -r /etc/ld.so.cache; then -    echo "warning: /etc/ld.so.cache does not exist, test skipped" +if ! test -r "${sysconfdir}/ld.so.cache"; then +    echo "warning: ${sysconfdir}/ld.so.cache does not exist, test skipped"      exit 77  fi   @@ -46,7 +47,7 @@ errors=0  case $status in      (0)      if head -n 1 "$testout" | \ -        grep -q "libs found in cache \`/etc/ld.so.cache'\$" ; then +        grep -q "libs found in cache \`${sysconfdir}/ld.so.cache'\$" ; then          echo "info: initial string found" >>"$testout"      else          echo "error: initial string not found" >>"$testout"