From patchwork Wed Jul 31 21:34:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 33883 Received: (qmail 17908 invoked by alias); 31 Jul 2019 21:34:22 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 17898 invoked by uid 89); 31 Jul 2019 21:34:22 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-15.1 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.1 spammy=H*i:sk:8749987, H*f:sk:8749987 X-HELO: relay1.mentorg.com Date: Wed, 31 Jul 2019 21:34:15 +0000 From: Joseph Myers To: Carlos O'Donell CC: DJ Delorie , Subject: Re: testroot.pristine creation falls over copying dynamic linker In-Reply-To: <8749987e-2f06-9362-0afc-d2d9cda4cda5@redhat.com> Message-ID: References: <8749987e-2f06-9362-0afc-d2d9cda4cda5@redhat.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 On Wed, 31 Jul 2019, Carlos O'Donell wrote: > > > Maybe we need a filter like this? It just prefers the RHS path if there > > > is on, else uses the first path available: > > > > > > - | grep / | sed 's/^[^/]*//' | sed 's/ .*//'` ;\ > > > + | grep / | sed 's@.*=> /@/@' | sed 's/^[^/]*//' | sed 's/ > > > .*//'` ;\ > > > > I can confirm that doing that (for both Makefile lines with such a sed > > command) allows the MIPS tests to run in cases where they previously fell > > over because the path on the LHS does not exist in the root filesystem. > > Shall we get this fix in for 2.30? I think it's desirable for 2.30 (to avoid problems testing for an ABI on a system without that ABI's dynamic linker installed in the root filesystem under its canonical name), but I haven't really thought about what cases ought to be tested to confirm the change is safe. For reference, this is the implied patch of DJ's that I tested. diff --git a/Makefile b/Makefile index ac1125853b..c91e151042 100644 --- a/Makefile +++ b/Makefile @@ -385,7 +385,7 @@ ifeq ($(run-built-tests),yes) for dso in `$(test-wrapper-env) LD_TRACE_LOADED_OBJECTS=1 \ $(rtld-prefix) \ $(objpfx)testroot.pristine/bin/sh \ - | grep / | sed 's/^[^/]*//' | sed 's/ .*//'` ;\ + | grep / | sed 's@.*=> /@/@' | sed 's/^[^/]*//' | sed 's/ .*//'` ;\ do \ test -d `dirname $(objpfx)testroot.pristine$$dso` || \ mkdir -p `dirname $(objpfx)testroot.pristine$$dso` ;\ @@ -394,7 +394,7 @@ ifeq ($(run-built-tests),yes) for dso in `$(test-wrapper-env) LD_TRACE_LOADED_OBJECTS=1 \ $(rtld-prefix) \ $(objpfx)support/$(LINKS_DSO_PROGRAM) \ - | grep / | sed 's/^[^/]*//' | sed 's/ .*//'` ;\ + | grep / | sed 's@.*=> /@/@' | sed 's/^[^/]*//' | sed 's/ .*//'` ;\ do \ test -d `dirname $(objpfx)testroot.pristine$$dso` || \ mkdir -p `dirname $(objpfx)testroot.pristine$$dso` ;\