Skip to contentSkip to conversation

gst1-plugins-bad: hls: fix broken dependency

PATCH New Rahul Bedarkar 2 participants 2 messages Aug 4, 2016 – Aug 5, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gst1-plugins-bad: hls: fix broken dependency

HLS plugin can be built with nettle or libgcrypt or openssl cryptographic backend. But current dependency on gnutls is incorrect. It has been working so far because gnutls depends on nettle.

gst-plugins-bad's build system for HLS allows user to choose which cryptographic backend to use. If that is not specified, it internally checks for nettle or libgcrypt or openssl in order. If none of the cryptographic backend is available, HLS plugin gets disabled internally.

Select cryptographic backend according to which cryptographic packages are available. If both libgcrypt or openssl are not available, choose nettle by default.

---
 package/gstreamer1/gst1-plugins-bad/Config.in           |  2 +-
 package/gstreamer1/gst1-plugins-bad/gst1-plugins-bad.mk | 14 +++++++++++++-
 2 files changed, 14 insertions(+), 2 deletions(-)
package/gstreamer1/gst1-plugins-bad/Config.in +1 -1
index 0f9fb15..2f288ca 100644
@@ -530,7 +530,7 @@ comment "gl needs the gst1-plugins-bad opengl library"
 
 config BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_HLS
 	bool "hls"
-	select BR2_PACKAGE_GNUTLS
+	select BR2_PACKAGE_NETTLE if !(BR2_PACKAGE_LIBGCRYPT || BR2_PACKAGE_OPENSSL)
 	help
 	  Fragmented streaming plugins
 
package/gstreamer1/gst1-plugins-bad/gst1-plugins-bad.mk +13 -1
index 8f739ec..3ffdd10 100644
@@ -650,7 +650,19 @@ endif
 
 ifeq ($(BR2_PACKAGE_GST1_PLUGINS_BAD_PLUGIN_HLS),y)
 GST1_PLUGINS_BAD_CONF_OPTS += --enable-hls
-GST1_PLUGINS_BAD_DEPENDENCIES += gnutls
+
+ifeq ($(BR2_PACKAGE_NETTLE),y)
+GST1_PLUGINS_BAD_DEPENDENCIES += nettle
+GST1_PLUGINS_BAD_CONF_OPTS += --with-hls-crypto=nettle
+else ifeq ($(BR2_PACKAGE_LIBGCRYPT),y)
+GST1_PLUGINS_BAD_DEPENDENCIES += libgcrypt
+GST1_PLUGINS_BAD_CONF_OPTS += --with-hls-crypto=libgcrypt \
+	--with-libgcrypt-prefix=$(STAGING_DIR)/usr
+else
+GST1_PLUGINS_BAD_DEPENDENCIES += openssl
+GST1_PLUGINS_BAD_CONF_OPTS += --with-hls-crypto=openssl
+endif
+
 else
 GST1_PLUGINS_BAD_CONF_OPTS += --disable-hls
 endif
Signature · 1 line
2.6.2
#1 lore raw

PATCH 1/1 gst1-plugins-bad: hls: fix broken dependency

Hello,

Quoted 13 lines · Rahul Bedarkar

HLS plugin can be built with nettle or libgcrypt or openssl cryptographic backend. But current dependency on gnutls is incorrect. It has been working so far because gnutls depends on nettle.

gst-plugins-bad's build system for HLS allows user to choose which cryptographic backend to use. If that is not specified, it internally checks for nettle or libgcrypt or openssl in order. If none of the cryptographic backend is available, HLS plugin gets disabled internally.

Select cryptographic backend according to which cryptographic packages are available. If both libgcrypt or openssl are not available, choose nettle by default.

Quoted 8 lines
---
 package/gstreamer1/gst1-plugins-bad/Config.in           |  2 +-
 package/gstreamer1/gst1-plugins-bad/gst1-plugins-bad.mk | 14 +++++++++++++-
 2 files changed, 14 insertions(+), 2 deletions(-)

Applied to master, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com