1 |
%define oname FedoraZram |
2 |
|
3 |
%define gitdate 20120916 |
4 |
%define rel 2 |
5 |
|
6 |
Name: zramstart |
7 |
Version: 0 |
8 |
Release: %mkrel -c git%{gitdate} %{rel} |
9 |
Summary: Sets up zram swap devices on boot |
10 |
License: GPL+ |
11 |
Url: https://github.com/mystilleef/FedoraZram |
12 |
Group: System/Kernel and hardware |
13 |
# |
14 |
# git clone https://github.com/mystilleef/FedoraZram.git |
15 |
# cd FedoraZram |
16 |
# git archive --format=tar --prefix=FedoraZram-20120916/ master | xz > ../FedoraZram-20120916.tar.xz |
17 |
# |
18 |
Source0: %{oname}-%{gitdate}.tar.xz |
19 |
Patch0: FedoraZram-20120916-fix-Makefile.patch |
20 |
Patch1: FedoraZram-20120916-fix-systemd-unit-file.patch |
21 |
BuildArch: noarch |
22 |
Provides: zramswap-enabler |
23 |
|
24 |
%description |
25 |
zram compresses swap partitions into RAM for performance. |
26 |
|
27 |
%prep |
28 |
%setup -qn %{oname}-%{gitdate} |
29 |
%apply_patches |
30 |
|
31 |
%build |
32 |
#nothing |
33 |
|
34 |
%install |
35 |
%makeinstall_std \ |
36 |
PREFIX=%{_prefix} \ |
37 |
SYSTEMD_UNITDIR=%{_unitdir} |
38 |
|
39 |
%post |
40 |
%_post_service zram |
41 |
|
42 |
%preun |
43 |
%_preun_service zram |
44 |
|
45 |
%files |
46 |
%doc README |
47 |
%{_sysconfdir}/default/zram |
48 |
%{_unitdir}/zram.service |
49 |
%{_sbindir}/zramstart |
50 |
%{_sbindir}/zramstop |