瀏覽代碼

package/libsoup3: new package

Libsoup3 has a new API [1], packages using libsoup may not compile
with libsoup3 or may crash at runtime in unexpected ways, so we add a
new package. It can be installed side by site with libsoup, without
any conflict.

[1] https://libsoup.org/libsoup-3.0/ch02.html

Signed-off-by: Thomas Devoogdt <thomas@devoogdt.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Thomas Devoogdt 2 年之前
父節點
當前提交
28e38f4d5c
共有 5 個文件被更改,包括 97 次插入0 次删除
  1. 1 0
      DEVELOPERS
  2. 1 0
      package/Config.in
  3. 34 0
      package/libsoup3/Config.in
  4. 4 0
      package/libsoup3/libsoup3.hash
  5. 57 0
      package/libsoup3/libsoup3.mk

+ 1 - 0
DEVELOPERS

@@ -2854,6 +2854,7 @@ F:	toolchain/
 
 N:	Thomas Devoogdt <thomas@devoogdt.com>
 F:	package/fluent-bit/
+F:	package/libsoup3/
 
 N:	Thomas Huth <huth@tuxfamily.org>
 F:	board/qemu/m68k-mcf5208/

+ 1 - 0
package/Config.in

@@ -1957,6 +1957,7 @@ menu "Networking"
 	source "package/libshout/Config.in"
 	source "package/libsocketcan/Config.in"
 	source "package/libsoup/Config.in"
+	source "package/libsoup3/Config.in"
 	source "package/libsrtp/Config.in"
 	source "package/libstrophe/Config.in"
 	source "package/libteam/Config.in"

+ 34 - 0
package/libsoup3/Config.in

@@ -0,0 +1,34 @@
+config BR2_PACKAGE_LIBSOUP3
+	bool "libsoup3"
+	depends on BR2_USE_WCHAR # glib2, libpsl
+	depends on BR2_TOOLCHAIN_HAS_THREADS # glib2
+	depends on BR2_USE_MMU # glib2
+	select BR2_PACKAGE_LIBGLIB2
+	select BR2_PACKAGE_LIBPSL
+	select BR2_PACKAGE_NGHTTP2
+	select BR2_PACKAGE_SQLITE
+	help
+	  libsoup3 is an HTTP client/server library. It uses GObject
+	  and the GLib main loop, to integrate well with GNOME
+	  applications.
+
+	  https://wiki.gnome.org/Projects/libsoup
+
+if BR2_PACKAGE_LIBSOUP3
+
+config BR2_PACKAGE_LIBSOUP3_SSL
+	bool "https support"
+	depends on !BR2_STATIC_LIBS # glib-networking, gnutls
+	select BR2_PACKAGE_GLIB_NETWORKING # runtime
+	select BR2_PACKAGE_GNUTLS # runtime
+	help
+	  Enable HTTPS (SSL) support.
+
+comment "libsoup3 https support needs a toolchain w/ dynamic library"
+	depends on BR2_STATIC_LIBS
+
+endif
+
+comment "libsoup3 needs a toolchain w/ wchar, threads"
+	depends on BR2_USE_MMU
+	depends on !BR2_USE_WCHAR || !BR2_TOOLCHAIN_HAS_THREADS

+ 4 - 0
package/libsoup3/libsoup3.hash

@@ -0,0 +1,4 @@
+# From https://download.gnome.org/sources/libsoup/3.4/libsoup-3.4.2.sha256sum
+sha256  78c8fa37cb152d40ec8c4a148d6155e2f6947f3f1602a7cda3a31ad40f5ee2f3  libsoup-3.4.2.tar.xz
+# Locally calculated
+sha256  b7993225104d90ddd8024fd838faf300bea5e83d91203eab98e29512acebd69c  COPYING

+ 57 - 0
package/libsoup3/libsoup3.mk

@@ -0,0 +1,57 @@
+################################################################################
+#
+# libsoup3
+#
+################################################################################
+
+LIBSOUP3_VERSION_MAJOR = 3.4
+LIBSOUP3_VERSION = $(LIBSOUP3_VERSION_MAJOR).2
+LIBSOUP3_SOURCE = libsoup-$(LIBSOUP3_VERSION).tar.xz
+LIBSOUP3_SITE = https://download.gnome.org/sources/libsoup/$(LIBSOUP3_VERSION_MAJOR)
+LIBSOUP3_LICENSE = LGPL-2.0+
+LIBSOUP3_LICENSE_FILES = COPYING
+LIBSOUP3_CPE_ID_VENDOR = gnome
+LIBSOUP3_INSTALL_STAGING = YES
+LIBSOUP3_DEPENDENCIES = \
+	host-intltool \
+	host-libglib2 \
+	host-pkgconf \
+	libglib2 \
+	libpsl \
+	nghttp2 \
+	sqlite \
+	$(TARGET_NLS_DEPENDENCIES)
+
+LIBSOUP3_LDFLAGS = $(TARGET_LDFLAGS) $(TARGET_NLS_LIBS)
+
+LIBSOUP3_CONF_OPTS = \
+	-Dntlm=disabled \
+	-Dsysprof=disabled \
+	-Dtests=false \
+	-Dtls_check=false \
+	-Dvapi=disabled
+
+ifeq ($(BR2_PACKAGE_BROTLI),y)
+LIBSOUP3_CONF_OPTS += -Dbrotli=enabled
+LIBSOUP3_DEPENDENCIES += brotli
+else
+LIBSOUP3_CONF_OPTS += -Dbrotli=disabled
+endif
+
+ifeq ($(BR2_PACKAGE_GOBJECT_INTROSPECTION),y)
+LIBSOUP3_CONF_OPTS += -Dintrospection=enabled
+LIBSOUP3_DEPENDENCIES += gobject-introspection
+else
+LIBSOUP3_CONF_OPTS += -Dintrospection=disabled
+endif
+
+ifeq ($(BR2_PACKAGE_LIBKRB5),y)
+LIBSOUP3_CONF_OPTS += \
+	-Dgssapi=enabled \
+	-Dkrb5_config=$(STAGING_DIR)/usr/bin/krb5-config
+LIBSOUP3_DEPENDENCIES += libkrb5
+else
+LIBSOUP3_CONF_OPTS += -Dgssapi=disabled
+endif
+
+$(eval $(meson-package))