aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2016-06-04 04:18:24 -0400
committerJesse Luehrs <doy@tozt.net>2016-06-04 04:18:24 -0400
commitf703ec243726aaa9ca0073e460509f149d5565d4 (patch)
treed244ade0364b3c748f2e7973032bcce5fa91ff2a
parent0f672812a773e73ed9651a7f664aaa6f0930caa5 (diff)
downloadrunes-f703ec243726aaa9ca0073e460509f149d5565d4.tar.gz
runes-f703ec243726aaa9ca0073e460509f149d5565d4.zip
enable an explicit std, and move the feature test macro to a cflag
we can't enable pedantic here, because a pangocairo header makes gcc unhappy
-rw-r--r--Makefile4
-rw-r--r--src/pty-unix.c1
2 files changed, 2 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 99e139e..06f1c48 100644
--- a/Makefile
+++ b/Makefile
@@ -26,8 +26,8 @@ COBJ = $(BUILD)runesc.o \
$(SOCK_OBJ)
LIBS = cairo cairo-xlib libevent pangocairo
OPT ?= -g
-CFLAGS ?= $(OPT) -Wall -Wextra -Werror
-LDFLAGS ?= $(OPT) -Wall -Wextra -Werror
+CFLAGS ?= $(OPT) -Wall -Wextra -Werror -std=c1x -D_XOPEN_SOURCE=600
+LDFLAGS ?= $(OPT) -Wall -Wextra -Werror -std=c1x -D_XOPEN_SOURCE=600
ALLCFLAGS = $(shell pkg-config --cflags $(LIBS)) -Ilibvt100/src $(CFLAGS)
ALLLDFLAGS = $(shell pkg-config --libs $(LIBS)) $(LDFLAGS)
diff --git a/src/pty-unix.c b/src/pty-unix.c
index 8eed477..becf608 100644
--- a/src/pty-unix.c
+++ b/src/pty-unix.c
@@ -1,4 +1,3 @@
-#define _XOPEN_SOURCE 600
#include <errno.h>
#include <fcntl.h>
#include <signal.h>