]> git.sur5r.net Git - i3/i3/commitdiff
common.mk: Split WM XCB flags
authorQuentin Glidic <sardemff7+git@sardemff7.net>
Sun, 22 Jul 2012 22:02:01 +0000 (00:02 +0200)
committerQuentin Glidic <sardemff7+git@sardemff7.net>
Sun, 22 Jul 2012 22:04:01 +0000 (00:04 +0200)
common.mk
src/i3.mk

index da75e5f170929d0bf4f5218a2ff513ce87d014e3..e347574e39bb29ae858528e843e7cf84c9814fef 100644 (file)
--- a/common.mk
+++ b/common.mk
@@ -71,9 +71,6 @@ CFLAGS += $(call cflags_for_lib, xcb-aux)
 else
 CFLAGS += $(call cflags_for_lib, xcb-util)
 endif
-CFLAGS += $(call cflags_for_lib, xcb-icccm)
-CFLAGS += $(call cflags_for_lib, xcb-xinerama)
-CFLAGS += $(call cflags_for_lib, xcb-randr)
 CFLAGS += $(call cflags_for_lib, xcb)
 
 LIBS += -L $(TOPDIR) -li3
@@ -85,11 +82,16 @@ LIBS += $(call ldflags_for_lib, xcb-aux,xcb-aux)
 else
 LIBS += $(call ldflags_for_lib, xcb-util)
 endif
-LIBS += $(call ldflags_for_lib, xcb-icccm,xcb-icccm)
-LIBS += $(call ldflags_for_lib, xcb-xinerama,xcb-xinerama)
-LIBS += $(call ldflags_for_lib, xcb-randr,xcb-randr)
 LIBS += $(call ldflags_for_lib, xcb,xcb)
 
+# XCB WM stuff
+XCB_WM_CFLAGS := $(call cflags_for_lib, xcb-icccm)
+XCB_WM_CFLAGS += $(call cflags_for_lib, xcb-xinerama)
+XCB_WM_CFLAGS += $(call cflags_for_lib, xcb-randr)
+XCB_WM_LIBS   := $(call ldflags_for_lib, xcb-icccm,xcb-icccm)
+XCB_WM_LIBS   += $(call ldflags_for_lib, xcb-xinerama,xcb-xinerama)
+XCB_WM_LIBS   += $(call ldflags_for_lib, xcb-randr,xcb-randr)
+
 # Xlib
 X11_CFLAGS := $(call cflags_for_lib, x11)
 X11_LIBS   := $(call ldflags_for_lib, x11,X11)
index b8557eb3f805592bea9421ae2b7f99ced185e3f9..e056342d44555c6f792cbec2aff8147c2c977132 100644 (file)
--- a/src/i3.mk
+++ b/src/i3.mk
@@ -6,8 +6,8 @@ i3_SOURCES_GENERATED  = src/cfgparse.tab.c src/cfgparse.yy.c
 i3_SOURCES           := $(filter-out $(i3_SOURCES_GENERATED),$(wildcard src/*.c))
 i3_HEADERS_CMDPARSER := $(wildcard include/GENERATED_*.h)
 i3_HEADERS           := $(filter-out $(i3_HEADERS_CMDPARSER),$(wildcard include/*.h))
-i3_CFLAGS             = $(X11_CFLAGS) $(XCURSOR_CFLAGS) $(YAJL_CFLAGS) $(LIBEV_CFLAGS) $(PCRE_CFLAGS) $(LIBSN_CFLAGS)
-i3_LIBS               = $(X11_LIBS) $(XCURSOR_LIBS) $(YAJL_LIBS) $(LIBEV_LIBS) $(PCRE_LIBS) $(LIBSN_LIBS) -lm
+i3_CFLAGS             = $(XCB_WM_CFLAGS) $(X11_CFLAGS) $(XCURSOR_CFLAGS) $(YAJL_CFLAGS) $(LIBEV_CFLAGS) $(PCRE_CFLAGS) $(LIBSN_CFLAGS)
+i3_LIBS               = $(XCB_WM_LIBS) $(X11_LIBS) $(XCURSOR_LIBS) $(YAJL_LIBS) $(LIBEV_LIBS) $(PCRE_LIBS) $(LIBSN_LIBS) -lm
 
 i3_OBJECTS := $(i3_SOURCES_GENERATED:.c=.o) $(i3_SOURCES:.c=.o)