PC=pkg-config UCW_CFLAGS := $(shell $(PC) --cflags libucw) UCW_LIBS := $(shell $(PC) --libs libucw) MOSQUITTO_CFLAGS := $(shell $(PC) --cflags libmosquitto) MOSQUITTO_LIBS := $(shell $(PC) --libs libmosquitto) SYSTEMD_CFLAGS := $(shell $(PC) --cflags libsystemd) SYSTEMD_LIBS := $(shell $(PC) --libs libsystemd) CFLAGS=-O2 -Wall -Wextra -Wno-sign-compare -Wno-parentheses -Wstrict-prototypes -Wmissing-prototypes $(UCW_CFLAGS) $(SYSTEMD_CFLAGS) $(MOSQUITTO_CFLAGS) LDLIBS=$(UCW_LIBS) $(SYSTEMD_LIBS) $(MOSQUITTO_LIBS) -lpthread -lm all: burrow-bifrost burrow-bifrost: burrow-bifrost.o install: install -m 755 burrow-bifrost ~/bin/ clean: rm -f *.o burrow-bifrost .PHONY: all clean