Skip to contentSkip to conversation

package/libsoup3: new package

PATCH Superseded Thomas Devoogdt 1 participant 3 messages Aug 2, 2023

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 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 add a new package.

This replaces my original commit that was sent to the buildroot mailing list a long time ago: [2]

Changes for libsoup3:
- "0001-meson.build-set-c_std-to-gnu99.patch" is upstream now [2].
- The "gnome" option was dropped in [3].
- A new "libnghttp2" dependency is added since libsoup 2.99.6 (HTTP2 backend) [4].

[1] https://libsoup.org/libsoup-3.0/ch02.html
[2] https://patchwork.ozlabs.org/project/buildroot/patch/[email protected]/
[3] https://gitlab.gnome.org/GNOME/libsoup/-/commit/5c3d431bdb094c59997f2a23e31e83f815ab667c
[4] https://gitlab.gnome.org/GNOME/libsoup/-/commit/3fcaa882c4eb29fd754cdb6dd06195632cb4b52a
[5] https://gitlab.gnome.org/GNOME/libsoup/-/commit/1a1d29c3114ca86c673d0c0b02a492d0962dcfe8

---
 DEVELOPERS                     |  1 +
 package/Config.in              |  1 +
 package/libsoup3/Config.in     | 40 +++++++++++++++++++++++
 package/libsoup3/libsoup3.hash |  4 +++
 package/libsoup3/libsoup3.mk   | 58 ++++++++++++++++++++++++++++++++++
 5 files changed, 104 insertions(+)
 create mode 100644 package/libsoup3/Config.in
 create mode 100644 package/libsoup3/libsoup3.hash
 create mode 100644 package/libsoup3/libsoup3.mk
DEVELOPERS +1 -0
index 5023ecd775..700422dcfa 100644
@@ -2855,6 +2855,7 @@ F:	toolchain/
 
 N:	Thomas Devoogdt <[email protected]>
 F:	package/fluent-bit/
+F:	package/libsoup3/
 
 N:	Thomas Huth <[email protected]>
 F:	board/qemu/m68k-mcf5208/
package/Config.in +1 -0
index 54cddc3914..e12ee34e9f 100644
@@ -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"
package/libsoup3/Config.in new file +40 -0
new file mode 100644
index 0000000000..8a6cbc1e67
@@ -0,0 +1,40 @@
+config BR2_PACKAGE_LIBSOUP3
+	bool "libsoup3"
+	depends on BR2_USE_WCHAR # glib2, gnutls and libpsl
+	depends on BR2_TOOLCHAIN_HAS_THREADS # glib2
+	depends on BR2_USE_MMU # glib2
+	select BR2_PACKAGE_NGHTTP2
+	select BR2_PACKAGE_LIBXML2
+	select BR2_PACKAGE_LIBGLIB2
+	select BR2_PACKAGE_LIBPSL
+	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_GNOME
+	bool "libsoup3-gnome"
+	help
+	  Build libsoup3-gnome library.
+
+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
package/libsoup3/libsoup3.hash new file +4 -0
new file mode 100644
index 0000000000..01313b394b
@@ -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
package/libsoup3/libsoup3.mk new file +58 -0

58 lines not on this page · raw message

Signature · 6 lines
2.34.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#1 lore raw

PATCH 2/3 package/webkitgtk: add http/2 support by using libsoup3

Support added in 2.33.2:
https://webkitgtk.org/2021/06/08/webkitgtk2.33.2-released.html
"HTTP/2 support when building with libsoup3."

---
 package/webkitgtk/Config.in    | 10 +++++-----
 package/webkitgtk/webkitgtk.mk |  3 +--
 2 files changed, 6 insertions(+), 7 deletions(-)
package/webkitgtk/Config.in +5 -5
index 23c0bf41db..6835467c46 100644
@@ -31,9 +31,9 @@ config BR2_PACKAGE_WEBKITGTK
 	depends on !BR2_BINFMT_FLAT # icu
 	depends on BR2_HOST_GCC_AT_LEAST_4_9 # icu, host-ruby
 	depends on BR2_INSTALL_LIBSTDCPP
-	depends on BR2_TOOLCHAIN_HAS_THREADS # wayland, icu, libsoup
+	depends on BR2_TOOLCHAIN_HAS_THREADS # wayland, icu, libsoup3
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_8
-	depends on BR2_USE_WCHAR # icu, libsoup
+	depends on BR2_USE_WCHAR # icu, libsoup3
 	depends on BR2_PACKAGE_LIBGTK3
 	depends on BR2_PACKAGE_WEBKITGTK_ARCH_SUPPORTS
 	select BR2_PACKAGE_CAIRO
@@ -44,7 +44,7 @@ config BR2_PACKAGE_WEBKITGTK
 	select BR2_PACKAGE_JPEG
 	select BR2_PACKAGE_LIBGCRYPT
 	select BR2_PACKAGE_LIBSECRET
-	select BR2_PACKAGE_LIBSOUP
+	select BR2_PACKAGE_LIBSOUP3
 	select BR2_PACKAGE_LIBTASN1
 	select BR2_PACKAGE_LIBXML2
 	select BR2_PACKAGE_LIBXSLT
@@ -82,9 +82,9 @@ comment "sandboxing support needs a toolchain w/ headers >= 3.12"
 
 config BR2_PACKAGE_WEBKITGTK_HTTPS
 	bool "HTTPS support"
-	depends on !BR2_STATIC_LIBS # libsoup -> glib-networking, gnutls
+	depends on !BR2_STATIC_LIBS # libsoup3 -> glib-networking, gnutls
 	select BR2_PACKAGE_CA_CERTIFICATES # runtime
-	select BR2_PACKAGE_LIBSOUP_SSL
+	select BR2_PACKAGE_LIBSOUP3_SSL
 	help
 	  Enable HTTPS protocol support.
 
package/webkitgtk/webkitgtk.mk +1 -2
index 56277a0a0a..f578868e52 100644
@@ -14,7 +14,7 @@ WEBKITGTK_LICENSE_FILES = \
 	Source/WebCore/LICENSE-LGPL-2.1
 WEBKITGTK_CPE_ID_VENDOR = webkitgtk
 WEBKITGTK_DEPENDENCIES = host-ruby host-python3 host-gperf host-unifdef \
-	enchant harfbuzz icu jpeg libgcrypt libgtk3 libsecret libsoup \
+	enchant harfbuzz icu jpeg libgcrypt libgtk3 libsecret libsoup3 \
 	libtasn1 libxml2 libxslt openjpeg sqlite webp woff2
 WEBKITGTK_CONF_OPTS = \
 	-DENABLE_API_TESTS=OFF \
@@ -27,7 +27,6 @@ WEBKITGTK_CONF_OPTS = \
 	-DUSE_AVIF=OFF \
 	-DUSE_LIBHYPHEN=OFF \
 	-DUSE_OPENJPEG=ON \
-	-DUSE_SOUP2=ON \
 	-DUSE_WOFF2=ON
 
 ifeq ($(BR2_PACKAGE_WEBKITGTK_SANDBOX),y)
Signature · 6 lines
2.34.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
#2 lore raw

PATCH 3/3 package/webkitgtk: add http/2 support by using libsoup3

In reply to Thomas Devoogdt

Support added in 2.33.2:
https://wpewebkit.org/release/wpewebkit-2.33.2.html
"HTTP/2 support when building with libsoup3."

---
 package/wpewebkit/Config.in    | 6 +++---
 package/wpewebkit/wpewebkit.mk | 5 ++---
 2 files changed, 5 insertions(+), 6 deletions(-)
package/wpewebkit/Config.in +3 -3
index 7a8dc557c3..f1d38c7cad 100644
@@ -36,9 +36,9 @@ config BR2_PACKAGE_WPEWEBKIT
 	depends on !BR2_BINFMT_FLAT # icu
 	depends on BR2_HOST_GCC_AT_LEAST_4_9 # icu, host-ruby
 	depends on BR2_INSTALL_LIBSTDCPP # harfbuzz, icu
-	depends on BR2_TOOLCHAIN_HAS_THREADS # wayland, icu, libsoup
+	depends on BR2_TOOLCHAIN_HAS_THREADS # wayland, icu, libsoup3
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7
-	depends on BR2_USE_WCHAR # icu, libsoup
+	depends on BR2_USE_WCHAR # icu, libsoup3
 	depends on BR2_PACKAGE_HAS_LIBGLES # libepoxy
 	depends on BR2_PACKAGE_HAS_LIBEGL # libepoxy
 	depends on BR2_PACKAGE_HAS_LIBEGL_WAYLAND # wpebackend-fdo
@@ -51,7 +51,7 @@ config BR2_PACKAGE_WPEWEBKIT
 	select BR2_PACKAGE_LIBEPOXY
 	select BR2_PACKAGE_LIBGCRYPT
 	select BR2_PACKAGE_LIBPNG
-	select BR2_PACKAGE_LIBSOUP
+	select BR2_PACKAGE_LIBSOUP3
 	select BR2_PACKAGE_LIBTASN1
 	select BR2_PACKAGE_LIBXSLT
 	select BR2_PACKAGE_OPENJPEG
package/wpewebkit/wpewebkit.mk +2 -3
index c13a7201e6..8b5de00f07 100644
@@ -15,7 +15,7 @@ WPEWEBKIT_LICENSE_FILES = \
 WPEWEBKIT_CPE_ID_VENDOR = wpewebkit
 WPEWEBKIT_CPE_ID_PRODUCT = wpe_webkit
 WPEWEBKIT_DEPENDENCIES = host-gperf host-python3 host-ruby host-unifdef \
-	harfbuzz cairo icu jpeg libepoxy libgcrypt libgles libsoup libtasn1 \
+	harfbuzz cairo icu jpeg libepoxy libgcrypt libgles libsoup3 libtasn1 \
 	libpng libxslt openjpeg wayland-protocols webp wpebackend-fdo
 
 WPEWEBKIT_CONF_OPTS = \
@@ -26,8 +26,7 @@ WPEWEBKIT_CONF_OPTS = \
 	-DENABLE_INTROSPECTION=OFF \
 	-DENABLE_MINIBROWSER=OFF \
 	-DENABLE_WEB_RTC=OFF \
-	-DUSE_AVIF=OFF \
-	-DUSE_SOUP2=ON
+	-DUSE_AVIF=OFF
 
 ifeq ($(BR2_PACKAGE_WPEWEBKIT_SANDBOX),y)
 WPEWEBKIT_CONF_OPTS += \
Signature · 6 lines
2.34.1

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot