summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--log.c1
-rw-r--r--loop.c1
-rw-r--r--main.c1
-rw-r--r--meson.build2
-rw-r--r--password-buffer.c1
-rw-r--r--pool-buffer.c1
-rw-r--r--shadow.c1
7 files changed, 3 insertions, 5 deletions
diff --git a/log.c b/log.c
index cb46039..dcb5090 100644
--- a/log.c
+++ b/log.c
@@ -1,4 +1,3 @@
-#define _POSIX_C_SOURCE 199506L
#include <errno.h>
#include <stdarg.h>
#include <stdio.h>
diff --git a/loop.c b/loop.c
index 8cbfaa6..7081b13 100644
--- a/loop.c
+++ b/loop.c
@@ -1,4 +1,3 @@
-#define _POSIX_C_SOURCE 200809L
#include <limits.h>
#include <string.h>
#include <stdbool.h>
diff --git a/main.c b/main.c
index 3a3a68f..4794817 100644
--- a/main.c
+++ b/main.c
@@ -1,4 +1,3 @@
-#define _POSIX_C_SOURCE 200809L
#include <assert.h>
#include <ctype.h>
#include <errno.h>
diff --git a/meson.build b/meson.build
index f69ebfb..a530a2d 100644
--- a/meson.build
+++ b/meson.build
@@ -11,6 +11,8 @@ project(
],
)
+add_project_arguments('-D_POSIX_C_SOURCE=200809L', language: 'c')
+
add_project_arguments(
[
'-Wno-unused-parameter',
diff --git a/password-buffer.c b/password-buffer.c
index 7b1e465..1af992a 100644
--- a/password-buffer.c
+++ b/password-buffer.c
@@ -1,4 +1,3 @@
-#define _POSIX_C_SOURCE 200809L
#include "password-buffer.h"
#include "log.h"
#include "swaylock.h"
diff --git a/pool-buffer.c b/pool-buffer.c
index dfb4d0d..96271e1 100644
--- a/pool-buffer.c
+++ b/pool-buffer.c
@@ -1,4 +1,3 @@
-#define _POSIX_C_SOURCE 200809L
#include <assert.h>
#include <cairo/cairo.h>
#include <errno.h>
diff --git a/shadow.c b/shadow.c
index 3399d04..83b0cc0 100644
--- a/shadow.c
+++ b/shadow.c
@@ -1,3 +1,4 @@
+#undef _POSIX_C_SOURCE
#define _XOPEN_SOURCE // for crypt
#include <assert.h>
#include <pwd.h>