# Generated by rust2rpm 26 %bcond_without check # prevent library files from being installed %global cargo_install_lib 0 Name: boxbuddy-rs Version: 2.2.5 %global _basename BoxBuddyRS %global app_id io.github.dvlv.boxbuddyrs %global forgeurl https://github.com/Dvlv/%{_basename} %global tag %{version} %global date 20240611 %forgemeta Release: %autorelease Summary: A Graphical Interface for Distrobox License: MIT # LICENSE.dependencies contains a full license breakdown URL: %{forgeurl} Source: %{forgesource} BuildRequires: cargo-rpm-macros >= 26 BuildRequires: desktop-file-utils BuildRequires: libappstream-glib Requires: distrobox Requires: libadwaita %global _description %{expand: %{summary}.} %description %{_description} %prep %autosetup -n %{_basename}-%{version} -p1 %cargo_prep %generate_buildrequires %cargo_generate_buildrequires %build %cargo_build %{cargo_license_summary} %{cargo_license} > LICENSE.dependencies %install %cargo_install install -Dm644 %{app_id}.desktop -t %{buildroot}%{_datadir}/applications/ install -Dm644 %{app_id}.gschema.xml -t %{buildroot}%{_datadir}/glib-2.0/schemas/ install -Dm644 %{app_id}.metainfo.xml -t %{buildroot}%{_metainfodir}/ install -Dm644 icons/%{app_id}.svg -t %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/ install -Dm644 icons/build-alt-{symbolic,symbolic-light}.svg -t %{buildroot}%{_datadir}/icons/hicolor/symbolic/apps/ for lang in de_DE el es hi it_IT pt_BR ru_RU uk_UA zh_CN; do install -Dm644 "po/${lang}/LC_MESSAGES/boxbuddyrs.mo" -t \ %{buildroot}%{_datadir}/locale/${lang}/LC_MESSAGES/ done %if %{with check} %check %cargo_test desktop-file-validate %{buildroot}%{_datadir}/applications/%{app_id}.desktop appstream-util validate-relax --nonet %{buildroot}%{_metainfodir}/%{app_id}.metainfo.xml %endif %files %license LICENSE %license LICENSE.dependencies %doc README.md %{_bindir}/%{name} %{_datadir}/applications/%{app_id}.desktop %{_datadir}/glib-2.0/schemas/%{app_id}.gschema.xml %{_metainfodir}/%{app_id}.metainfo.xml %{_datadir}/icons/hicolor/scalable/apps/%{app_id}.svg %{_datadir}/icons/hicolor/symbolic/apps/build-alt-{symbolic,symbolic-light}.svg %{_datadir}/locale/*/LC_MESSAGES/boxbuddyrs.mo %changelog %autochangelog