File angelfish.spec of Package angelfish

# spec file for angelfish
#
# Copyright (c) 2021 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.

%global rustflags '-Clink-arg=-Wl,-z,relro,-z,now'

Name:           angelfish
Version:        22.04
Release:        0
License:        GPL-2.0-or-later AND LGPL-2.0-only AND LGPL-2.0-or-later AND MIT
Summary:        Mobile friendly web browser 
Url:            https://apps.kde.org/en/mobile.angelfish
Source0:        %{name}-%{version}.tar.xz
Source1:        vendor.tar.xz
Source2:        cargo_config
BuildRequires:  gcc
BuildRequires:  gcc-c++
BuildRequires:  cmake
BuildRequires:  fdupes
BuildRequires:  AppStream
BuildRequires:  extra-cmake-modules
BuildRequires:  hicolor-icon-theme
BuildRequires:  update-desktop-files
BuildRequires:  cmake(KF5I18n)
BuildRequires:  cmake(KF5Config)
BuildRequires:  cmake(KF5CoreAddons)
BuildRequires:  cmake(KF5Notifications)
BuildRequires:  cmake(KF5Kirigami2)
BuildRequires:  cmake(KF5DBusAddons)
BuildRequires:  cmake(KF5Purpose)
BuildRequires:  cmake(KF5WindowSystem)
BuildRequires:  cmake(Qt5Svg)
BuildRequires:  cmake(Qt5WebEngine)
BuildRequires:  cmake(Qt5Sql)
BuildRequires:  cmake(Qt5QuickControls2)
BuildRequires:  cmake(Qt5Feedback)
BuildRequires:  cargo
BuildRequires:  rust-packaging
BuildRequires:  corrosion
Provides:       plasma-angelfish = %{version}
Obsoletes:      plasma-angelfish < %{version}
#BuildRequires:  cmake(Corrosion)

Requires:       kirigami2

BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
Angelfish is a modern mobile web browser. It supports typical browser
features, such as bookmarks, history and tabs.

%prep
%setup -q -n %{name}-%{version}
%setup -DTqa1
mkdir .cargo
cp %{SOURCE2} .cargo/config

%build
export RUSTFLAGS=%{rustflags}
%cmake_kf5 -d build
%cmake_build

%install
%kf5_makeinstall -C build
%kf5_post_install
%fdupes %{buildroot}%{_prefix}

%files
%defattr(-,root,root,-)
%doc README.md
%license LICENSES/{GPL-2.0-or-later,LGPL-2.0-only,LGPL-2.0-or-later,MIT}.txt
%{_kf5_bindir}/%{name}
%{_kf5_bindir}/%{name}-webapp
%{_kf5_applicationsdir}/*.desktop
%{_kf5_sharedir}/config.kcfg/*.kcfg
%{_kf5_iconsdir}/hicolor/*/*/*.svg
%{_kf5_appstreamdir}/*.metainfo.xml
%{_kf5_notifydir}/*.notifyrc

%changelog
openSUSE Build Service is sponsored by