xserver: Branch 'master' - 2 commits
Adam Jackson
ajax at kemper.freedesktop.org
Fri May 12 14:24:23 UTC 2017
hw/xfree86/os-support/xf86_OSlib.h | 6 ------
hw/xfree86/parser/scan.c | 7 -------
include/meson.build | 3 +++
os/osdep.h | 7 -------
os/utils.c | 12 ------------
5 files changed, 3 insertions(+), 32 deletions(-)
New commits:
commit 49c742557457ff9200a10f32daadfcea50d4911c
Author: Adam Jackson <ajax at redhat.com>
Date: Thu May 11 17:17:55 2017 -0400
meson: Fix CLOCK_MONOTONIC test
C99 isn't enough on its own to get POSIX feature sets defined.
Signed-off-by: Adam Jackson <ajax at redhat.com>
Reviewed-by: Julien Cristau <jcristau at debian.org>
Tested-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
diff --git a/include/meson.build b/include/meson.build
index 358e04976..2f8882803 100644
--- a/include/meson.build
+++ b/include/meson.build
@@ -4,7 +4,10 @@ dri_dep = dependency('dri', required: build_dri2 or build_dri3)
conf_data = configuration_data()
conf_data.set('_DIX_CONFIG_H_', '1')
+
+
conf_data.set('MONOTONIC_CLOCK', cc.compiles('''
+ #define _POSIX_C_SOURCE 200112L
#include <time.h>
#include <unistd.h>
#ifndef CLOCK_MONOTONIC
commit 152375f4e4f1ee4833129802730b36af8d0f7e1a
Author: Adam Jackson <ajax at redhat.com>
Date: Thu May 11 17:17:54 2017 -0400
os, xfree86: Stop being so weird about <limits.h>
Whatever problem this is trying to fix, we don't care. Just include the
thing and stop worrying about whether _POSIX_SOURCE is defined.
Signed-off-by: Adam Jackson <ajax at redhat.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith at oracle.com>
Reviewed-by: Julien Cristau <jcristau at debian.org>
Tested-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
diff --git a/hw/xfree86/os-support/xf86_OSlib.h b/hw/xfree86/os-support/xf86_OSlib.h
index 5d78c66e3..159c8064c 100644
--- a/hw/xfree86/os-support/xf86_OSlib.h
+++ b/hw/xfree86/os-support/xf86_OSlib.h
@@ -337,13 +337,7 @@ struct pcvtid {
#define MAXHOSTNAMELEN 32
#endif /* !MAXHOSTNAMELEN */
-#if defined(_POSIX_SOURCE)
#include <limits.h>
-#else
-#define _POSIX_SOURCE
-#include <limits.h>
-#undef _POSIX_SOURCE
-#endif /* _POSIX_SOURCE */
#ifndef DEV_MEM
#define DEV_MEM "/dev/mem"
diff --git a/hw/xfree86/parser/scan.c b/hw/xfree86/parser/scan.c
index 6d46a5621..1eb35ed73 100644
--- a/hw/xfree86/parser/scan.c
+++ b/hw/xfree86/parser/scan.c
@@ -65,14 +65,7 @@
#include <stdarg.h>
#include <X11/Xdefs.h>
#include <X11/Xfuncproto.h>
-
-#if defined(_POSIX_SOURCE)
-#include <limits.h>
-#else
-#define _POSIX_SOURCE
#include <limits.h>
-#undef _POSIX_SOURCE
-#endif /* _POSIX_SOURCE */
#if !defined(MAXHOSTNAMELEN)
#define MAXHOSTNAMELEN 32
diff --git a/os/osdep.h b/os/osdep.h
index a0d57b8db..c5bec3f56 100644
--- a/os/osdep.h
+++ b/os/osdep.h
@@ -55,14 +55,7 @@ SOFTWARE.
#include <X11/Xdmcp.h>
#endif
-#ifdef _POSIX_SOURCE
#include <limits.h>
-#else
-#define _POSIX_SOURCE
-#include <limits.h>
-#undef _POSIX_SOURCE
-#endif
-
#include <stddef.h>
#include <X11/Xos.h>
diff --git a/os/utils.c b/os/utils.c
index 611e8ac23..1972aa120 100644
--- a/os/utils.c
+++ b/os/utils.c
@@ -83,19 +83,7 @@ __stdcall unsigned long GetTickCount(void);
#include <X11/fonts/libxfont2.h>
#include "osdep.h"
#include "extension.h"
-#ifdef X_POSIX_C_SOURCE
-#define _POSIX_C_SOURCE X_POSIX_C_SOURCE
#include <signal.h>
-#undef _POSIX_C_SOURCE
-#else
-#if defined(_POSIX_SOURCE)
-#include <signal.h>
-#else
-#define _POSIX_SOURCE
-#include <signal.h>
-#undef _POSIX_SOURCE
-#endif
-#endif
#ifndef WIN32
#include <sys/wait.h>
#endif
More information about the xorg-commit
mailing list