summaryrefslogtreecommitdiff
path: root/meta/classes/kernel.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2007-01-08 21:05:18 +0000
committerRichard Purdie <richard@openedhand.com>2007-01-08 21:05:18 +0000
commitfb61dc1430f81ae2ee59766ffab8404fd79ff1b1 (patch)
tree50693c739a63db8e9e1793bb08050a71ceba51a7 /meta/classes/kernel.bbclass
parent3a8695033f23888b76e413eae3c7096a01a9ab84 (diff)
downloadopenembedded-core-fb61dc1430f81ae2ee59766ffab8404fd79ff1b1.tar.gz
openembedded-core-fb61dc1430f81ae2ee59766ffab8404fd79ff1b1.tar.bz2
openembedded-core-fb61dc1430f81ae2ee59766ffab8404fd79ff1b1.zip
kernel.bbclass: Drop KERNEL_RELEASE variable
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@1123 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/classes/kernel.bbclass')
-rw-r--r--meta/classes/kernel.bbclass35
1 files changed, 15 insertions, 20 deletions
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index 13381740a1..56e3946c4a 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -14,12 +14,7 @@ KERNEL_IMAGETYPE ?= "zImage"
KERNEL_PRIORITY = "${@bb.data.getVar('PV',d,1).split('-')[0].split('.')[-1]}"
-# [jbowler 20051109] ${PV}${KERNEL_LOCALVERSION} is used throughout this
-# .bbclass to (apparently) find the full 'uname -r' kernel version, this
-# should be the same as UTS_RELEASE or (in this file) KERNEL_VERSION:
-# KERNELRELEASE=$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION)$(LOCALVERSION)
-# but since this is not certain this overridable setting is used here:
-KERNEL_RELEASE ?= "${PV}${KERNEL_LOCALVERSION}"
+KERNEL_RELEASE ?= "${KERNEL_VERSION}"
KERNEL_CCSUFFIX ?= ""
KERNEL_LDSUFFIX ?= ""
@@ -111,9 +106,9 @@ kernel_do_stage() {
cp -fR drivers/sound/*.h ${STAGING_KERNEL_DIR}/include/drivers/sound/
fi
- install -m 0644 .config ${STAGING_KERNEL_DIR}/config-${KERNEL_RELEASE}
- ln -sf config-${KERNEL_RELEASE} ${STAGING_KERNEL_DIR}/.config
- ln -sf config-${KERNEL_RELEASE} ${STAGING_KERNEL_DIR}/kernel-config
+ install -m 0644 .config ${STAGING_KERNEL_DIR}/config-${KERNEL_VERSION}
+ ln -sf config-${KERNEL_VERSION} ${STAGING_KERNEL_DIR}/.config
+ ln -sf config-${KERNEL_VERSION} ${STAGING_KERNEL_DIR}/kernel-config
echo "${KERNEL_VERSION}" >${STAGING_KERNEL_DIR}/kernel-abiversion
echo "${S}" >${STAGING_KERNEL_DIR}/kernel-source
echo "${KERNEL_CCSUFFIX}" >${STAGING_KERNEL_DIR}/kernel-ccsuffix
@@ -128,7 +123,7 @@ kernel_do_stage() {
fi
cp -fR include/config* ${STAGING_KERNEL_DIR}/include/
install -m 0644 ${KERNEL_OUTPUT} ${STAGING_KERNEL_DIR}/${KERNEL_IMAGETYPE}
- install -m 0644 System.map ${STAGING_KERNEL_DIR}/System.map-${KERNEL_RELEASE}
+ install -m 0644 System.map ${STAGING_KERNEL_DIR}/System.map-${KERNEL_VERSION}
[ -e Module.symvers ] && install -m 0644 Module.symvers ${STAGING_KERNEL_DIR}/
cp -fR scripts ${STAGING_KERNEL_DIR}/
@@ -144,9 +139,9 @@ kernel_do_install() {
install -d ${D}/${KERNEL_IMAGEDEST}
install -d ${D}/boot
- install -m 0644 ${KERNEL_OUTPUT} ${D}/${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}-${KERNEL_RELEASE}
- install -m 0644 System.map ${D}/boot/System.map-${KERNEL_RELEASE}
- install -m 0644 .config ${D}/boot/config-${KERNEL_RELEASE}
+ install -m 0644 ${KERNEL_OUTPUT} ${D}/${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}-${KERNEL_VERSION}
+ install -m 0644 System.map ${D}/boot/System.map-${KERNEL_VERSION}
+ install -m 0644 .config ${D}/boot/config-${KERNEL_VERSION}
install -d ${D}/etc/modutils
# Check if scripts/genksyms exists and if so, build it
@@ -163,11 +158,11 @@ kernel_do_configure() {
}
pkg_postinst_kernel () {
- update-alternatives --install /${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE} ${KERNEL_IMAGETYPE} /${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}-${KERNEL_RELEASE} ${KERNEL_PRIORITY} || true
+ update-alternatives --install /${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE} ${KERNEL_IMAGETYPE} /${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}-${KERNEL_VERSION} ${KERNEL_PRIORITY} || true
}
pkg_postrm_kernel () {
- update-alternatives --remove ${KERNEL_IMAGETYPE} /${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}-${KERNEL_RELEASE} || true
+ update-alternatives --remove ${KERNEL_IMAGETYPE} /${KERNEL_IMAGEDEST}/${KERNEL_IMAGETYPE}-${KERNEL_VERSION} || true
}
inherit cml1
@@ -184,11 +179,11 @@ ALLOW_EMPTY_kernel = "1"
ALLOW_EMPTY_kernel-image = "1"
pkg_postinst_kernel-image () {
-if [ ! -e "$D/lib/modules/${KERNEL_RELEASE}" ]; then
- mkdir -p $D/lib/modules/${KERNEL_RELEASE}
+if [ ! -e "$D/lib/modules/${KERNEL_VERSION}" ]; then
+ mkdir -p $D/lib/modules/${KERNEL_VERSION}
fi
if [ -n "$D" ]; then
- ${HOST_PREFIX}depmod-${KERNEL_MAJOR_VERSION} -A -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_RELEASE} ${KERNEL_VERSION}
+ ${HOST_PREFIX}depmod-${KERNEL_MAJOR_VERSION} -A -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_VERSION} ${KERNEL_VERSION}
else
depmod -a
fi
@@ -196,7 +191,7 @@ fi
pkg_postinst_modules () {
if [ -n "$D" ]; then
- ${HOST_PREFIX}depmod-${KERNEL_MAJOR_VERSION} -A -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_RELEASE} ${KERNEL_VERSION}
+ ${HOST_PREFIX}depmod-${KERNEL_MAJOR_VERSION} -A -b $D -F ${STAGING_KERNEL_DIR}/System.map-${KERNEL_VERSION} ${KERNEL_VERSION}
else
depmod -a
update-modules || true
@@ -257,7 +252,7 @@ python populate_packages_prepend () {
bb.error("D not defined")
return
- kernelver = bb.data.getVar('KERNEL_RELEASE', d, 1)
+ kernelver = bb.data.getVar('KERNEL_VERSION', d, 1)
kernelver_stripped = kernelver
m = re.match('^(.*-hh.*)[\.\+].*$', kernelver)
if m: