diff options
-rw-r--r-- | Makefile | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -1,3 +1,5 @@ +-include config.mk + VERSION=0.2 GIT_VERSION := $(shell [ -d .git ] && echo "-$$(git describe --always)") @@ -7,8 +9,12 @@ CFLAGS += -DVERSION=\"$(VERSION)$(GIT_VERSION)\" TARGETS = sircbot sircbot-send ifneq (NOLUA,) +LUAPC ?= lua +PKGCONFIG ?= pkg-config TARGETS += sircbot.so -LUA_LIBS=-llua +LUA_CFLAGS = $(shell $(PKGCONFIG) --cflags $(LUAPC)) +LUA_LIBS = $(shell $(PKGCONFIG) --libs $(LUAPC)) +CFLAGS += $(LUA_CFLAGS) endif prefix ?= /usr/local |