package/shairport-sync: add mqtt option
authorJörg Krause <joerg.krause@embedded.rocks>
Tue, 3 Dec 2019 10:53:41 +0000 (11:53 +0100)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Sun, 8 Dec 2019 22:21:19 +0000 (23:21 +0100)
Shairport Sync added support for the MQTT protocol in version 3.2. For
full MQTT support Avahi and DBus support are required.

Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/shairport-sync/Config.in
package/shairport-sync/shairport-sync.mk

index 750767e5675ed93ff234eda8d13e971d891ab9f1..528767ba9c46be65d9841bd2827d03eeba0de2ad 100644 (file)
@@ -52,6 +52,23 @@ config BR2_PACKAGE_SHAIRPORT_SYNC_LIBSOXR
          can be heard in some circumstances. Libsoxr allows this
          interpolation to be done much more smoothly and subtly.
 
+config BR2_PACKAGE_SHAIRPORT_SYNC_MQTT
+       bool "mqtt support"
+       depends on BR2_USE_MMU # avahi
+       depends on BR2_TOOLCHAIN_HAS_THREADS # avahi
+       depends on !BR2_STATIC_LIBS # avahi
+       select BR2_PACKAGE_AVAHI
+       select BR2_PACKAGE_AVAHI_DAEMON
+       select BR2_PACKAGE_DBUS
+       select BR2_PACKAGE_MOSQUITTO
+       help
+         Enable support for the MQTT, the Message Queuing Telemetry
+         Transport protocol.
+
+comment "shairport-sync mqtt support needs a toolchain w/ dynamic library, threads"
+       depends on BR2_USE_MMU
+       depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS
+
 endif
 
 comment "shairport-sync needs a toolchain w/ C++, NPTL"
index a20570f9158d20c365672065f6e1765fdab11562..880a058909fb305e9ecd6150986338eb2eafffdf 100644 (file)
@@ -66,6 +66,11 @@ SHAIRPORT_SYNC_DEPENDENCIES += libsoxr
 SHAIRPORT_SYNC_CONF_OPTS += --with-soxr
 endif
 
+ifeq ($(BR2_PACKAGE_SHAIRPORT_SYNC_MQTT),y)
+SHAIRPORT_SYNC_DEPENDENCIES += avahi dbus mosquitto
+SHAIRPORT_SYNC_CONF_OPTS += --with-mqtt-client
+endif
+
 define SHAIRPORT_SYNC_INSTALL_TARGET_CMDS
        $(INSTALL) -D -m 0755 $(@D)/shairport-sync \
                $(TARGET_DIR)/usr/bin/shairport-sync