Adapt to new packaging

Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
This commit is contained in:
Igor Gnatenko 2019-02-17 18:40:15 +01:00
parent ed63637e45
commit 736d942daf
No known key found for this signature in database
GPG Key ID: 695714BD1BBC5F4C
2 changed files with 43 additions and 31 deletions

View File

@ -5,53 +5,72 @@
Name: rust-%{crate}
Version: 0.2.0
Release: 4%{?dist}
Release: 5%{?dist}
Summary: Rust command line tool that prints out a 6-digit random number
# Upstream license specification: GPL-3.0
License: GPLv3+
URL: https://crates.io/crates/yubibomb
Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate
Source: %{crates_source}
# Initial patched metadata
# * Bump regex to 1, https://gitlab.com/bowlofeggs/yubibomb/commit/301cb10cd056cd33c4736b87aaad333f77c6c252
Patch0: yubibomb-0.2.0-fix-metadata.diff
Patch0: yubibomb-fix-metadata.diff
ExclusiveArch: %{rust_arches}
BuildRequires: rust-packaging
# [dependencies]
BuildRequires: (crate(rand) >= 0.4.0 with crate(rand) < 0.5.0)
BuildRequires: (crate(rand/default) >= 0.4.0 with crate(rand/default) < 0.5.0)
%if %{with check}
# [dev-dependencies]
BuildRequires: (crate(regex) >= 1.0.0 with crate(regex) < 2.0.0)
BuildRequires: (crate(regex/default) >= 1.0.0 with crate(regex/default) < 2.0.0)
%endif
%description
%{summary}.
%global _description \
Don't you love when you accidentally tap your Yubikey when you have your IRC\
client in focus and you send 987947 into Freenode? Want to be able to have that\
experience without having to reach all the way over to your laptop's USB port?\
Now you can!
%description %{_description}
%package -n %{crate}
Summary: %{summary}
%description -n %{crate}
Don't you love when you accidentally tap your Yubikey when you have your IRC
client in focus and you send 987947 into Freenode? Want to be able to have that
experience without having to reach all the way over to your laptop's USB port?
Now you can!
%{summary}.
%files -n %{crate}
%license LICENSE
%doc README.md
%{_bindir}/yubibomb
%package devel
Summary: %{summary}
BuildArch: noarch
%description devel
Don't you love when you accidentally tap your Yubikey when you have your IRC
client in focus and you send 987947 into Freenode? Want to be able to have that
experience without having to reach all the way over to your laptop's USB port?
Now you can!
%description devel %{_description}
This package contains library source intended for building other packages
which use %{crate} from crates.io.
which use "%{crate}" crate.
%files devel
%license LICENSE
%doc README.md
%{cargo_registry}/%{crate}-%{version}/
%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 "default" feature of "%{crate}" crate.
%files -n %{name}+default-devel
%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml
%prep
%autosetup -n %{crate}-%{version} -p1
%autosetup -n %{crate}-%{version_no_tilde} -p1
%cargo_prep
%build
@ -65,17 +84,10 @@ which use %{crate} from crates.io.
%cargo_test
%endif
%files -n %{crate}
%license LICENSE
%doc README.md
%{_bindir}/yubibomb
%files devel
%license LICENSE
%doc README.md
%{cargo_registry}/%{crate}-%{version}/
%changelog
* Sun Feb 17 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.2.0-5
- Adapt to new packaging
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.2.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild

View File

@ -1,5 +1,5 @@
--- yubibomb-0.2.0/Cargo.toml 1970-01-01T01:00:00+01:00
+++ yubibomb-0.2.0/Cargo.toml 2018-06-14T09:15:13.966819+02:00
+++ yubibomb-0.2.0/Cargo.toml 2019-02-17T18:38:59.421864+01:00
@@ -24,4 +24,4 @@
[dependencies.rand]
version = "0.4"