Re: [PATCH v3] kheaders: make it possible to override TAR

From: Michał Górny
Date: Sun Jul 20 2025 - 15:08:36 EST


On Sat, 2025-07-19 at 16:10 -0400, Nathan Chancellor wrote:
> On Sat, Jul 19, 2025 at 04:24:05PM +0100, Sam James wrote:
> > From: Michał Górny <mgorny@xxxxxxxxxx>
> >
> > Commit 86cdd2fdc4e39c388d39c7ba2396d1a9dfd66226 ("kheaders: make headers
> > archive reproducible") introduced a number of options specific to GNU
> > tar to the `tar` invocation in `gen_kheaders.sh` script. This causes
> > the script to fail to work on systems where `tar` is not GNU tar. This
> > can occur e.g. on recent Gentoo Linux installations that support using
> > bsdtar from libarchive instead.
> >
> > Add a `TAR` make variable to make it possible to override the tar
> > executable used, e.g. by specifying:
> >
> > make TAR=gtar
> >
> > Link: https://bugs.gentoo.org/884061
> > Reported-by: Sam James <sam@xxxxxxxxxx>
> > Tested-by: Sam James <sam@xxxxxxxxxx>
> > Co-developed-by: Masahiro Yamada <masahiroy@xxxxxxxxxx>
> > Signed-off-by: Michał Górny <mgorny@xxxxxxxxxx>
> > Signed-off-by: Sam James <sam@xxxxxxxxxx>
> > ---
>
> Reviewed-by: Nathan Chancellor <nathan@xxxxxxxxxx>
>
> I assume that other places that call tar within the build process are
> not problematic because they do not use GNU specific options, such as
> scripts/Makefile.package and scripts/package/install-extmod-build, or
> maybe that people just have not tried building those packages with
> bsdtar?

Precisely. We focused on the one place which actually breaks our build,
to avoid touching too many subsystems simultaneously. If this is
desirable, I can look into replacing the other instances.


--
Best regards,
Michał Górny

Attachment: signature.asc
Description: This is a digitally signed message part