aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Oberritter <obi@opendreambox.org>2017-11-17 18:49:14 +0100
committerAndreas Oberritter <obi@opendreambox.org>2019-04-08 13:49:57 +0200
commitbed5152cf576419f768e1981f24207b460fe0adc (patch)
treee5c58c3a142bba192ca7690a799305941fb38739
parentb85f335bee1e8f4bddd8954b047e87dba7c08e33 (diff)
downloadopenembedded-core-contrib-bed5152cf576419f768e1981f24207b460fe0adc.tar.gz
Revert "Revert "kernel: Fix symlinks""
This reverts commit 11880ea22d59f747d231bb50cbdd70b611867a77.
-rw-r--r--meta/classes/kernel.bbclass6
-rw-r--r--meta/recipes-kernel/linux/linux-dtb.inc4
2 files changed, 5 insertions, 5 deletions
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index fc55f9e69f..ce2cab65ae 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -53,10 +53,11 @@ python __anonymous () {
for type in types.split():
typelower = type.lower()
+ imagedest = d.getVar('KERNEL_IMAGEDEST')
d.appendVar('PACKAGES', ' ' + 'kernel-image-' + typelower)
- d.setVar('FILES_kernel-image-' + typelower, '/boot/' + type + '-${KERNEL_VERSION_NAME}')
+ d.setVar('FILES_kernel-image-' + typelower, '/' + imagedest + '/' + type + '-${KERNEL_VERSION_NAME}')
d.appendVar('RDEPENDS_kernel-image', ' ' + 'kernel-image-' + typelower)
@@ -64,9 +65,8 @@ python __anonymous () {
d.setVar('ALLOW_EMPTY_kernel-image-' + typelower, '1')
- imagedest = d.getVar('KERNEL_IMAGEDEST')
priority = d.getVar('KERNEL_PRIORITY')
- postinst = '#!/bin/sh\n' + 'update-alternatives --install /' + imagedest + '/' + type + ' ' + type + ' ' + '/' + imagedest + '/' + type + '-${KERNEL_VERSION_NAME} ' + priority + ' || true' + '\n'
+ postinst = '#!/bin/sh\n' + 'update-alternatives --install /' + imagedest + '/' + type + ' ' + type + ' ' + type + '-${KERNEL_VERSION_NAME} ' + priority + ' || true' + '\n'
d.setVar('pkg_postinst_kernel-image-' + typelower, postinst)
postrm = '#!/bin/sh\n' + 'update-alternatives --remove' + ' ' + type + ' ' + type + '-${KERNEL_VERSION_NAME} || true' + '\n'
diff --git a/meta/recipes-kernel/linux/linux-dtb.inc b/meta/recipes-kernel/linux/linux-dtb.inc
index 41aad7c309..22e374fa88 100644
--- a/meta/recipes-kernel/linux/linux-dtb.inc
+++ b/meta/recipes-kernel/linux/linux-dtb.inc
@@ -63,7 +63,7 @@ pkg_postinst_kernel-devicetree () {
DTB_EXT=${DTB##*.}
DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"`
DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"`
- update-alternatives --install /${KERNEL_IMAGEDEST}/${DTB_BASE_NAME}.${DTB_EXT} ${DTB_BASE_NAME}.${DTB_EXT} /boot/devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT} ${KERNEL_PRIORITY} || true
+ update-alternatives --install /${KERNEL_IMAGEDEST}/${DTB_BASE_NAME}.${DTB_EXT} ${DTB_BASE_NAME}.${DTB_EXT} devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT} ${KERNEL_PRIORITY} || true
done
done
}
@@ -76,7 +76,7 @@ pkg_postrm_kernel-devicetree () {
DTB_EXT=${DTB##*.}
DTB_BASE_NAME=`basename ${DTB} ."${DTB_EXT}"`
DTB_SYMLINK_NAME=`echo ${symlink_name} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"`
- update-alternatives --remove ${DTB_BASE_NAME}.${DTB_EXT} /boot/devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT} ${KERNEL_PRIORITY} || true
+ update-alternatives --remove ${DTB_BASE_NAME}.${DTB_EXT} devicetree-${DTB_SYMLINK_NAME}.${DTB_EXT} ${KERNEL_PRIORITY} || true
done
done
}