Two hours later, and we have an unbundled #CramJam in #Gentoo.

gitweb.gentoo.org/repo/gentoo.

All it took was to:

• add an artificial pkg-config file for bzip2, as bzip2-sys requires it, yet vanilla bzip2 distribution doesn't supply one (github.com/alexcrichton/bzip2-)
• set an environment variable for zstd-sys
• pass appropriate "feature" to activate system lib in blosc2-sys
• patch lz4-sys to support system lib, using a patch that's being ignored by the author for months now (github.com/10XGenomics/lz4-rs/)
• patch libcramjam to allow system library in libdeflate-sys and liblzma-sys (via passing appropriate features)
• patch libcramjam not to force linking to static blosc2 in blosc2-sys
• patch blosc2-sys and libdeflate-sys not to force an exact version of the system library (in the case of blosc2-sys, a broken version, I must add)

So, well, #RustLang and #Cargo are going great. I recall that somebody posted a matching variant of the Scooby Doo meme. Except that I'd modify it a bit, to show that underneath your average`*-sys` crate, there's actually a vendored, old and broken version of a C library. And even if system libraries are actually supported, you have to put a lot of effort to make them work. And on top of that, if they don't, nobody even bothers printing a message and telling you why. It's all guesswork and reading the code.

Now we just have to check and patch all the remaining Rust packages in Gentoo…