]> git.pld-linux.org Git - packages/AppStream.git/commitdiff
- added cxx patch (autodetect which g++ warning options are actually supported),...
authorJakub Bogusz <qboosh@pld-linux.org>
Fri, 17 Feb 2023 05:33:27 +0000 (06:33 +0100)
committerJakub Bogusz <qboosh@pld-linux.org>
Fri, 17 Feb 2023 05:33:27 +0000 (06:33 +0100)
AppStream-cxx.patch [new file with mode: 0644]
AppStream.spec

diff --git a/AppStream-cxx.patch b/AppStream-cxx.patch
new file mode 100644 (file)
index 0000000..d4a50b6
--- /dev/null
@@ -0,0 +1,32 @@
+--- AppStream-0.16.1/meson.build.orig  2023-02-10 20:54:13.000000000 +0100
++++ AppStream-0.16.1/meson.build       2023-02-16 15:37:15.221219224 +0100
+@@ -1,4 +1,4 @@
+-project('AppStream', 'c',
++project('AppStream', 'c', 'cpp',
+   meson_version: '>=0.62',
+   default_options: ['c_std=c11', 'cpp_std=gnu++14'],
+@@ -7,6 +7,7 @@ project('AppStream', 'c',
+ )
+ cc = meson.get_compiler('c')
++cxx = meson.get_compiler('cpp')
+ source_root = meson.project_source_root()
+ as_version = meson.project_version()
+@@ -123,6 +124,7 @@ add_project_arguments(
+   language: 'c'
+ )
+ add_project_arguments(
++  cxx.get_supported_arguments([
+   '-Wno-unused-parameter',
+   '-Werror=shadow',
+   '-Werror=empty-body',
+@@ -135,6 +137,7 @@ add_project_arguments(
+   # NOTE: Can be removed with AppStream 1.0
+   '-Wno-error=c++20-compat',
++  ]),
+   language: 'cpp'
+ )
index 273747408c3099552dd8ee3b6e56519a3229704b..3cb18c620d7b2305060e21f9d47ff80c3e1b8d0a 100644 (file)
@@ -15,28 +15,31 @@ License:    LGPL v2.1+
 Group:         Libraries
 Source0:       https://www.freedesktop.org/software/appstream/releases/%{name}-%{version}.tar.xz
 # Source0-md5: 1d7ff7d5073af49108590ab6df1d9931
+Patch0:                %{name}-cxx.patch
 URL:           https://www.freedesktop.org/wiki/Distributions/AppStream/
 BuildRequires: curl-devel >= 7.62
 %{?with_apidocs:BuildRequires: daps}
 BuildRequires: docbook-style-xsl-nons
 BuildRequires: gettext-tools
-BuildRequires: glib2-devel >= 1:2.58
+BuildRequires: glib2-devel >= 1:2.62
 BuildRequires: gobject-introspection-devel >= 1.56
 BuildRequires: gperf
 BuildRequires: libstdc++-devel >= 6:5
 BuildRequires: libstemmer-devel
 BuildRequires: libxml2-devel >= 2.0
+BuildRequires: libxmlb-devel >= 0.3.6
 BuildRequires: libxslt-progs
-# with .pc file
 BuildRequires: itstool
+# with .pc file
 BuildRequires: lmdb-devel >= 0.9.24-1
-BuildRequires: meson >= 0.48
+BuildRequires: meson >= 0.62
 BuildRequires: ninja >= 1.5
 BuildRequires: pkgconfig
 BuildRequires: python3 >= 1:3
 BuildRequires: rpm-build >= 4.6
 BuildRequires: rpmbuild(macros) >= 1.750
 BuildRequires: sed >= 4
+BuildRequires: systemd-devel >= 1:209
 BuildRequires: tar >= 1:1.22
 %{?with_vala:BuildRequires:    vala}
 BuildRequires: xmlto
@@ -53,11 +56,12 @@ BuildRequires:      cairo-devel >= 1.12
 BuildRequires: fontconfig-devel
 BuildRequires: freetype-devel >= 2
 BuildRequires: gdk-pixbuf2-devel >= 2.0
-BuildRequires: librsvg-devel >= 2.0
+BuildRequires: librsvg-devel >= 2.48
 BuildRequires: pango-devel
 %endif
 Requires:      curl-libs >= 7.62
-Requires:      glib2 >= 1:2.58
+Requires:      glib2 >= 1:2.62
+Requires:      libxmlb >= 0.3.6
 Obsoletes:     PackageKit-plugin-appstream < 0.7.4
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -74,7 +78,7 @@ Summary:      Header files for AppStream library
 Summary(pl.UTF-8):     Pliki nagłówkowe biblioteki AppStream
 Group:         Development/Libraries
 Requires:      %{name} = %{version}-%{release}
-Requires:      glib2-devel >= 1:2.58
+Requires:      glib2-devel >= 1:2.62
 
 %description devel
 Header files for AppStream library.
@@ -126,6 +130,7 @@ Summary(pl.UTF-8):  Biblioteka AppStreamCompose
 Group:         Libraries
 Requires:      %{name} = %{version}-%{release}
 Requires:      cairo >= 1.12
+Requires:      librsvg >= 2.48
 
 %description compose
 AppStreamCompose library contains helper functions to generate
@@ -212,10 +217,7 @@ Dane ITS AppStream metainfo dla narzędzi gettext.
 
 %prep
 %setup -q
-
-%if "%{_ver_lt '%{cc_version}' '9.0'}" == "1"
-%{__sed} -i -e "s/'-Wno-error=deprecated-copy', //" meson.build
-%endif
+%patch0 -p1
 
 %build
 %meson build \
@@ -237,7 +239,7 @@ rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT%{_docdir}
 %{__mv} $RPM_BUILD_ROOT%{_datadir}/gtk-doc $RPM_BUILD_ROOT%{_docdir}
 
-# unify
+# unify; bn_BD is more complete than bn
 %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/bn
 %{__mv} $RPM_BUILD_ROOT%{_localedir}/{bn_BD,bn}
 # not supported by glibc
@@ -297,6 +299,7 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %{_docdir}/appstream
 %{_gtkdocdir}/appstream
+%{_gtkdocdir}/appstream-compose
 %endif
 
 %if %{with compose}
This page took 0.356021 seconds and 4 git commands to generate.