Accepting request 1002704 from GNOME:Next
GNOME 43.rc - let's get this into Staging to see what we break (e.g meson:test seems to be an issue already) OBS-URL: https://build.opensuse.org/request/show/1002704 OBS-URL: https://build.opensuse.org/package/show/hardware/libosinfo?expand=0&rev=105
This commit is contained in:
parent
8d30438e55
commit
eba19b9dbe
58
3a0fef72.patch
Normal file
58
3a0fef72.patch
Normal file
@ -0,0 +1,58 @@
|
||||
From 3a0fef72b11e2a22cac61a93a5b5b796885ac7e7 Mon Sep 17 00:00:00 2001
|
||||
From: Matt Turner <mattst88@gmail.com>
|
||||
Date: Tue, 15 Feb 2022 12:22:00 -0800
|
||||
Subject: [PATCH] build: Add option to select libsoup ABI
|
||||
|
||||
This allows distributions that ship both versions of libsoup and choose
|
||||
which version of libsoup will be linked.
|
||||
|
||||
Signed-off-by: Matt Turner <mattst88@gmail.com>
|
||||
---
|
||||
meson.build | 11 ++++++++---
|
||||
meson_options.txt | 7 +++++++
|
||||
2 files changed, 15 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index a6644025..037e4f33 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -71,10 +71,15 @@ gio_dep = dependency('gio-2.0', version: glib_version_info)
|
||||
gobject_dep = dependency('gobject-2.0', version: glib_version_info)
|
||||
|
||||
# everything else
|
||||
-libsoup_dep = dependency('libsoup-3.0', required: false)
|
||||
-# fallback to libsoup2
|
||||
+
|
||||
+libsoup_abi = get_option('libsoup-abi')
|
||||
+libsoup_dep = disabler()
|
||||
+if ['auto', '3.0'].contains(libsoup_abi)
|
||||
+ libsoup_dep = dependency('libsoup-3.0', required: libsoup_abi.contains('3.0'))
|
||||
+endif
|
||||
if not libsoup_dep.found()
|
||||
- libsoup_dep = dependency('libsoup-2.4')
|
||||
+# fallback to libsoup2
|
||||
+ libsoup_dep = dependency('libsoup-2.4', required: libsoup_abi.contains('2.4'))
|
||||
endif
|
||||
libxml_dep = dependency('libxml-2.0', version: '>= 2.6.0')
|
||||
libxslt_dep = dependency('libxslt', version: '>= 1.0.0')
|
||||
diff --git a/meson_options.txt b/meson_options.txt
|
||||
index 13fc3583..15a361fd 100644
|
||||
--- a/meson_options.txt
|
||||
+++ b/meson_options.txt
|
||||
@@ -24,6 +24,13 @@ option('enable-vala',
|
||||
description: 'Enable Vala bindings'
|
||||
)
|
||||
|
||||
+option('libsoup-abi',
|
||||
+ type: 'combo',
|
||||
+ value: 'auto',
|
||||
+ choices: ['auto', '2.4', '3.0'],
|
||||
+ description: 'Select libsoup ABI version'
|
||||
+)
|
||||
+
|
||||
option('with-pci-ids-path',
|
||||
type: 'string',
|
||||
value: '',
|
||||
--
|
||||
GitLab
|
||||
|
@ -1,3 +1,12 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Aug 31 19:33:40 UTC 2022 - Bjørn Lie <bjorn.lie@gmail.com>
|
||||
|
||||
- Add 3a0fef72.patch: build: Add option to select libsoup ABI.
|
||||
Following this, add conditional pkgconfig(libsoup-3.0)
|
||||
BuildRequires.
|
||||
- Modernize spec, use ldconfig_scriptlets macro for post(un)
|
||||
handling, package COPYING with license macro.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Mar 1 10:49:08 MST 2022 - carnold@suse.com
|
||||
|
||||
|
@ -25,8 +25,11 @@ Release: 0
|
||||
Summary: Operating system and hypervisor information management library
|
||||
License: GPL-2.0-or-later AND LGPL-2.1-or-later
|
||||
Group: Development/Libraries/C and C++
|
||||
URL: https://releases.pagure.org/libosinfo/
|
||||
Source0: https://releases.pagure.org/libosinfo/%{name}-%{version}.tar.xz
|
||||
URL: https://releases.pagure.org/libosinfo
|
||||
Source0: %{url}/%{name}-%{version}.tar.xz
|
||||
# PATCH-FIX-UPSTREAM 3a0fef72.patch -- build: Add option to select libsoup ABI
|
||||
Patch0: https://gitlab.com/libosinfo/libosinfo/-/commit/3a0fef72.patch
|
||||
|
||||
BuildRequires: gtk-doc
|
||||
BuildRequires: hwdata
|
||||
BuildRequires: libcurl-devel
|
||||
@ -36,7 +39,11 @@ BuildRequires: pkgconfig(check)
|
||||
BuildRequires: pkgconfig(gio-2.0)
|
||||
BuildRequires: pkgconfig(gobject-2.0)
|
||||
BuildRequires: pkgconfig(gobject-introspection-1.0)
|
||||
%if 0%{suse_version} > 1550
|
||||
BuildRequires: pkgconfig(libsoup-3.0)
|
||||
%else
|
||||
BuildRequires: pkgconfig(libsoup-2.4)
|
||||
%endif
|
||||
BuildRequires: pkgconfig(libxml-2.0)
|
||||
BuildRequires: pkgconfig(libxslt) >= 1.0.0
|
||||
Requires: osinfo-db
|
||||
@ -87,7 +94,7 @@ as well as Vala bindings for the libosinfo library.
|
||||
%endif
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%autosetup -p1
|
||||
|
||||
%build
|
||||
%meson \
|
||||
@ -104,13 +111,11 @@ find %{buildroot} -type f -name "*.la" -delete -print
|
||||
%find_lang %{name} %{?no_lang_C}
|
||||
%endif
|
||||
|
||||
%post -n libosinfo-1_0-0 -p /sbin/ldconfig
|
||||
|
||||
%postun -n libosinfo-1_0-0 -p /sbin/ldconfig
|
||||
%ldconfig_scriptlets -n libosinfo-1_0-0
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%doc ChangeLog README COPYING
|
||||
%license COPYING
|
||||
%doc ChangeLog README
|
||||
%{_bindir}/osinfo-detect
|
||||
%{_bindir}/osinfo-install-script
|
||||
%{_bindir}/osinfo-query
|
||||
@ -119,21 +124,17 @@ find %{buildroot} -type f -name "*.la" -delete -print
|
||||
%{_mandir}/man1/osinfo-query.1%{?ext_man}
|
||||
|
||||
%files -n libosinfo-1_0-0
|
||||
%defattr(-, root, root)
|
||||
%{_libdir}/libosinfo-1.0.so.*
|
||||
|
||||
%files -n typelib-1_0-Libosinfo-1_0
|
||||
%defattr(-,root,root)
|
||||
%{_libdir}/girepository-1.0/Libosinfo-1.0.typelib
|
||||
|
||||
%files devel
|
||||
%defattr(-, root, root)
|
||||
%{_datadir}/gtk-doc/html/Libosinfo/
|
||||
%{_includedir}/%{name}-1.0
|
||||
%{_libdir}/pkgconfig/%{name}-1.0.pc
|
||||
%{_libdir}/libosinfo-1.0.so
|
||||
%{_datadir}/gir-1.0/Libosinfo-1.0.gir
|
||||
|
||||
%dir %{_datadir}/vala
|
||||
%dir %{_datadir}/vala/vapi
|
||||
%{_datadir}/vala/vapi/libosinfo-1.0.deps
|
||||
|
Loading…
Reference in New Issue
Block a user