From 46a36694cea8bc795a8a00bef5e0a4e8e0cfe058 Mon Sep 17 00:00:00 2001 From: Igor Raits Date: Wed, 13 Jan 2021 16:58:19 +0100 Subject: [PATCH] Update to 0.3.0-rc.1 Signed-off-by: Igor Raits --- .gitignore | 1 + .rust2rpm.conf | 2 ++ rust-zram-generator.spec | 26 ++++++++++++++++---------- sources | 2 +- zram-generator-fix-metadata.diff | 11 ----------- 5 files changed, 20 insertions(+), 22 deletions(-) delete mode 100644 zram-generator-fix-metadata.diff diff --git a/.gitignore b/.gitignore index 31491d7..ea2e892 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ /zram-generator-0.2.0-beta.1.crate /zram-generator-0.2.0-rc.1.crate /zram-generator-0.2.0.crate +/zram-generator-0.3.0-rc.1.crate diff --git a/.rust2rpm.conf b/.rust2rpm.conf index 067a624..f710a32 100644 --- a/.rust2rpm.conf +++ b/.rust2rpm.conf @@ -2,3 +2,5 @@ buildrequires = systemd-rpm-macros /usr/bin/ronn + /usr/bin/make + pkgconfig(systemd) diff --git a/rust-zram-generator.spec b/rust-zram-generator.spec index ad3feef..8d72a05 100644 --- a/rust-zram-generator.spec +++ b/rust-zram-generator.spec @@ -1,11 +1,11 @@ -# Generated by rust2rpm 16 +# Generated by rust2rpm 17 %bcond_without check %global crate zram-generator Name: rust-%{crate} -Version: 0.2.0 -Release: 6%{?dist} +Version: 0.3.0~rc.1 +Release: 1%{?dist} Summary: Systemd unit generator for zram swap devices # Upstream license specification: MIT @@ -13,9 +13,6 @@ License: MIT URL: https://crates.io/crates/zram-generator Source: %{crates_source} Source1: zram-generator.conf -# Initial patched metadata -# * allow rust-ini 0.16 -Patch0: zram-generator-fix-metadata.diff ExclusiveArch: %{rust_arches} %if %{__cargo_skip_build} @@ -23,8 +20,6 @@ BuildArch: noarch %endif BuildRequires: rust-packaging -BuildRequires: systemd-rpm-macros -BuildRequires: /usr/bin/ronn %global _description %{expand: This is a systemd unit generator that enables swap on zram. @@ -50,7 +45,7 @@ Recommends: /usr/bin/zramctl %doc zram-generator.conf.example %doc README.md %{_systemdgeneratordir}/zram-generator -%{_unitdir}/swap-create@.service +%{_unitdir}/systemd-zram-setup@.service %{_mandir}/man8/zram-generator.8* %{_mandir}/man5/zram-generator.conf.5* @@ -100,27 +95,38 @@ cp -a %{S:1} . %generate_buildrequires %cargo_generate_buildrequires +echo '/usr/bin/make' +echo '/usr/bin/ronn' +echo 'systemd-rpm-macros' +echo 'pkgconfig(systemd)' %build +export SYSTEMD_UTIL_DIR=$(pkg-config --variable=systemdutildir systemd) %cargo_build +make systemd_service LC_ALL=C.UTF-8 ronn --roff --organization="zram-generator %{version_no_tilde}" man/*.md %install +export SYSTEMD_UTIL_DIR=$(pkg-config --variable=systemdutildir systemd) %cargo_install mkdir -p %{buildroot}%{_systemdgeneratordir} mv -v %{buildroot}%{_bindir}/zram-generator %{buildroot}%{_systemdgeneratordir}/ -install -Dpm0644 -t %{buildroot}%{_unitdir} units/swap-create@.service +install -Dpm0644 -t %{buildroot}%{_unitdir} units/systemd-zram-setup@.service install -Dpm0644 -t %{buildroot}%{_prefix}/lib/systemd zram-generator.conf install -Dpm0644 -t %{buildroot}%{_mandir}/man8 man/zram-generator.8 install -Dpm0644 -t %{buildroot}%{_mandir}/man5 man/zram-generator.conf.5 %if %{with check} %check +export SYSTEMD_UTIL_DIR=$(pkg-config --variable=systemdutildir systemd) %cargo_test %endif %changelog +* Wed Jan 13 16:57:21 CET 2021 Igor Raits - 0.3.0~rc.1-1 +- Update to 0.3.0-rc.1 + * Mon Dec 28 13:34:14 CET 2020 Igor Raits - 0.2.0-6 - Rebuild diff --git a/sources b/sources index ce3676d..e74c6b5 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (zram-generator-0.2.0.crate) = 03c80bbd866e32d8e47ecb87ff0ee782d247b81f3cb6c429481f6954dfb106605e9fd895598b39e24e1ac115d1d65f0b99640186ed47be585b5a8225a710ff88 +SHA512 (zram-generator-0.3.0-rc.1.crate) = e182acd912bb6c1e640e167e7dc89ff2d47ebaf1b7cc408fd5920ffd6ff489082663573f3a631854846bf98a330bf86243495ea0450621cd04eeb6001e9685d0 diff --git a/zram-generator-fix-metadata.diff b/zram-generator-fix-metadata.diff deleted file mode 100644 index a9536f7..0000000 --- a/zram-generator-fix-metadata.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- zram-generator-0.2.0/Cargo.toml 2020-07-04T15:30:00+00:00 -+++ zram-generator-0.2.0/Cargo.toml 2020-11-23T13:24:06.584817+00:00 -@@ -38,7 +38,7 @@ - features = ["std"] - - [dependencies.rust-ini] --version = ">=0.13, <0.16" -+version = ">=0.13, <0.17" - [dev-dependencies.fs_extra] - version = "1.1" -