Skip to content
Snippets Groups Projects
Commit 301c88a7 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Use pkg-config for detectiong libmosquitto presence and lib name

Apparently the mosquitto.h won't always be installed in /usr/include on
all systems (e.g. Deuce's FreeBSD gitlab-runner system)
parent 653e43e8
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
Pipeline #4409 failed
......@@ -89,10 +89,11 @@ ifeq ($(os),linux)
CON_LIBS += -lsystemd
endif
endif
ifeq ($(shell test -f /usr/include/mosquitto.h && echo "yes"),yes)
ifeq ($(shell pkg-config libmosquitto --exists && echo "yes"),yes)
CFLAGS += -DUSE_MOSQUITTO
CON_LIBS += -lmosquitto
JS_LIBS += -lmosquitto
CFLAGS += $(shell pkg-config libmosquitto --cflags)
CON_LIBS += $(shell pkg-config libmosquitto --libs)
JS_LIBS += $(shell pkg-config libmosquitto --libs)
endif
include sbbsdefs.mk
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment