File mingw32-libsoup.spec of Package mingw32-libsoup

#
# spec file for package mingw32-libsoup
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           mingw32-libsoup
Version:        2.74.3
Release:        0
Summary:        HTTP client/server library
License:        LGPL-2.1-or-later
Group:          Development/Libraries/C and C++
Url:            http://ftp.gnome.org/pub/GNOME/sources/libsoup
Source:         http://ftp.gnome.org/pub/gnome/sources/libsoup/2.74/libsoup-%{version}.tar.xz
# PATCH-FIX-OPENSUSE disable tls_interaction-test https://gitlab.gnome.org/GNOME/libsoup/issues/120
Patch1:         libsoup-skip-tls_interaction-test.patch
# PATCH-FIX-UPSTREAM libsoup2-extend-test-cert.patch boo#1102840 -- Fix tests after 2027
Patch2:         libsoup2-extend-test-cert.patch
# PATCH-FIX-UPSTREAM 4d12c3e5.patch -- lib: Add g_task_set_source_tag() everywhere
Patch3:         https://gitlab.gnome.org/GNOME/libsoup/-/commit/4d12c3e5.patch
# PATCH-FIX-UPSTREAM 48b3b611.patch -- lib: Add names to various GSources
Patch4:         https://gitlab.gnome.org/GNOME/libsoup/-/commit/48b3b611.patch
# PATCH-FIX-UPSTREAM ced3c5d8.patch -- Fix build with libxml2-2.12.0 and clang-17
Patch5:         https://gitlab.gnome.org/GNOME/libsoup/-/commit/ced3c5d8.patch
# PATCH-FIX-UPSTREAM 04df03bc.patch boo#1233285 mgorse@suse.com -- strictly don't allow NUL bytes in headers.
Patch6:         https://gitlab.gnome.org/GNOME/libsoup/-/commit/04df03bc.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2024-52532.patch boo#1233287 mgorse@suse.com -- process the frame as soon as we read data.
Patch7:         libsoup-CVE-2024-52532.patch
# PATCH-FIX-UPSTREAM 29b96fab.patch boo#1233287 mgorse@suse.com -- websocket-test: disconnect error copy after the test ends.
Patch8:         https://gitlab.gnome.org/GNOME/libsoup/-/commit/29b96fab.patch
# PATCH-FIX-UPSTREAM a35222dd.patch boo#1233292 mgorse@suse.com -- be more robust against invalid input when parsing params.
Patch9:         https://gitlab.gnome.org/GNOME/libsoup/-/commit/a35222dd.patch
# PATCH-FIX-UPSTREAM 4c9e75c6.patch boo#1233287 mgorse@suse.com -- fix an intermittent test failure.
Patch10:        https://gitlab.gnome.org/GNOME/libsoup/-/commit/4c9e75c6.patch
# PATCH-FIX-UPSTREAM ef6c4bf6.patch boo#1240750 mgorse@suse.com -- fix a potential overflow.
Patch11:        https://gitlab.gnome.org/GNOME/libsoup/-/commit/ef6c4bf6.patch
# PATCH-FIX-UPSTREAM 96c22b67.patch boo#1240750 mgorse@suse.com -- add better coverage of skip_insignificant_space.
Patch12:        https://gitlab.gnome.org/GNOME/libsoup/-/commit/96c22b67.patch
# PATCH-FIX-UPSTREAM 19124679.patch boo#1240752 mgorse@suse.com -- Fix using int instead of size_t for strcspn return.
Patch13:        https://gitlab.gnome.org/GNOME/libsoup/-/commit/19124679.patch
# PATCH-FIX-UPSTREAM a5b86bfc.patch boo#1240756 mgorse@suse.com -- fix heap buffer overflow in soup_content_sniffer_sniff.
Patch14:        https://gitlab.gnome.org/GNOME/libsoup/-/commit/a5b86bfc.patch
# PATCH-FIX-UPSTREAM 5739a090.patch boo#1240757 mgorse@suse.com -- fix heap buffer overflow in soup_content_sniffer.c:sniff_feed_or_html
Patch15:        https://gitlab.gnome.org/GNOME/libsoup/-/commit/5739a090.patch
# PATCH-FIX-UPSTREAM c9083869.patch boo#1241686 mgorse@suse.com -- fix leak in soup_header_parse_quality_list.
Patch16:        https://gitlab.gnome.org/GNOME/libsoup/-/commit/c9083869.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-32914.patch boo#1241164 mgorse@suse.com -- fix read out of buffer bounds under soup_multipart_new_from_message.
Patch17:        libsoup-CVE-2025-32914.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-32907.patch boo#1241222 mgorse@suse.com -- correct merge of ranges.
Patch18:        libsoup-CVE-2025-32907.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-46421.patch boo#1241688 mgorse@suse.com -- strip authentication credentials on cross-origin redirect.
Patch19:        libsoup-CVE-2025-46421.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-32913.patch boo#1241162 mgorse@suse.com -- fix NULL deref in soup_message_headers_get_content_disposition.
Patch20:        libsoup-CVE-2025-32913.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-32910.patch boo#1241252 mgorse@suse.com -- fix NULL deref with missing realm in authenticate header.
Patch21:        libsoup-CVE-2025-32910.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-32912.patch boo#1241214 mgorse@suse.com -- fix NULL pointer deref in SoupAuthDigest.
Patch22:        libsoup-CVE-2025-32912.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-32906.patch boo#1241263 mgorse@suse.com -- fix an out-of-bounds read parsing headers.
Patch23:        libsoup-CVE-2025-32906.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-32909.patch boo#1241226 mgorse@suse.com -- handle sniffing resource shorter than 4 bytes.
Patch24:        libsoup-CVE-2025-32909.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-4948.patch boo#1243332 mgorse@suse.com -- verify boundary limits for multipart body.
Patch25:        libsoup-CVE-2025-4948.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-4969.patch boo#1243423 mgorse@suse.com -- soup-multipart: Verify array bounds before accessing its members.
Patch26:        libsoup-CVE-2025-4969.patch
# PATCH-FIX-UPSTREAM libsoup-CVE-2025-4945.patch boo#1243314 mgorse@suse.com -- add value checks for date/time parsing.
Patch27:        libsoup-CVE-2025-4945.patch

