mosquitto/plugins/payload-modification/Makefile
Peter Robinson 9d7580fdb6 Use libdir as the install prefix for plugins
Use the libdir variable from config.mk just like lib/ uses to ensure
that the plugins are installed into the same location as the library.
This fixes systems that use lib64 for libraries like most 64 bit
Linux distributions.

Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
2020-12-18 08:05:06 +00:00

28 lines
662 B
Makefile

include ../../config.mk
.PHONY : all binary check clean reallyclean test install uninstall
PLUGIN_NAME=mosquitto_payload_modification
all : binary
binary : ${PLUGIN_NAME}.so
${PLUGIN_NAME}.so : ${PLUGIN_NAME}.c
$(CROSS_COMPILE)$(CC) $(PLUGIN_CPPFLAGS) $(PLUGIN_CFLAGS) $(PLUGIN_LDFLAGS) -fPIC -shared $< -o $@
reallyclean : clean
clean:
-rm -f *.o ${PLUGIN_NAME}.so *.gcda *.gcno
check: test
test:
install: ${PLUGIN_NAME}.so
# Don't install, these are examples only.
#$(INSTALL) -d "${DESTDIR}$(libdir)"
#$(INSTALL) ${STRIP_OPTS} ${PLUGIN_NAME}.so "${DESTDIR}${libdir}/${PLUGIN_NAME}.so"
uninstall :
-rm -f "${DESTDIR}${libdir}/${PLUGIN_NAME}.so"