[flac-dev] libFLAC with Android NDK: use of undeclared identifier 'SIZE_MAX'

Steve stevefung at chromium.org
Tue May 2 22:38:03 UTC 2017

Hi flac-dev,

When we try to build libFLAC v1.3.1 using the Android NDK, we currently are
getting an error in a couple files:

../../third_party/flac/src/libFLAC/md5.c:498:25: error: use of undeclared
> identifier 'SIZE_MAX'
> if ((size_t)channels > SIZE_MAX / (size_t)bytes_per_sample)

I filed a bug for it on the sourceforge bug tracker:

This is fixed (in all NDK versions) by including limits.h.  I've attached a
simple patch that fixes the Android NDK build.

Please let me know if theres any other process involved in getting this
patch upstreamed.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xiph.org/pipermail/flac-dev/attachments/20170502/b51b21d2/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: flac_android.diff
Type: application/octet-stream
Size: 605 bytes
Desc: not available
URL: <http://lists.xiph.org/pipermail/flac-dev/attachments/20170502/b51b21d2/attachment.obj>

More information about the flac-dev mailing list