[Mesa-dev] [PATCH] glsl: Add strings.h on non-MSC platforms
Alexander von Gluck IV
kallisti5 at unixzen.com
Wed Aug 27 13:55:37 PDT 2014
* IEEE Std 1003.1-2001 placed strcasecmp() in strings.h.
* ISO C99 doesn't mention strcase* in string.h
* On all platforms I could find, strcasecmp is in strings.h and string.h
as a compatibility layer for software written pre-2001 POSIX
* Technically strcasecmp should be only in strings.h and the man
pages back this up.
---
src/glsl/glsl_parser.yy | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/src/glsl/glsl_parser.yy b/src/glsl/glsl_parser.yy
index 2f30b85..6160e26 100644
--- a/src/glsl/glsl_parser.yy
+++ b/src/glsl/glsl_parser.yy
@@ -24,6 +24,9 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#ifndef _MSC_VER
+#include <strings.h>
+#endif
#include <assert.h>
#include "ast.h"
--
1.7.1
More information about the mesa-dev
mailing list