From f357024377435d2b2343f283b900979c307d6a36 Mon Sep 17 00:00:00 2001 From: Harry Jeffery Date: Sat, 13 Jul 2019 11:02:37 +0100 Subject: Make window system configurable --- Makefile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index f157e87..e690e8b 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ INSTALL_PROGRAM ?= install -m 0755 override CFLAGS += -std=c99 -W -Wall -Wpedantic -Wextra $(shell pkg-config --cflags pangocairo) override CPPFLAGS += -D_XOPEN_SOURCE=700 -override LIBS := -lwayland-client -lwayland-egl -lEGL -lGL -lpthread -lxkbcommon $(shell pkg-config --libs pangocairo) +override LIBS := -lGL -lpthread -lxkbcommon $(shell pkg-config --libs pangocairo) BUILDDIR ?= build TARGET := $(BUILDDIR)/imv @@ -34,8 +34,12 @@ SOURCES += src/list.c SOURCES += src/log.c SOURCES += src/navigator.c SOURCES += src/viewport.c -SOURCES += src/window.c -SOURCES += src/xdg-shell-protocol.c + +ifeq ($(WINDOWS),wayland) + SOURCES += src/wl_window.c + SOURCES += src/xdg-shell-protocol.c + override LIBS += -lwayland-client -lwayland-egl -lEGL +endif # Add backends to build as configured ifeq ($(BACKEND_FREEIMAGE),yes) -- cgit v1.2.3