[packages/AppStream] - updated to 0.8.0; now defaults to qt5
qboosh
qboosh at pld-linux.org
Thu Jan 29 21:03:13 CET 2015
commit 112490e9742630f9a2ffe7e6e05d14f88484eac9
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Thu Jan 29 21:05:13 2015 +0100
- updated to 0.8.0; now defaults to qt5
AppStream.spec | 36 ++++++++++++++++++++++++++++--------
1 file changed, 28 insertions(+), 8 deletions(-)
---
diff --git a/AppStream.spec b/AppStream.spec
index 3cf1bc5..1e46818 100644
--- a/AppStream.spec
+++ b/AppStream.spec
@@ -1,22 +1,21 @@
-# TODO: qt5 support (on bcond? devel package not parallel installable with qt4, only soname differs)
#
# Conditional build:
%bcond_without apidocs # API documentation build
%bcond_without qt # Qt library (libappstream-qt)
+%bcond_with qt4 # Qt 4.x instead of Qt 5 (note: devel supports only single package at a time)
%bcond_without vala # Vala API (VAPI)
#
Summary: AppStream-Core library and tools
Summary(pl.UTF-8): Biblioteka i narzędzia AppStream-Core
Name: AppStream
-Version: 0.7.6
+Version: 0.8.0
Release: 1
License: LGPL v2.1+
Group: Libraries
Source0: http://www.freedesktop.org/software/appstream/releases/%{name}-%{version}.tar.xz
-# Source0-md5: 613d1cef643846f165137ffeed5bf541
+# Source0-md5: 9efd0d73f7b0b9391c862cb925b729cf
Patch0: %{name}-cmake.patch
URL: http://www.freedesktop.org/wiki/Distributions/AppStream/Software/
-%{?with_qt:BuildRequires: QtCore-devel >= 4.8.0}
BuildRequires: cmake >= 2.8.12
BuildRequires: gettext-tools
BuildRequires: glib2-devel >= 1:2.36
@@ -25,12 +24,20 @@ BuildRequires: intltool
BuildRequires: libstdc++-devel
BuildRequires: libxml2-devel >= 2.0
BuildRequires: pkgconfig
-%{?with_qt:BuildRequires: qt4-qmake >= 4.8.0}
BuildRequires: tar >= 1:1.22
%{?with_vala:BuildRequires: vala}
BuildRequires: xapian-core-devel >= 1.2
BuildRequires: xz
BuildRequires: yaml-devel >= 0.1
+%if %{with qt}
+%if %{with qt4}
+BuildRequires: QtCore-devel >= 4.8.0
+BuildRequires: qt4-qmake >= 4.8.0
+%else
+BuildRequires: Qt5Core-devel >= 5.0
+BuildRequires: qt5-qmake >= 5.0
+%endif
+%endif
%if %{with apidocs}
BuildRequires: gtk-doc
BuildRequires: publican
@@ -77,7 +84,11 @@ Dokumentacja API biblioteki AppStream.
Summary: AppstreamQt library
Summary(pl.UTF-8): Biblioteka AppstreamQt
Group: Libraries
+%if %{with qt4}
Requires: QtCore >= 4.8.0
+%else
+Requires: Qt5Core >= 5.0
+%endif
Requires: xapian-core-libs >= 1.2
%description qt
@@ -91,7 +102,11 @@ Summary: Header files for AppstreamQt library
Summary(pl.UTF-8): Pliki nagłówkowe biblioteki AppstreamQt
Group: Libraries
Requires: %{name}-qt = %{version}-%{release}
+%if %{with qt4}
Requires: QtCore-devel >= 4.8.0
+%else
+Requires: Qt5Core-devel >= 5.0
+%endif
%description qt-devel
Header files for AppstreamQt library.
@@ -121,7 +136,7 @@ install -d build
cd build
%cmake .. \
%{?with_apidocs:-DDOCUMENTATION=ON} \
- %{?with_qt:-DQT=ON} \
+ %{?with_qt:-DQT=ON %{?with_qt4:-DAPPSTREAM_QT_VERSION=4}} \
%{?with_vala:-DVAPI=ON}
%{__make} -j1
@@ -153,7 +168,7 @@ rm -rf $RPM_BUILD_ROOT
%attr(755,root,root) %{_bindir}/appstream-validate
%attr(755,root,root) %{_libdir}/libappstream.so.*.*.*
%attr(755,root,root) %ghost %{_libdir}/libappstream.so.2
-%{_libdir}/girepository-1.0/AppStream-0.7.typelib
+%{_libdir}/girepository-1.0/AppStream-0.8.typelib
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/appstream.conf
%dir %{_datadir}/app-info
%{_datadir}/app-info/categories.xml
@@ -163,13 +178,14 @@ rm -rf $RPM_BUILD_ROOT
%files devel
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/libappstream.so
-%{_datadir}/gir-1.0/AppStream-0.7.gir
+%{_datadir}/gir-1.0/AppStream-0.8.gir
%{_includedir}/AppStream
%{_pkgconfigdir}/appstream.pc
%if %{with apidocs}
%files apidocs
%defattr(644,root,root,755)
+%{_docdir}/appstream
%{_gtkdocdir}/appstream
%endif
@@ -177,7 +193,11 @@ rm -rf $RPM_BUILD_ROOT
%files qt
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/libAppstreamQt.so.*.*.*
+%if %{with qt4}
%attr(755,root,root) %ghost %{_libdir}/libAppstreamQt.so.0
+%else
+%attr(755,root,root) %ghost %{_libdir}/libAppstreamQt.so.1
+%endif
%files qt-devel
%defattr(644,root,root,755)
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/AppStream.git/commitdiff/112490e9742630f9a2ffe7e6e05d14f88484eac9
More information about the pld-cvs-commit
mailing list