From: Michael Stapelberg Date: Mon, 16 Feb 2009 02:35:16 +0000 (+0100) Subject: Linux needs -D_GNU_SOURCE for some functions, so enable it in Makefile X-Git-Tag: 3.a~174 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=d88c49682f78318ac03ae49c7dddd47a606bfb2a;p=i3%2Fi3 Linux needs -D_GNU_SOURCE for some functions, so enable it in Makefile --- diff --git a/Makefile b/Makefile index 28b7a636..06388cb9 100644 --- a/Makefile +++ b/Makefile @@ -16,6 +16,10 @@ CFLAGS += -I/usr/pkg/include LDFLAGS += -Wl,-rpath,/usr/local/lib -Wl,-rpath,/usr/pkg/lib endif +ifeq ($(UNAME),Linux) +CFLAGS += -D_GNU_SOURCE +endif + ifeq ($(DEBUG),1) # Extended debugging flags, macros shall be available in gcc CFLAGS += -gdwarf-2 diff --git a/src/layout.c b/src/layout.c index a3b87f17..48fcaf36 100644 --- a/src/layout.c +++ b/src/layout.c @@ -10,7 +10,6 @@ * layout.c: Functions handling layout/drawing of window decorations * */ -#define _GNU_SOURCE #include #include #include diff --git a/src/mainx.c b/src/mainx.c index 70a0f819..b8a8da19 100644 --- a/src/mainx.c +++ b/src/mainx.c @@ -8,7 +8,6 @@ * See file LICENSE for license information. * */ -#define _GNU_SOURCE #include #include #include