File stardust-xr-armillary.spec of Package stardust-xr-armillary
%define _bin_name armillary
Name: stardust-xr-armillary
# This will be set by osc services, that will run after this.
Version: 0.50.0~0
Release: 0
Summary: Annotate things in Stardust XR
# If you know the license, put it's SPDX string here.
# Alternately, you can use cargo lock2rpmprovides to help generate this.
License: MIT
Url: https://github.com/StardustXR/armillary
Source0: %{_bin_name}-%{version}.tar.zst
Source1: vendor.tar.zst
# Pull in the latest rust/cargo toolchain
%if 0%{?suse_version}
BuildRequires: cargo
# This contains rpm macros to assist with building
BuildRequires: cargo-packaging
%else
BuildRequires: rust-srpm-macros
BuildRequires: cargo-rpm-macros
%endif
%description
%summary.
%prep
%autosetup -p1 -a1 -n %{_bin_name}-%{version}
%if 0%{?fedora}
%cargo_prep -v vendor
%endif
%build
%if 0%{?suse_version}
export CARGO_HOME=$PWD/.cargo
%endif
%{cargo_build}
%install
%if 0%{?suse_version}
export CARGO_HOME=$PWD/.cargo
%endif
%{cargo_install}
%check
%if 0%{?suse_version}
export CARGO_HOME=$PWD/.cargo
%endif
%{cargo_test}
%files
%license LICENSE
%{_bindir}/%{_bin_name}
%changelog