@@ -136,6 +136,7 @@ case "$target" in
;;
*linux*)
starpu_linux=yes
+ AC_DEFINE(STARPU_LINUX_SYS, 1, [Define to 1 on Linux])
esac
AM_CONDITIONAL([STARPU_HAVE_WINDOWS], [test "x$starpu_windows" = "xyes"])
@@ -46,8 +46,13 @@ starpu_unistd_global_alloc (struct starpu_unistd_global_obj * obj, void *base, s
strcpy(baseCpy, (char *) base);
strcat(baseCpy,template);
-
+#ifdef STARPU_LINUX_SYS
id = mkostemp(baseCpy, obj->flags);
+#else
+ STARPU_ASSERT(obj->flags == O_RDWR);
+ id = mkstemp(baseCpy);
+#endif
+
/* fail */
if (id < 0)
{