From 106646a98f9e07d650a5d5e0d5aa7373c9973e67 Mon Sep 17 00:00:00 2001 From: Intel A80486DX2-66 Date: Sun, 7 Jul 2024 01:08:41 +0300 Subject: [PATCH] Makefile: add POSIX macro to `CFLAGS` Declare macro `_POSIX_C_SOURCE` to `200809L` during compilation --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index e0bc307..9ed63fc 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,8 @@ CC ?= gcc DEBUG ?= 0 -CFLAGS = -Wall -Werror -Wextra -Wpedantic -std=c99 -Ofast +CFLAGS = -Wall -Werror -Wextra -Wpedantic -std=c99 -Ofast \ +-D_POSIX_C_SOURCE=200809L ifeq ($(DEBUG), 1) CFLAGS += -g -DDEBUG