mirror of
https://github.com/eclipse-mosquitto/mosquitto.git
synced 2026-04-19 08:48:11 +02:00
struct mosquitto_msg_store -> struct mosquitto_base_msg This is the base message which client messages and retained messages refer to. The base messages are still held in the message store. This change comes about because the persistence interface exposes these message types. Prior to this commit the different messages were "msg", "client_msg", and "retain". After this commit there is "base_msg", "client_msg", and and "retain_msg" in the persist interface.
74 lines
2 KiB
Makefile
74 lines
2 KiB
Makefile
R=../..
|
|
include ${R}/config.mk
|
|
|
|
.PHONY : all binary check clean reallyclean test install uninstall
|
|
|
|
PLUGIN_NAME=mosquitto_persist_sqlite
|
|
LOCAL_CPPFLAGS=-I${R}/src/
|
|
|
|
OBJS= \
|
|
base_msgs.o \
|
|
clients.o \
|
|
client_msgs.o \
|
|
init.o \
|
|
plugin.o \
|
|
restore.o \
|
|
retain_msgs.o \
|
|
subscriptions.o \
|
|
tick.o
|
|
|
|
ifeq ($(WITH_SQLITE),yes)
|
|
ALL_DEPS:= binary
|
|
else
|
|
ALL_DEPS:=
|
|
endif
|
|
|
|
all : ${ALL_DEPS}
|
|
binary : ${PLUGIN_NAME}.so
|
|
|
|
${PLUGIN_NAME}.so : ${OBJS}
|
|
${CROSS_COMPILE}${CC} $(PLUGIN_LDFLAGS) -fPIC -shared $^ -o $@ -lsqlite3
|
|
|
|
clients.o : clients.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
client_msgs.o : client_msgs.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
init.o : init.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
base_msgs.o : base_msgs.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
plugin.o : plugin.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
restore.o : restore.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
retain_msgs.o : retain_msgs.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
subscriptions.o : subscriptions.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
tick.o : tick.c persist_sqlite.h
|
|
${CROSS_COMPILE}${CC} $(LOCAL_CPPFLAGS) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) -c $< -o $@
|
|
|
|
reallyclean : clean
|
|
clean:
|
|
-rm -f *.o ${PLUGIN_NAME}.so *.gcda *.gcno
|
|
|
|
check: test
|
|
test:
|
|
|
|
install: all
|
|
ifeq ($(WITH_SQLITE),yes)
|
|
$(INSTALL) -d "${DESTDIR}$(libdir)"
|
|
$(INSTALL) ${STRIP_OPTS} ${PLUGIN_NAME}.so "${DESTDIR}${libdir}/${PLUGIN_NAME}.so"
|
|
endif
|
|
|
|
uninstall :
|
|
-rm -f "${DESTDIR}${libdir}/${PLUGIN_NAME}.so"
|