File elementary-appcenter.spec of Package elementary-appcenter
#
# spec file for package elementary-appcenter
#
# 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: elementary-appcenter
Version: 0.2.9
Release: 0
Summary: Browse and manage apps
License: GPL-3.0
Group: System/GUI/Other
URL: https://elementary.io/
Source: https://github.com/elementary/appcenter/archive/%{version}.tar.gz#/appcenter-%{version}.tar.gz
# PATCH-FIX-UPSTREAM -- Fix vala compiler errors (#663)
Patch0: appcenter-0.2.9-vala-0.4.patch
BuildRequires: cmake
BuildRequires: elementary-cmake-modules
BuildRequires: fdupes
BuildRequires: gcc-c++
BuildRequires: intltool
BuildRequires: libxml2-tools
BuildRequires: pkgconfig
BuildRequires: update-desktop-files
BuildRequires: pkgconfig(appstream) >= 0.10.3
BuildRequires: pkgconfig(appstream-glib)
BuildRequires: pkgconfig(gee-0.8)
BuildRequires: pkgconfig(gio-2.0) >= 2.46
BuildRequires: pkgconfig(granite)
BuildRequires: pkgconfig(gthread-2.0)
BuildRequires: pkgconfig(gtk+-3.0) >= 3.10
BuildRequires: pkgconfig(json-glib-1.0)
BuildRequires: pkgconfig(libsoup-2.4)
BuildRequires: pkgconfig(packagekit-glib2)
BuildRequires: pkgconfig(vapigen) >= 0.28
Recommends: %{name}-lang
Recommends: libzypp-plugin-appdata
Provides: appcenter = %{version}
Obsoletes: appcenter < %{version}
%description
AppCenter is a native Gtk+ app store built on AppStream and Packagekit.
%lang_package
%prep
%setup -q -n appcenter-%{version}
%patch0 -p2
sed -i 's/\bmetainfo\b/appdata/' $(grep -rwl 'metainfo')
# Use the system logo
sed -i 's/\(distributor\)-logo/\1/' $(grep -rwl distributor-logo)
%build
%cmake -DGSETTINGS_COMPILE=FALSE -DUSE_UNITY=FALSE
make %{?_smp_mflags}
%install
%cmake_install
%suse_update_desktop_file -r -G AppCenter io.elementary.appcenter GTK System PackageManager
%find_lang io.elementary.appcenter %{name}.lang
%fdupes %{buildroot}%{_datadir}
%post
%glib2_gsettings_schema_post
%desktop_database_post
%postun
%glib2_gsettings_schema_postun
%desktop_database_postun
%files
%doc AUTHORS COPYING
%{_bindir}/io.elementary.appcenter
%{_datadir}/appdata/io.elementary.appcenter.appdata.xml
%{_datadir}/applications/io.elementary.appcenter*.desktop
%{_datadir}/dbus-1/services/io.elementary.appcenter.service
%{_datadir}/glib-2.0/schemas/io.elementary.appcenter.gschema.xml
%dir %{_sysconfdir}/io.elementary.appcenter
%config %{_sysconfdir}/io.elementary.appcenter/appcenter.blacklist
%files lang -f %{name}.lang
%changelog