mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

53 lines
2.2 KiB

# --- ROCK-COPYRIGHT-NOTE-BEGIN ---
#
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
# Please add additional copyright information _after_ the line containing
# the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
#
# ROCK Linux: rock-src/package/mnemoc/rsbac/pkg_linux_pre.conf
# ROCK Linux is Copyright (C) 1998 - 2006 Clifford Wolf
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version. A copy of the GNU General Public
# License can be found at Documentation/COPYING.
#
# Many people helped and are helping developing ROCK Linux. Please
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM
# file for details.
#
# --- ROCK-COPYRIGHT-NOTE-END ---
if [ "${xpkg:0:7}" == "linux24" ] ; then
echo_status "Including RSBAC patch..."
pkg_rsbac_tempdir=`mktemp -d`
pkg_rsbac_archdir=$base/download/mirror/r
pkg_rsbac_confdir=$base/package/mnemoc/rsbac
pkg_rsbac_ver=`sed -n 's,^\[V\] \(.*\),\1,p' ${pkg_rsbac_confdir}/rsbac.desc`
# ignore kernel version of the patch, it can be appliable to another.
pkg_rsbac_lxpatch=$( grep "^\[D\]" ${pkg_rsbac_confdir}/rsbac.desc | \
sed -n "s,.* \(patch-.*-v${pkg_rsbac_ver}.gz\) .*,\1,p" )
bunzip2 -c ${pkg_rsbac_archdir}/${pkg_rsbac_lxpatch%.gz}.bz2 > \
${pkg_rsbac_tempdir}/rsbac-${pkg_rsbac_ver}.patch
var_append patchfiles ' ' "${pkg_rsbac_tempdir}/rsbac-${pkg_rsbac_ver}.patch"
var_append patchfiles ' ' "${pkg_rsbac_confdir}/rsbac-no_extraversion.diff"
var_append conffiles ' ' "${pkg_rsbac_confdir}/kernel.conf.sh"
hook_add prepatch 4 "tar -v $taropt ${pkg_rsbac_archdir}/rsbac-v${pkg_rsbac_ver}.tar.bz2"
hook_add postpatch 6 "rm -rf $pkg_rsbac_tempdir"
# apply hotfixes here
for i in $pkg_rsbac_lxpatches; do
var_append patchfiles ' ' "${pkg_rsbac_archdir}/rsbac-bugfix-v$pkg_rsbac_ver-$i.diff"
done
# copy include/rsbac to /usr/include/linux too
if [[ $xpkg = *header* ]] ; then
hook_add postdoc 1 'cp -rv include/rsbac $includedir/'
fi
fi