summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2016-04-27 17:17:28 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2016-04-27 17:17:28 +0000
commitda7c00aac2f5abc8223cf6be143baf7a8ec3960a (patch)
treed241d9bed2adb29dae3f66036488c8f6f073b048
parentaa9cfcfc494242f14098ee28a18209a154c7d58c (diff)
downloadskalibs-da7c00aac2f5abc8223cf6be143baf7a8ec3960a.tar.xz
Help Solaris finds its own futimens() in its own ass
-rw-r--r--src/libstddjb/touch.c1
-rw-r--r--src/sysdeps/tryfutimens.c8
2 files changed, 6 insertions, 3 deletions
diff --git a/src/libstddjb/touch.c b/src/libstddjb/touch.c
index 57e0d0d..d85c483 100644
--- a/src/libstddjb/touch.c
+++ b/src/libstddjb/touch.c
@@ -4,6 +4,7 @@
#ifdef SKALIBS_HASFUTIMENS
+#include <skalibs/nonposix.h>
#include <time.h>
#include <sys/stat.h>
#include <skalibs/djbunix.h>
diff --git a/src/sysdeps/tryfutimens.c b/src/sysdeps/tryfutimens.c
index 809aaa5..0c4b2af 100644
--- a/src/sysdeps/tryfutimens.c
+++ b/src/sysdeps/tryfutimens.c
@@ -1,8 +1,10 @@
/* ISC license. */
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <time.h>
+#undef _POSIX_C_SOURCE
+#undef _XOPEN_SOURCE
+#ifndef __EXTENSIONS__
+#define __EXTENSIONS__
+#endif
int main (void)
{