#!BuildIgnore: post-build-checks
BuildRequires:  mingw32-glib-networking
BuildRequires:  mingw32-cross-meson
BuildRequires:  glib2-devel
BuildRequires:  intltool
BuildRequires:  mingw32-cross-binutils
BuildRequires:  mingw32-cross-gcc
BuildRequires:  mingw32-cross-pkg-config
BuildRequires:  mingw32-filesystem
BuildRequires:  mingw32-glib2-devel
BuildRequires:  mingw32-libpsl-devel
BuildRequires:  mingw32-libxml2-devel
BuildRequires:  mingw32-sqlite-devel
BuildRequires:  mingw32-brotli-devel
BuildRequires:  python3
BuildRequires:  xz
%_mingw32_package_header_debug
BuildArch:      noarch

%description
libsoup is an HTTP client/server library for GNOME. It uses GObjects and the glib main loop, to integrate well with
GNOME applications, and also has a synchronous API, for use in threaded applications.

%package -n mingw32-libsoup-2_4-1
Summary:        HTTP client/server library
Group:          System/Libraries
Obsoletes:      %{name}
Provides:       %{name}

%description -n mingw32-libsoup-2_4-1
libsoup is an HTTP client/server library for GNOME. It uses GObjects and the glib main loop, to integrate well with
GNOME applications, and also has a synchronous API, for use in threaded applications.

%package devel
Summary:        HTTP client/server library (development files)
Group:          Development/Libraries/C and C++

%description devel
libsoup is an HTTP client/server library for GNOME. It uses GObjects and the glib main loop, to integrate well with
GNOME applications, and also has a synchronous API, for use in threaded applications.
This package allows you to develop applications that use the libsoup library.

%package -n mingw32-libsoup-gnome-2_4-1
Summary:        HTTP client/server library (gnome files)
Group:          System/Libraries
Obsoletes:      %{name}-gnome
Provides:       %{name}-gnome

%description -n mingw32-libsoup-gnome-2_4-1
libsoup is an HTTP client/server library for GNOME. It uses GObjects and the glib main loop, to integrate well with
GNOME applications, and also has a synchronous API, for use in threaded applications.
This package contains gnome library.

%package gnome-devel
Summary:        HTTP client/server library (gnome development files)
Group:          Development/Libraries/C and C++

%description gnome-devel
libsoup is an HTTP client/server library for GNOME. It uses GObjects and the glib main loop, to integrate well with
GNOME applications, and also has a synchronous API, for use in threaded applications.
This package allows you to develop applications that use the libsoup gnome library.

%_mingw32_debug_package

%lang_package

%prep
%autosetup -p1 -n libsoup-%{version}

%build
%_mingw32_cross_wine_init
%_mingw32_meson \
    -Dgssapi=disabled \
    -Dvapi=disabled \
    -Dntlm=disabled \
    -Dsysprof=disabled \
    -Dintrospection=disabled \
    %{nil}
%_mingw32_meson_build

%install
%_mingw32_meson_install

%find_lang libsoup

%files -n mingw32-libsoup-2_4-1
%defattr(-,root,root)
%{_mingw32_bindir}/libsoup-2.4-1.dll

%files -n mingw32-libsoup-gnome-2_4-1
%defattr(-,root,root)
%{_mingw32_bindir}/libsoup-gnome-2.4-1.dll

%files devel
%defattr(-,root,root)
%{_mingw32_includedir}/libsoup-2.4/libsoup
%{_mingw32_libdir}/libsoup-2.4.dll.a
%{_mingw32_libdir}/pkgconfig/libsoup-2.4.pc

%files gnome-devel
%defattr(-,root,root)
%{_mingw32_includedir}/libsoup-gnome-2.4/libsoup
%{_mingw32_libdir}/libsoup-gnome-2.4.dll.a
%{_mingw32_libdir}/pkgconfig/libsoup-gnome-2.4.pc

%files lang -f libsoup.lang
%defattr(-,root,root)

%changelog
openSUSE Build Service is sponsored by