]> git.sur5r.net Git - i3/i3/blobdiff - common.mk
Make code compatible with yajl 2.0 *and* 1.0
[i3/i3] / common.mk
index e3a9f80bf09de5ba6e2ee9196fae5d7e66dfea9c..d45286a8f63b81e886646ee3aeaee46f6701d4da 100644 (file)
--- a/common.mk
+++ b/common.mk
@@ -73,6 +73,10 @@ ifeq ($(UNAME),FreeBSD)
 LDFLAGS += -liconv
 endif
 
+# Fallback for libyajl 1 which did not include yajl_version.h. We need
+# YAJL_MAJOR from that file to decide which code path should be used.
+CFLAGS += -idirafter yajl-fallback
+
 ifneq (,$(filter Linux GNU GNU/%, $(UNAME)))
 CFLAGS += -D_GNU_SOURCE
 endif