Bruno Haible <[email protected]> writes:

> Collin Funk wrote:
>> I pushed the attached patch to fix it.
>
> Thanks. "make distcheck" now succeeds. But a build with sanitizers fails
> due to this test:

[...]

> ++ cmd_exe coreutils
> +++ command -v coreutils
> ++ local found_cmd=/usr/bin/coreutils
> ++++ command -v env
> +++ dirname 
> /home/runner/work/ci-check/ci-check/coreutils-2026-10-19/build/./src/env
> ++ local 
> found_dir=/home/runner/work/ci-check/ci-check/coreutils-2026-10-19/build/./src
> ++ local 
> built_cmd=/home/runner/work/ci-check/ci-check/coreutils-2026-10-19/build/src/coreutils
> ++ test -x /usr/bin/coreutils
> ++ printf '%s\n' /usr/bin/coreutils
> + single_binary=/usr/bin/coreutils
> + test -n /usr/bin/coreutils
> + /usr/bin/coreutils --coreutils-prog=cat /dev/null

Sigh... I spent an unfortunate amount of time confused about why this
did not fail for me before I noticed this.

Unfortunely, GitHub Actions uses an distribution which I will leave
unnamed, whos leadership has decided their primary purpose is to replace
GNU coreutils over the past year and a half.

Anyways, thanks for the report, fixed with the attached patch.

Collin


>From 54e193810582ba4cb2f7216b7aa91d3b4bd84e49 Mon Sep 17 00:00:00 2001
Message-ID: <54e193810582ba4cb2f7216b7aa91d3b4bd84e49.1792467738.git.collin.fu...@gmail.com>
From: Collin Funk <[email protected]>
Date: Mon, 19 Oct 2026 19:49:26 -0700
Subject: [PATCH] tests: avoid a false failure on some systems

* tests/misc/proc-self-comm.sh: Make sure the 'coreutils' program is the
one we just built.
Reported by Bruno Haible.
---
 tests/misc/proc-self-comm.sh | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/tests/misc/proc-self-comm.sh b/tests/misc/proc-self-comm.sh
index 31bd333ac..6d1d58aee 100755
--- a/tests/misc/proc-self-comm.sh
+++ b/tests/misc/proc-self-comm.sh
@@ -24,9 +24,11 @@ test -f /proc/self/comm || skip_ '/proc/self/comm is required'
 # Set up variables to execute 'cat' from its absolute path and,
 # if available, through the single binary.
 abs_cat=$(cmd_exe cat) || framework_failure_
-single_binary=$(cmd_exe coreutils)
+single_binary="$abs_top_builddir/src/coreutils$EXEEXT"
 
-if test -n "$single_binary" &&
+if ! test -x "$single_binary"; then
+  single_binary=
+elif test -n "$single_binary" &&
     ! "$single_binary" --coreutils-prog=cat /dev/null 2>err; then
   grep "^coreutils: unknown program 'cat'$" err || framework_failure_
   single_binary=
-- 
2.56.0

Reply via email to