Bundled libarchive (which is used by pkg) doesn't have zstd built-in?
Autumn Jolitz
autumn.jolitz at gmail.com
Thu Apr 9 19:24:45 PDT 2026
I tried to create a `tzst` format pkg but it failed with: "pkg: zstd is supported, but not builtin."
This is on a 6.5 system running latest master and pkg 2.2.0.
This could be a problem as `tzst` is the default pkg format (https://lists.freebsd.org/archives/freebsd-ports/2025-January/007185.html) — a bare `pkg create …` will complain about zstd despite /usr/local/etc/pkg.conf having all defaults.
Since pkg farms out archive unpacking to libarchive:
$ ldd /usr/local/sbin/pkg | grep libarchive
libarchive.so.5 => /usr/lib/libarchive.so.5 (0x800bda000)
Taking a look at ``/usr/src/contrib/libarchive/README.DRAGONFLY``, I notice it has
Configured with
===============
./configure --without-nettle --with-openssl --without-xml2 --without-zstd \
--without-lz4 --without-lzo2 \
ac_cv_lib_md_MD5Init=no ac_cv_lzma_has_mt=no
Hm, yeah that would do it. If we’re using pkg 2.0.2+, the bundled libarchive will likely need to have zstd support added if pkg will be able to make use of tzst.
I notice this cause I build binary packages locally using pkg create and pkg repo.
`pkg repo` certainly isn’t working with missing zstd support and doesn’t seem to respect pkg.conf ``COMPRESSION_FORMAT = txz`` at all. 😕
Autumn
More information about the Users
mailing list