Blame rust-atomicwrites.spec

2b8f928
# Generated by rust2rpm
469ccd7
%bcond_with check
2b8f928
%global debug_package %{nil}
2b8f928
2b8f928
%global crate atomicwrites
2b8f928
2b8f928
Name:           rust-%{crate}
2b8f928
Version:        0.2.2
469ccd7
Release:        2%{?dist}
2b8f928
Summary:        Atomic file-writes
2b8f928
2b8f928
License:        MIT
2b8f928
URL:            https://crates.io/crates/atomicwrites
2b8f928
Source:         %{crates_source}
2b8f928
# Initial patched metadata
2b8f928
# - Remove Windows-only dependencies
2b8f928
# - Bump nix to 0.13.0 https://github.com/untitaker/rust-atomicwrites/pull/29
2b8f928
Patch0:         atomicwrites-fix-metadata.diff
2b8f928
2b8f928
ExclusiveArch:  %{rust_arches}
2b8f928
2b8f928
BuildRequires:  rust-packaging
2b8f928
BuildRequires:  (crate(nix/default) >= 0.13.0 with crate(nix/default) < 0.14.0)
2b8f928
BuildRequires:  (crate(tempdir/default) >= 0.3.0 with crate(tempdir/default) < 0.4.0)
2b8f928
2b8f928
%global _description \
2b8f928
Atomic file-writes.\
2b8f928
\
2b8f928
The basic idea is to write to temporary files, and move them when done writing.\
2b8f928
This avoids the problem of two programs writing to the same file. For\
2b8f928
AllowOverwrite, rename is used. For DisallowOverwrite, link + unlink is used\
2b8f928
instead to raise errors when the target path already exists.
2b8f928
2b8f928
%description %{_description}
2b8f928
2b8f928
%package        devel
2b8f928
Summary:        %{summary}
2b8f928
BuildArch:      noarch
2b8f928
2b8f928
%description    devel %{_description}
2b8f928
2b8f928
This package contains library source intended for building other packages
2b8f928
which use "%{crate}" crate.
2b8f928
2b8f928
%files          devel
2b8f928
%doc README.md
2b8f928
%license LICENSE
2b8f928
%{cargo_registry}/%{crate}-%{version}/
2b8f928
2b8f928
%package     -n %{name}+default-devel
2b8f928
Summary:        %{summary}
2b8f928
BuildArch:      noarch
2b8f928
2b8f928
%description -n %{name}+default-devel %{_description}
2b8f928
2b8f928
This package contains library source intended for building other packages
2b8f928
which use "default" feature of "%{crate}" crate.
2b8f928
2b8f928
%files       -n %{name}+default-devel
2b8f928
%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml
2b8f928
2b8f928
%prep
2b8f928
%autosetup -n %{crate}-%{version_no_tilde} -p1
2b8f928
%cargo_prep
2b8f928
2b8f928
%build
2b8f928
%cargo_build
2b8f928
2b8f928
%install
2b8f928
%cargo_install
2b8f928
2b8f928
%if %{with check}
2b8f928
%check
2b8f928
%cargo_test
2b8f928
%endif
2b8f928
2b8f928
%changelog
469ccd7
* Tue Apr 23 15:02:56 CEST 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.2.2-2
469ccd7
- Run tests in infrastructure
469ccd7
2b8f928
* Sat Apr 13 2019 Robert-André Mauchin <zebob.m@gmail.com> - 0.2.2-1
2b8f928
- Initial package