summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2019-09-08 19:44:54 -0700
committerAlan Coopersmith <alan.coopersmith@oracle.com>2019-09-08 19:46:37 -0700
commit603fcbc4a497270877e2039eeb506197bac15d83 (patch)
treeee9fa64b6c07f66452e79983477d95ec470d283b
parent8573dbcee30506f7ad1831247789deaf53a56a10 (diff)
downloadlibepoxy-603fcbc4a497270877e2039eeb506197bac15d83.tar.gz
test: #define __EXTENSIONS__ on Solaris for strdup()
Needed to allow functions outside the original XPG3 standard to be visible in the Solaris headers when _XOPEN_SOURCE is defined and not set to a particular value. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--test/egl_epoxy_api.c4
-rw-r--r--test/egl_has_extension_nocontext.c4
2 files changed, 8 insertions, 0 deletions
diff --git a/test/egl_epoxy_api.c b/test/egl_epoxy_api.c
index a840525..252b535 100644
--- a/test/egl_epoxy_api.c
+++ b/test/egl_epoxy_api.c
@@ -27,7 +27,11 @@
* Tests the Epoxy API using EGL.
*/
+#ifdef __sun
+#define __EXTENSIONS__
+#else
#define _GNU_SOURCE
+#endif
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
diff --git a/test/egl_has_extension_nocontext.c b/test/egl_has_extension_nocontext.c
index a95860a..4fa5f60 100644
--- a/test/egl_has_extension_nocontext.c
+++ b/test/egl_has_extension_nocontext.c
@@ -28,7 +28,11 @@
* no context bound would fail out in dispatch.
*/
+#ifdef __sun
+#define __EXTENSIONS__
+#else
#define _GNU_SOURCE
+#endif
#include <stdio.h>
#include <string.h>
#include <stdlib.h>