With some versions of MinGW, in a 64-bit optimized build the prototype for _aligned_malloc() isn't found so we get some compiler warnings about using the undeclared function. The root cause is unknown but including malloc.h before windows.h solves the problem. --- src/gallium/state_trackers/wgl/stw_device.c | 5 +++++ 1 file changed, 5 insertions(+)
diff --git a/src/gallium/state_trackers/wgl/stw_device.c b/src/gallium/state_trackers/wgl/stw_device.c index e43f12f..8bdfada 100644 --- a/src/gallium/state_trackers/wgl/stw_device.c +++ b/src/gallium/state_trackers/wgl/stw_device.c @@ -25,6 +25,11 @@ * **************************************************************************/ + +/* Include malloc.h before windows.h to ensure we get a prototype for + * _aligned_malloc() with MinGW. + */ +#include <malloc.h> #include <windows.h> #include "glapi/glapi.h" -- 2.7.4 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev