#358 Build fails on MinGW32 - missing SIZE_MAX / SIZE_T_MAX

1.3.0
closed-out-of-date
Erik
libFLAC (57)
5
2014-03-21
2009-10-27
Volker Grabsch
No

When cross-compiling for MinGW32, the build fails at the "#error" in flac-1.2.1/include/share/alloc.h:

#ifndef SIZE_MAX
# ifndef SIZE_T_MAX
# ifdef _MSC_VER
# define SIZE_T_MAX UINT_MAX
# else
# error
# endif
# endif
# define SIZE_MAX SIZE_T_MAX
#endif

The workaround for "_MSC_VER" is perfectly acceptable for MinGW32, too. So the #ifdef just needs to become more flexible.

The attached patch solves the problem.

Discussion

  • Volker Grabsch
    Volker Grabsch
    2009-10-27

    Patch that solves the problem

     
  • Erik
    Erik
    2014-03-21

    Believe this to be fixed in flac 1.3.0. Closing.

     
  • Erik
    Erik
    2014-03-21

    • status: open --> closed-out-of-date
    • assigned_to: Erik
    • Group: --> 1.3.0