From c43719d6ba9c7d3395af1f15c74882bdf26cdc86 Mon Sep 17 00:00:00 2001 From: David Härdeman Date: Wed, 24 Jun 2020 00:38:52 +0200 Subject: Add global _GNU_SOURCE define --- meson.build | 2 ++ minecctl/minecctl.c | 1 - minecproxy/idle.c | 1 - minecproxy/main.c | 1 - minecproxy/server-config.c | 1 - minecproxy/server-proxy.c | 1 - minecproxy/server.c | 1 - minecproxy/signal-handler.c | 1 - minecproxy/uring.c | 1 - shared/config-parser.c | 1 - shared/config-parser.h | 1 - 11 files changed, 2 insertions(+), 10 deletions(-) diff --git a/meson.build b/meson.build index cc9edc1..cd95e87 100644 --- a/meson.build +++ b/meson.build @@ -5,6 +5,8 @@ project('minecproxy', default_options : ['c_std=gnu18'] ) +add_global_arguments('-D_GNU_SOURCE', language: 'c') + sysconfdir = join_paths(get_option('prefix'), get_option('sysconfdir'), meson.project_name()) mainconfname = meson.project_name() + '.conf' diff --git a/minecctl/minecctl.c b/minecctl/minecctl.c index acee3b1..bbc5d47 100644 --- a/minecctl/minecctl.c +++ b/minecctl/minecctl.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/minecproxy/idle.c b/minecproxy/idle.c index c49846d..79c7bab 100644 --- a/minecproxy/idle.c +++ b/minecproxy/idle.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/minecproxy/main.c b/minecproxy/main.c index f83b956..9a57aa8 100644 --- a/minecproxy/main.c +++ b/minecproxy/main.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/minecproxy/server-config.c b/minecproxy/server-config.c index c388eb2..5d8c724 100644 --- a/minecproxy/server-config.c +++ b/minecproxy/server-config.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/minecproxy/server-proxy.c b/minecproxy/server-proxy.c index d8ff0cf..087773d 100644 --- a/minecproxy/server-proxy.c +++ b/minecproxy/server-proxy.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/minecproxy/server.c b/minecproxy/server.c index 534ceca..c6e6480 100644 --- a/minecproxy/server.c +++ b/minecproxy/server.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/minecproxy/signal-handler.c b/minecproxy/signal-handler.c index 67c2e0b..0173bf8 100644 --- a/minecproxy/signal-handler.c +++ b/minecproxy/signal-handler.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/minecproxy/uring.c b/minecproxy/uring.c index e979471..79b90b8 100644 --- a/minecproxy/uring.c +++ b/minecproxy/uring.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/shared/config-parser.c b/shared/config-parser.c index e2ff413..8094cda 100644 --- a/shared/config-parser.c +++ b/shared/config-parser.c @@ -1,4 +1,3 @@ -#define _GNU_SOURCE #include #include #include diff --git a/shared/config-parser.h b/shared/config-parser.h index e371dec..7d99e31 100644 --- a/shared/config-parser.h +++ b/shared/config-parser.h @@ -1,7 +1,6 @@ #ifndef fooconfigparserhfoo #define fooconfigparserhfoo -#define _GNU_SOURCE #include #include #include -- cgit v1.2.3