new script for remove of old kernels
This commit is contained in:
parent
4d2203e0b2
commit
6f19f7d87d
18
do-kernel-remove.sh
Executable file
18
do-kernel-remove.sh
Executable file
@ -0,0 +1,18 @@
|
||||
#!/bin/sh
|
||||
if [ -z "$1" ]; then
|
||||
echo do-kernel-remove.sh KVERSION
|
||||
exit
|
||||
fi
|
||||
|
||||
VER=$1
|
||||
BASEDIR=$(dirname $0)
|
||||
|
||||
source $BASEDIR/kernel
|
||||
|
||||
EMERGE=""
|
||||
|
||||
for package in ${PACKAGES}; do
|
||||
EMERGE="$EMERGE =${package}-${VER}"
|
||||
done
|
||||
|
||||
emerge -c $EMERGE
|
108
eclass/avahi.eclass
Normal file
108
eclass/avahi.eclass
Normal file
@ -0,0 +1,108 @@
|
||||
# Copyright 2004-2011 Sabayon
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $
|
||||
|
||||
SUPPORTED_AVAHI_MODULES="base gtk gtk3 mono qt"
|
||||
|
||||
# @ECLASS-VARIABLE: AVAHI_MODULE
|
||||
# @DESCRIPTION:
|
||||
# Set this variable to the avahi module ebuild name, by default it's used
|
||||
# the second part of PN, for example: for avahi-glib, it is "glib".
|
||||
# Supported avahi modules:
|
||||
# base gtk gtk3 mono qt
|
||||
AVAHI_MODULE="${AVAHI_MODULE:-${PN/avahi-}}"
|
||||
|
||||
# @ECLASS-VARIABLE: AVAHI_PATCHES
|
||||
# @DEFAULT-UNSET
|
||||
# @DESCRIPTION:
|
||||
# List of patches to apply
|
||||
if [ -z "${AVAHI_PATCHES}" ]; then
|
||||
AVAHI_PATCHES=()
|
||||
fi
|
||||
|
||||
# @ECLASS-VARIABLE: AVAHI_MODULE_DEPEND
|
||||
# @DESCRIPTION:
|
||||
# Avahi module built time dependencies list
|
||||
AVAHI_MODULE_DEPEND="${AVAHI_MODULE_DEPEND:-}"
|
||||
|
||||
# @ECLASS-VARIABLE: AVAHI_MODULE_RDEPEND
|
||||
# @DESCRIPTION:
|
||||
# Avahi module run time dependencies list
|
||||
AVAHI_MODULE_RDEPEND="${AVAHI_MODULE_RDEPEND:-}"
|
||||
|
||||
# @ECLASS-VARIABLE: AVAHI_MODULE_PDEPEND
|
||||
# @DESCRIPTION:
|
||||
# Avahi module post dependencies list
|
||||
AVAHI_MODULE_PDEPEND="${AVAHI_MODULE_PDEPEND:-}"
|
||||
|
||||
_supported="0"
|
||||
for mod in ${SUPPORTED_AVAHI_MODULES} ; do
|
||||
if [ "${mod}" = "${AVAHI_MODULE}" ]; then
|
||||
_supported="1"
|
||||
break
|
||||
fi
|
||||
done
|
||||
if [ "${_supported}" = "0" ]; then
|
||||
die "Unsupported avahi module: ${AVAHI_MODULE}"
|
||||
fi
|
||||
|
||||
MY_P=${P/-${AVAHI_MODULE}}
|
||||
|
||||
inherit autotools eutils flag-o-matic
|
||||
|
||||
DESCRIPTION="avahi ${AVAHI_MODULE} module"
|
||||
HOMEPAGE="http://avahi.org/"
|
||||
SRC_URI="http://avahi.org/download/${MY_P}.tar.gz"
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
|
||||
AVAHI_COMMON_DEPEND=">=dev-util/intltool-0.40.5
|
||||
>=dev-util/pkgconfig-0.9.0"
|
||||
DEPEND="${AVAHI_MODULE_DEPEND} ${AVAHI_COMMON_DEPEND}"
|
||||
RDEPEND="${AVAHI_MODULE_RDEPEND}"
|
||||
PDEPEND="${AVAHI_MODULE_PDEPEND}"
|
||||
|
||||
avahi_src_prepare() {
|
||||
sed -i\
|
||||
-e "s:\\.\\./\\.\\./\\.\\./doc/avahi-docs/html/:../../../doc/${PF}/html/:" \
|
||||
doxygen_to_devhelp.xsl || die
|
||||
|
||||
# Drop DEPRECATED flags, bug #384743
|
||||
sed -i -e 's:-D[A-Z_]*DISABLE_DEPRECATED=1::g' avahi-ui/Makefile.am || die
|
||||
|
||||
# Prevent .pyc files in DESTDIR
|
||||
>py-compile
|
||||
|
||||
for i in ${!AVAHI_PATCHES[@]}; do
|
||||
epatch "${AVAHI_PATCHES[i]}"
|
||||
done
|
||||
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
avahi_src_configure() {
|
||||
use sh && replace-flags -O? -O0
|
||||
# We need to unset DISPLAY, else the configure script might have problems detecting the pygtk module
|
||||
unset DISPLAY
|
||||
local myconf="
|
||||
--disable-static
|
||||
--localstatedir=/var
|
||||
--with-distro=gentoo
|
||||
--disable-xmltoman
|
||||
--disable-monodoc
|
||||
--enable-glib
|
||||
--enable-gobject
|
||||
--disable-qt3
|
||||
$@"
|
||||
econf ${myconf}
|
||||
}
|
||||
|
||||
avahi_src_install-cleanup() {
|
||||
# Remove .la files
|
||||
find "${D}" -name '*.la' -exec rm -f {} + || die
|
||||
}
|
||||
|
||||
EXPORT_FUNCTIONS src_prepare src_configure
|
@ -645,13 +645,13 @@ _kernel_src_compile() {
|
||||
-d zImage.new "${WORKDIR}"/boot/uImage-genkernel-${ARCH}-${KV_FULL}.buffalo
|
||||
einfo "Create uInitrd with correct start address"
|
||||
mkimage -A arm -O linux -T ramdisk -C none -a 0x00000000 -e 0x00000000 -n initrd-${KV_FULL} \
|
||||
-d "${WORKDIR}"/boot/initramfs-genkernel-${ARCH}-${KV_FULL} "${WORKDIR}"/boot/uInitrd-genkernel-${ARCH}-${KV_FULL}.buffalo
|
||||
-d "${WORKDIR}"/boot/initramfs-genkernel-${ARCH}-${KV_FULL} "${WORKDIR}"/boot/uInitramfs-genkernel-${ARCH}-${KV_FULL}.buffalo
|
||||
fi
|
||||
fi
|
||||
|
||||
# cleanup
|
||||
rm -rf foo zImage.new ${K_NASKERNEL_DTB}
|
||||
# rm "${WORKDIR}"/boot/kernel-genkernel-${ARCH}-${KV_FULL} "${WORKDIR}"/boot/initramfs-genkernel-${ARCH}-${KV_FULL}
|
||||
rm "${WORKDIR}"/boot/kernel-genkernel-${ARCH}-${KV_FULL} "${WORKDIR}"/boot/initramfs-genkernel-${ARCH}-${KV_FULL}
|
||||
}
|
||||
|
||||
_setup_mkimage_ramdisk() {
|
||||
|
Loading…
Reference in New Issue
Block a user