mesa: Try to unbreak the MSVC build.
authorKenneth Graunke <kenneth@whitecape.org>
Sun, 5 Jun 2016 23:31:11 +0000 (16:31 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Sun, 5 Jun 2016 23:32:08 +0000 (16:32 -0700)
PATH_MAX is apparently not a thing on Windows.  Borrow the hack from
pipe_loader.c to try and make this work.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/arbprogram.c
src/mesa/main/shaderapi.c

index c0786d4230dccd47d2fda13da8c7b45fb3a0279c..911b6fa3960472148311efd18daca655d6459e34 100644 (file)
 #include "program/program.h"
 #include "program/prog_print.h"
 
+#ifdef _MSC_VER
+#include <stdlib.h>
+#define PATH_MAX _MAX_PATH
+#endif
 
 /**
  * Bind a program (make it current)
index eb6b1f5a7e83938d860812054ac8580fee4ce4e9..9d440a0fd03b0f85249f43bba0a5629a1d97c1fc 100644 (file)
 #include "util/hash_table.h"
 #include "util/mesa-sha1.h"
 
+#ifdef _MSC_VER
+#include <stdlib.h>
+#define PATH_MAX _MAX_PATH
+#endif
 
 /**
  * Return mask of GLSL_x flags by examining the MESA_GLSL env var.