You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
85 lines
1.8 KiB
85 lines
1.8 KiB
3 years ago
|
# Generated by rust2rpm 21
|
||
|
%bcond_without check
|
||
|
|
||
|
%global crate nu-utils
|
||
|
|
||
|
Name: rust-%{crate}
|
||
|
Version: 0.60.0
|
||
|
Release: %autorelease
|
||
|
Summary: Nushell utility functions
|
||
|
|
||
|
# Upstream license specification: MIT
|
||
|
License: MIT
|
||
|
URL: https://crates.io/crates/nu-utils
|
||
|
Source0: %{crates_source}
|
||
|
# license text not included yet in most crates
|
||
|
# see https://github.com/nushell/nushell/pull/5094
|
||
|
Source1: https://raw.githubusercontent.com/nushell/nushell/main/LICENSE#/%{crate}-LICENSE
|
||
|
# Drop Windows dependencies
|
||
|
Patch0: nu-utils-fix-metadata.diff
|
||
|
|
||
|
ExclusiveArch: %{rust_arches}
|
||
|
|
||
|
BuildRequires: rust-packaging >= 21
|
||
|
|
||
|
%global _description %{expand:
|
||
|
Nushell utility functions.}
|
||
|
|
||
|
%description %{_description}
|
||
|
|
||
|
%package -n %{crate}
|
||
|
Summary: %{summary}
|
||
|
|
||
|
%description -n %{crate} %{_description}
|
||
|
|
||
|
%files -n %{crate}
|
||
|
%license LICENSE
|
||
|
%{_bindir}/utils
|
||
|
|
||
|
%package devel
|
||
|
Summary: %{summary}
|
||
|
BuildArch: noarch
|
||
|
|
||
|
%description devel %{_description}
|
||
|
|
||
|
This package contains library source intended for building other packages which
|
||
|
use the "%{crate}" crate.
|
||
|
|
||
|
%files devel
|
||
|
%license LICENSE
|
||
|
%{crate_instdir}/
|
||
|
|
||
|
%package -n %{name}+default-devel
|
||
|
Summary: %{summary}
|
||
|
BuildArch: noarch
|
||
|
|
||
|
%description -n %{name}+default-devel %{_description}
|
||
|
|
||
|
This package contains library source intended for building other packages which
|
||
|
use the "default" feature of the "%{crate}" crate.
|
||
|
|
||
|
%files -n %{name}+default-devel
|
||
|
%ghost %{crate_instdir}/Cargo.toml
|
||
|
|
||
|
%prep
|
||
|
%autosetup -n %{crate}-%{version_no_tilde} -p1
|
||
|
cp -p %{SOURCE1} LICENSE
|
||
|
%cargo_prep
|
||
|
|
||
|
%generate_buildrequires
|
||
|
%cargo_generate_buildrequires
|
||
|
|
||
|
%build
|
||
|
%cargo_build
|
||
|
|
||
|
%install
|
||
|
%cargo_install
|
||
|
|
||
|
%if %{with check}
|
||
|
%check
|
||
|
%cargo_test
|
||
|
%endif
|
||
|
|
||
|
%changelog
|
||
|
%autochangelog
|