NetBSD Problem Report #55989
From martin@aprisoft.de Thu Feb 11 09:02:47 2021
Return-Path: <martin@aprisoft.de>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
by mollari.NetBSD.org (Postfix) with ESMTPS id 604031A9217
for <gnats-bugs@gnats.NetBSD.org>; Thu, 11 Feb 2021 09:02:47 +0000 (UTC)
Message-Id: <20210211090238.B463F5CC84B@emmas.aprisoft.de>
Date: Thu, 11 Feb 2021 10:02:38 +0100 (CET)
From: martin@NetBSD.org
Reply-To: martin@NetBSD.org
To: gnats-bugs@NetBSD.org
Subject: archivers/zstd depends on coreutils
X-Send-Pr-Version: 3.95
>Number: 55989
>Category: pkg
>Synopsis: archivers/zstd depends on coreutils
>Confidential: no
>Severity: critical
>Priority: high
>Responsible: pkg-manager
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Feb 11 09:05:00 +0000 2021
>Closed-Date: Thu Feb 11 10:07:54 +0000 2021
>Last-Modified: Thu Feb 11 10:35:02 +0000 2021
>Originator: Martin Husemann
>Release: NetBSD 9.99.80
>Organization:
The NetBSD Foundation, Inc.
>Environment:
System: NetBSD martins.aprisoft.de 9.99.80 NetBSD 9.99.80 (GENERIC) #43: Tue Feb 9 16:41:52 CET 2021 martin@martins.aprisoft.de:/usr/src/sys/arch/amd64/compile/GENERIC amd64
Architecture: x86_64
Machine: amd64
>Description:
If anything on a Posix'ish system depends on coreutils on non-Linux systems,
something is *very* wrong.
Besides this breaks pkg updates big time due to conflicts with idutils.
>How-To-Repeat:
Try to install something depending on archivers/zstd.
>Fix:
n/a
>Release-Note:
>Audit-Trail:
From: Thomas Klausner <wiz@NetBSD.org>
To: NetBSD bugtracking <gnats-bugs@NetBSD.org>
Cc:
Subject: Re: pkg/55989: archivers/zstd depends on coreutils
Date: Thu, 11 Feb 2021 10:06:11 +0100
On Thu, Feb 11, 2021 at 09:05:00AM +0000, martin@NetBSD.org wrote:
> >Number: 55989
> >Category: pkg
> >Synopsis: archivers/zstd depends on coreutils
TOOL_DEPENDS+= coreutils>=0:../../sysutils/coreutils
MAKE_ENV+= HASH=gmd5sum
It's just needed at built time.
I don't see the problem.
Thomas
From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/55989: archivers/zstd depends on coreutils
Date: Thu, 11 Feb 2021 10:16:43 +0100
On Thu, Feb 11, 2021 at 09:10:01AM +0000, Thomas Klausner wrote:
> TOOL_DEPENDS+= coreutils>=0:../../sysutils/coreutils
> MAKE_ENV+= HASH=gmd5sum
>
> It's just needed at built time.
>
> I don't see the problem.
You can not build idutils in the same bulk build any more, or update
pkgs on any build machine where (for whatever reasons) idutils is
already installed without manual interventions.
How about splitting gmd5sum into its own pkg and only depending on that?
Martin
From: nia <nia@NetBSD.org>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/55989: archivers/zstd depends on coreutils
Date: Thu, 11 Feb 2021 09:18:01 +0000
It only needs a GNU-like md5 hashing program.
From the looks of the build system (lib/Makefile), it already
uses just 'md5' on Darwin and OpenBSD, so maybe it can use 'md5'
on NetBSD too.
I'll look into this.
From: "Nia Alarie" <nia@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/55989 CVS commit: pkgsrc/archivers/zstd
Date: Thu, 11 Feb 2021 09:29:50 +0000
Module Name: pkgsrc
Committed By: nia
Date: Thu Feb 11 09:29:50 UTC 2021
Modified Files:
pkgsrc/archivers/zstd: Makefile
Log Message:
zstd: Use base md5 program where possible, avoiding coreutils.
PR pkg/55989
To generate a diff of this commit:
cvs rdiff -u -r1.33 -r1.34 pkgsrc/archivers/zstd/Makefile
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
From: Niclas Rosenvik <nros@NetBSD.org>
To: nia <nia@NetBSD.org>
Cc: gnats-bugs@netbsd.org, pkg-manager@netbsd.org, gnats-admin@netbsd.org,
pkgsrc-bugs@netbsd.org
Subject: Re: pkg/55989: archivers/zstd depends on coreutils
Date: Thu, 11 Feb 2021 10:42:28 +0100
On Thu, 11 Feb 2021 09:20:02 +0000 (UTC)
nia <nia@NetBSD.org> wrote:
> The following reply was made to PR pkg/55989; it has been noted by
> GNATS.
>
> From: nia <nia@NetBSD.org>
> To: gnats-bugs@netbsd.org
> Cc:
> Subject: Re: pkg/55989: archivers/zstd depends on coreutils
> Date: Thu, 11 Feb 2021 09:18:01 +0000
>
> It only needs a GNU-like md5 hashing program.
>
> From the looks of the build system (lib/Makefile), it already
> uses just 'md5' on Darwin and OpenBSD, so maybe it can use 'md5'
> on NetBSD too.
>
> I'll look into this.
>
how about "digest md5". digest is always available in pkgsrc, right??
From: Thomas Klausner <wiz@NetBSD.org>
To: NetBSD bugtracking <gnats-bugs@NetBSD.org>
Cc:
Subject: Re: pkg/55989: archivers/zstd depends on coreutils
Date: Thu, 11 Feb 2021 10:48:45 +0100
On Thu, Feb 11, 2021 at 09:45:01AM +0000, Niclas Rosenvik wrote:
> how about "digest md5". digest is always available in pkgsrc, right??
>
The problem is just the different output format of the different md5 tools.
Thomas
From: nia <nia@NetBSD.org>
To: gnats-bugs@netbsd.org
Cc:
Subject: Re: pkg/55989: archivers/zstd depends on coreutils
Date: Thu, 11 Feb 2021 09:50:05 +0000
On Thu, Feb 11, 2021 at 09:45:01AM +0000, Niclas Rosenvik wrote:
> how about "digest md5". digest is always available in pkgsrc, right??
I suspect the output format needs to match coreutils (hash - filename)
State-Changed-From-To: open->feedback
State-Changed-By: nia@NetBSD.org
State-Changed-When: Thu, 11 Feb 2021 10:04:34 +0000
State-Changed-Why:
State-Changed-From-To: feedback->closed
State-Changed-By: martin@NetBSD.org
State-Changed-When: Thu, 11 Feb 2021 10:07:54 +0000
State-Changed-Why:
perfect - thanks for the quick fix!
From: Niclas Rosenvik <nros@NetBSD.org>
To: nia <nia@NetBSD.org>
Cc: gnats-bugs@netbsd.org, pkg-manager@netbsd.org, gnats-admin@netbsd.org,
pkgsrc-bugs@netbsd.org, Thomas Klausner <wiz@NetBSD.org>
Subject: Re: pkg/55989: archivers/zstd depends on coreutils
Date: Thu, 11 Feb 2021 11:33:55 +0100
On Thu, 11 Feb 2021 09:55:01 +0000 (UTC)
nia <nia@NetBSD.org> wrote:
> I suspect the output format needs to match coreutils (hash -
> filename)
>The problem is just the different output format of the different md5
>tools.
> Thomas
I see your point. But looking at the code where it is used and it looks
like this:
HASH_DIR = conf_$(shell echo $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(LDLIBS) $(ZSTD_FILES) | $(HASH) | cut -f 1 -d " ")
I have tried with:
echo 1 | digest md5 | cut -f 1 -d " "
echo 1 | gmd5sum | cut -f 1 -d " "
and they give the same result. Taking away the cut command gives the
checksum with a dash in the end when using gmd5sum. So I think he
actually wants the output that digest md5 gives. It should
be safe to use it IMHO unless the above command changes in the future.
also
HAVE_HASH :=$(shell echo 1 | $(HASH) > /dev/null && echo 1 || echo 0)
works correctly with digest md5 giving 1
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.