From a675b2c0c23f032f0cb59e886d406f18a3e0dda4 Mon Sep 17 00:00:00 2001 From: Nicolas Favre-Felix Date: Sun, 5 Jul 2020 10:36:48 -0700 Subject: [PATCH] Check for MsgPackC on macOS --- Makefile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Makefile b/Makefile index 55087d4..b41bd00 100644 --- a/Makefile +++ b/Makefile @@ -24,6 +24,14 @@ ifneq ($(strip $(MSGPACKC_LIB)),) FORMAT_OBJS += src/formats/msgpack.o CFLAGS += -DMSGPACK=1 LDFLAGS += -lmsgpackc +else +# check for MessagePack on macOS +MSGPACK_OSX_LIB=$(shell ls /usr/local/lib/libmsgpackc.dylib 2>/dev/null) +ifneq ($(strip $(MSGPACK_OSX_LIB)),) + FORMAT_OBJS += src/formats/msgpack.o + CFLAGS += -DMSGPACK=1 + LDFLAGS += -lmsgpackc +endif endif endif