[build2] Build error on openbsd 7.1

Boris Kolpackov boris at codesynthesis.com
Tue May 24 13:53:14 UTC 2022

Dirty Dawn via users <users at build2.org> writes:

> The error in my opinion is related to the --version switch not
> supported in openbsd tar version.

I don't think it's that (I don't see us calling tar with --version)
anywhere in the codebase.

I believe the culprit is `--format ustar` which we pass in the build
system when creating distributions. This option is not recognized by
OpenBSD tar. I did a bit of research and ustar (aka POSIX) seems to
be the default, though this is not explicitly stated/guaranteed
anywhere. We could just assume that and omit the option or we could
switch to pax which has `-x ustar`.

There is another problem with OpenBSD tar: in bpkg we need the
ability to extract just one file and pipe it to stdout. With GNU
and FreeBSD tar this can be achieved with -O|--to-stdout. But there
doesn't seem to be anything like this in OpenBSD tar (or pax). Not
sure what our options are here other than requiring GNU tar (which
would be unfortunate).

If you can do some research on these issues (maybe ask on OpenBSD
mailing list) and provide some guidance, that would be great.

More information about the users mailing list