Name ksplice Version Release dist Summary Patching Linux kernel withou

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
Name: ksplice
Version: 0.9.6
Release: 1%{?dist}
Summary: Patching a Linux kernel without reboot
Group: System Environment/Kernel
License: GPLv2
URL: http://ksplice.com
Source0: http://ksplice.com/dist/ksplice-%{version}-src.tar.gz
# Sent to upstream via email
Patch0: ksplice-0.9.4-config.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
ExcludeArch: ppc64, ppc
BuildRequires: autoconf
BuildRequires: binutils-devel, perl
BuildRequires: zlib-devel
Requires: gcc >= 3.4.2
Requires: patch >= 2.5.4
Requires: module-init-tools
Requires: binutils >= 2.12
Requires: bash >= 2.03
Requires: make >= 3.78
Requires: sh-utils, m4,
Requires: findutils, diffutils, tar, gzip, bzip2, perl, gawk
Requires: util-linux-ng
%description
Ksplice allows system administrators to apply security patches to the
Linux kernel without having to reboot. Ksplice takes as input a source
code change in unified diff format and the kernel source code to be
patched, and it applies the patch to the corresponding running kernel.
The running kernel does not need to have been prepared in advance in
any way.
%prep
%setup -q
%patch0 -p1 -b .auto
# Filter ksplce as a provide
cat << \EOF > %{name}-prov
#!/bin/sh
%{__perl_provides} $* |\
sed -e '/perl(Ksplice)/d'
EOF
%define __perl_provides %{_builddir}/%{name}-%{version}/%{name}-prov
chmod +x %{__perl_provides}
cat << \EOF > %{name}-req
#!/bin/sh
%{__perl_requires} $* |\
sed -e '/perl(Ksplice)/d'
EOF
%define __perl_requires %{_builddir}/%{name}-%{version}/%{name}-req
chmod +x %{__perl_requires}
%build
autoconf
%configure --with-libz --with-libbfd --with-libiberty
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%{_bindir}/ksplice-*
%{_sbindir}/ksplice-*
%{_libexecdir}/ksplice-*
%{_datadir}/ksplice/
%{_mandir}/man8/ksplice-*
%doc COPYING README
%changelog