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.
rust-nix/rust-nix.spec

109 lines
3.3 KiB

# Generated by rust2rpm
%bcond_without check
%global debug_package %{nil}
%global crate nix
Name: rust-%{crate}
Version: 0.11.0
Release: 2%{?dist}
Summary: Rust friendly bindings to *nix APIs
License: MIT
URL: https://crates.io/crates/nix
Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate
# Initial patched metadata
# * No dragonfly/freebsd
# * Bump tempfile to 3, https://github.com/nix-rust/nix/pull/900
Patch0: nix-0.11.0-fix-metadata.diff
# Make it work with new tempdir
Patch0001: 0001-deps-update-tempfile-to-3.patch
ExclusiveArch: %{rust_arches}
BuildRequires: rust-packaging
# [dependencies]
BuildRequires: (crate(bitflags) >= 1.0.0 with crate(bitflags) < 2.0.0)
BuildRequires: (crate(cfg-if) >= 0.1.0 with crate(cfg-if) < 0.2.0)
BuildRequires: (crate(libc) >= 0.2.42 with crate(libc) < 0.3.0)
BuildRequires: (crate(void) >= 1.0.2 with crate(void) < 2.0.0)
%if %{with check}
# [dev-dependencies]
BuildRequires: (crate(bytes) >= 0.4.8 with crate(bytes) < 0.5.0)
BuildRequires: (crate(lazy_static) >= 1.0.0 with crate(lazy_static) < 2.0.0)
BuildRequires: (crate(rand) >= 0.4.0 with crate(rand) < 0.5.0)
BuildRequires: (crate(tempfile) >= 3.0.0 with crate(tempfile) < 4.0.0)
%endif
%description
%{summary}.
%package devel
Summary: %{summary}
BuildArch: noarch
%description devel
Rust friendly bindings to *nix APIs.
This package contains library source intended for building other packages
which use %{crate} from crates.io.
%prep
%autosetup -n %{crate}-%{version} -p1
%cargo_prep
%build
%cargo_build
%install
%cargo_install
%if %{with check}
%check
# Testing parts are not distributed
%cargo_test -- --doc
%endif
%files devel
%license LICENSE
%doc CHANGELOG.md CONTRIBUTING.md CONVENTIONS.md README.md
%{cargo_registry}/%{crate}-%{version}/
%exclude %{cargo_registry}/%{crate}-%{version}/{Cross.toml,RELEASE_PROCEDURE.md,bors.toml,ci}
%changelog
* Sat Jul 28 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.11.0-2
- Rebuild to trigger tests
* Tue Jul 17 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.11.0-1
- Update to 0.11.0
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.10.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Sat Jun 23 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.10.0-4
- Adopt to new macro
* Fri May 11 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.10.0-3
- Bump tempfile to 3
* Thu Mar 08 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.10.0-2
- Re-apply statvfs patch
* Thu Mar 08 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.10.0-1
- Update to 0.10.0
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.9.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
* Mon Jan 08 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.9.0-4
- Rebuild for rust-packaging v5
* Mon Jan 08 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.9.0-3
- Implement statfs/statvfs on altarches
* Mon Jan 01 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.9.0-2
- Bump rand to 0.4
* Sun Dec 03 2017 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.9.0-1
- Initial package