2014-07-30 14:14:13 +02:00
|
|
|
# Variables for desktop notifications support
|
|
|
|
DESK_NOTIFY_LIBS = libnotify
|
2014-09-23 03:51:55 +02:00
|
|
|
DESK_NOTIFY_CFLAGS = -DBOX_NOTIFY
|
2014-07-30 14:14:13 +02:00
|
|
|
|
|
|
|
# Check if we can build desktop notifications support
|
2014-08-25 12:54:44 +02:00
|
|
|
CHECK_DESK_NOTIFY_LIBS = $(shell pkg-config --exists $(DESK_NOTIFY_LIBS) || echo -n "error")
|
2014-07-30 14:14:13 +02:00
|
|
|
ifneq ($(CHECK_DESK_NOTIFY_LIBS), error)
|
|
|
|
LIBS += $(DESK_NOTIFY_LIBS)
|
|
|
|
CFLAGS += $(DESK_NOTIFY_CFLAGS)
|
|
|
|
else
|
|
|
|
ifneq ($(MAKECMDGOALS), clean)
|
2014-08-25 12:54:44 +02:00
|
|
|
MISSING_DESK_NOTIFY_LIBS = $(shell for lib in $(DESK_NOTIFY_LIBS) ; do if ! pkg-config --exists $$lib ; then echo $$lib ; fi ; done)
|
2014-07-30 14:14:13 +02:00
|
|
|
$(warning WARNING -- Toxic will be compiled without desktop notifications support)
|
|
|
|
$(warning WARNING -- You need these libraries for desktop notifications support)
|
|
|
|
$(warning WARNING -- $(MISSING_DESK_NOTIFY_LIBS))
|
|
|
|
endif
|
|
|
|
endif
|