diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c945b77 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/news_flash_gtk-1.0-rc1.tar.gz diff --git a/newsflash.spec b/newsflash.spec new file mode 100644 index 0000000..6216d4a --- /dev/null +++ b/newsflash.spec @@ -0,0 +1,79 @@ +%global __cargo_skip_build 0 + +Name: newsflash +Version: 1.0~rc1 +Release: 1%{?dist} +Summary: Modern feed reader + +# (MIT or ASL 2.0) and BSD +# ASL 2.0 +# ASL 2.0 or Boost +# ASL 2.0 or MIT or MPLv2.0 +# BSD +# GPLv3+ +# MIT +# MIT or ASL 2.0 +# Unlicense +# Unlicense or MIT +# zlib +License: GPLv3+ and BSD and ASL 2.0 and MIT and Unlicense and zlib +URL: https://gitlab.com/news-flash/news_flash_gtk +Source0: https://gitlab.com/news-flash/news_flash_gtk/-/archive/%{version_no_tilde}/news_flash_gtk-%{version_no_tilde}.tar.gz + +ExclusiveArch: %{rust_arches} + +BuildRequires: rust-packaging +BuildRequires: meson +BuildRequires: /usr/bin/appstream-util +BuildRequires: /usr/bin/desktop-file-validate + +%description +A modern feed reader designed for the GNOME desktop. NewsFlash is a program +designed to complement an already existing web-based RSS reader account. + +It combines all the advantages of web based services like syncing across all +your devices with everything you expect from a modern desktop program: +Desktop notifications, fast search and filtering, tagging, handy keyboard +shortcuts and having access to all your articles as long as you like. + +%prep +%autosetup -n news_flash_gtk-%{version_no_tilde} -p1 +# Use packaged crates with proper versions +sed -i \ + -e '/tokio/s/=0.2/0.2/' \ + -e 's/news-flash = .*/news-flash = "1"/' \ + Cargo.toml +# We will build by cargo ourselves +sed -i -e '/\(build_by_default\|install\)/s/true/false/' src/meson.build +sed -i -e '/dependency/d' meson.build +%cargo_prep + +%generate_buildrequires +%cargo_generate_buildrequires + +%build +%meson +%meson_build +%cargo_build + +%install +%meson_install +%cargo_install +mv %{buildroot}%{_bindir}/{news_flash_gtk,com.gitlab.newsflash} + +%check +desktop-file-validate %{buildroot}%{_datadir}/applications/com.gitlab.newsflash.desktop +appstream-util validate-relax --nonet %{buildroot}%{_datadir}/metainfo/com.gitlab.newsflash.appdata.xml + +%files +%license LICENSE +%doc README.md +%{_bindir}/com.gitlab.newsflash +%{_datadir}/applications/com.gitlab.newsflash.desktop +%{_datadir}/dbus-1/services/com.gitlab.newsflash.service +%{_datadir}/icons/hicolor/*/apps/com.gitlab.newsflash* +%{_datadir}/metainfo/com.gitlab.newsflash.appdata.xml + +%changelog +* Sun Jun 07 2020 Igor Raits - 1.0~rc1-1 +- Initial package diff --git a/sources b/sources new file mode 100644 index 0000000..4676106 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (news_flash_gtk-1.0-rc1.tar.gz) = ad039ebe2856a348bff4a9ce02a4ab48eb4ffb5543acf213e504d977a4ca96156af0d7db58167626813c7626be34c2b27aab9f86f9114ef49fc168ab60a1f55e