Blob Blame History Raw
# Generated by rust2rpm-9-1.fc31
%bcond_with check
%global debug_package %{nil}

%global crate rmp-serde

Name:           rust-%{crate}
Version:        0.13.7
Release:        3%{?dist}
Summary:        Serde bindings for RMP

# Upstream license specification: MIT
# https://github.com/3Hren/msgpack-rust/issues/192
License:        MIT
URL:            https://crates.io/crates/rmp-serde
Source:         %{crates_source}
# Initial patched metadata
# * Update serde_bytes to 0.11, https://github.com/3Hren/msgpack-rust/pull/195
Patch0:         rmp-serde-fix-metadata.diff
# Make it work with new serde_bytes
Patch0001:      0001-chore-Update-serde_bytes-to-0.11.patch

ExclusiveArch:  %{rust_arches}

BuildRequires:  rust-packaging
BuildRequires:  (crate(byteorder/default) >= 1.0.0 with crate(byteorder/default) < 2.0.0)
BuildRequires:  (crate(rmp/default) >= 0.8.0 with crate(rmp/default) < 0.9.0)
BuildRequires:  (crate(serde/default) >= 1.0.0 with crate(serde/default) < 2.0.0)
%if %{with check}
BuildRequires:  (crate(serde_bytes/default) >= 0.11.0 with crate(serde_bytes/default) < 0.12.0)
BuildRequires:  (crate(serde_derive/default) >= 1.0.0 with crate(serde_derive/default) < 2.0.0)
%endif

%global _description \
Serde bindings for RMP.

%description %{_description}

%package        devel
Summary:        %{summary}
BuildArch:      noarch

%description    devel %{_description}

This package contains library source intended for building other packages
which use "%{crate}" crate.

%files          devel
%doc CHANGELOG.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_no_tilde} -p1
%cargo_prep

%build
%cargo_build

%install
%cargo_install

%if %{with check}
%check
%cargo_test
%endif

%changelog
* Sun May 12 08:53:53 CEST 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.13.7-3
- Update serde_bytes to 0.11

* Thu Apr 11 14:38:20 CEST 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.13.7-2
- Run tests in infrastructure

* Thu Mar 28 08:57:13 CET 2019 Robert-André Mauchin <zebob.m@gmail.com> - 0.13.7-1
- Initial package