Import package after review
This commit is contained in:
parent
3671296e24
commit
08de400d38
0
.gitignore
vendored
Normal file
0
.gitignore
vendored
Normal file
63
rust-zram-generator.spec
Normal file
63
rust-zram-generator.spec
Normal file
@ -0,0 +1,63 @@
|
||||
# Generated by rust2rpm
|
||||
%bcond_without check
|
||||
|
||||
%global crate zram-generator
|
||||
|
||||
Name: rust-%{crate}
|
||||
Version: 0.1.1
|
||||
Release: 1%{?dist}
|
||||
Summary: Systemd unit generator for zram devices
|
||||
|
||||
License: MIT
|
||||
URL: https://github.com/systemd/zram-generator
|
||||
Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate
|
||||
|
||||
ExclusiveArch: %{rust_arches}
|
||||
|
||||
BuildRequires: rust-packaging
|
||||
# [dependencies]
|
||||
BuildRequires: (crate(failure) >= 0.1.0 with crate(failure) < 0.2.0)
|
||||
BuildRequires: (crate(failure_derive) >= 0.1.0 with crate(failure_derive) < 0.2.0)
|
||||
BuildRequires: (crate(rust-ini) >= 0.12.0 with crate(rust-ini) < 0.13.0)
|
||||
|
||||
BuildRequires: systemd
|
||||
|
||||
%description
|
||||
This is a systemd unit generator that creates a unit file to create a
|
||||
zram device. To activate, copy
|
||||
/usr/share/doc/rust-zram-generator/zram-generator.conf.example to
|
||||
/etc/systemd/zram-generator.conf and possibly edit to adjust the limits.
|
||||
|
||||
%package -n %{crate}
|
||||
Summary: %{summary}
|
||||
|
||||
%description -n %{crate}
|
||||
%{summary}.
|
||||
|
||||
%prep
|
||||
%autosetup -n %{crate}-%{version} -p1
|
||||
%cargo_prep
|
||||
|
||||
%build
|
||||
%cargo_build
|
||||
|
||||
%install
|
||||
%cargo_install
|
||||
|
||||
mkdir -p %{buildroot}%{_systemdgeneratordir}
|
||||
mv -v %{buildroot}%{_bindir}/zram-generator %{buildroot}%{_systemdgeneratordir}/
|
||||
|
||||
%if %{with check}
|
||||
%check
|
||||
%cargo_test
|
||||
%endif
|
||||
|
||||
%files -n %{crate}
|
||||
%license LICENSE
|
||||
%doc zram-generator.conf.example
|
||||
%doc README.md TODO
|
||||
%{_systemdgeneratordir}/zram-generator
|
||||
|
||||
%changelog
|
||||
* Thu Aug 16 2018 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 0.1.1-1
|
||||
- Initial package
|
BIN
zram-generator-0.1.1.crate
Normal file
BIN
zram-generator-0.1.1.crate
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user