https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97183

--- Comment #3 from Jim Wilson <wilson at gcc dot gnu.org> ---
I installed Ubuntu 16.04 on an old laptop so I can directly reproduce the build
failure.

Checking for the zstd version looks like the easier patch.

Checking for specific macros and functions might be better, but what do we do
with the info?  I'm not familiar with zstd or the lto-compress.c code, and it
doesn't look like we can easily change it to not use certain macros/functions
when they don't exist.  Checking for half a dozen macros/functions and
disabling all of the code if one or more is missing seems silly.  Though
looking at this, as Kito pointed out, it appears that
ZSTD_getFrameContentSize() is the most recently added function that we are
using, so maybe we only need to check for that one.  That was added in version
1.3.0.  Or we can check for the 1.3.0 version which seems simpler.  I do know
that version 1.3.3 of zstd works as this is what Ubuntu 18.04 has.  I haven't
tried the versions 1.3.[012].

Reply via email to