blob: 19c4bb3a42d1b6caf3b24b4efe3609b94a2bf583 (
plain)
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
|
#!/bin/bash
SCRIPT="$0"
KMAJOR="$1"
DIRVER="$(basename $(pwd) | sed -e 's/linux-//' -e 's/-hardened.*//')"
: ${KMAJOR:=$DIRVER}
PATCHSET="/root/hardened-patchset/${KMAJOR}"
if [[ ! -d ${PATCHSET} ]] ; then
echo "Patchset ${KMAJOR} doesn't exist"
exit
fi
for p in $(ls ${PATCHSET}) ; do
if [[ ${p#0000} == $p ]] ; then
echo "++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"
echo
echo $p
echo
patch -p 1 --dry-run < ${PATCHSET}/$p
echo "Cont?"
read n
echo
patch -p 1 < ${PATCHSET}/$p
echo
echo "++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++"
fi
done
|