diff options
author | Martin Jansa <Martin.Jansa@gmail.com> | 2023-05-12 12:22:20 -0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2023-05-22 10:53:47 +0100 |
commit | e6eb278ce85f3ab93bdb44ce24c2eb27b7bf84a0 (patch) | |
tree | 906aacdc79c4f9a9e537f6edb8776d1f301ccbf5 | |
parent | fc899f1e1b407d493228ccb144972828271d0367 (diff) | |
download | poky-e6eb278ce85f3ab93bdb44ce24c2eb27b7bf84a0.tar.gz |
kernel-devicetree: make shell scripts posix compliant
Use the notation suggested by Martin Jansa to avoid a bashism. Also
switch KERNEL_DTBVENDORED to the more common 0/1 notation instead of
true/false.
Fixes: 04ab57d200 (kernel-devicetree: allow specification of dtb
directory, 2023-05-02)
(From OE-Core rev: dd5a5abc9d88c3bc8ff2c52b042600f00f054015)
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Randolph Sapp <rs@ti.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes-recipe/kernel-devicetree.bbclass | 4 | ||||
-rw-r--r-- | meta/classes-recipe/kernel.bbclass | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/meta/classes-recipe/kernel-devicetree.bbclass b/meta/classes-recipe/kernel-devicetree.bbclass index a6c6c5f227..831fdd1527 100644 --- a/meta/classes-recipe/kernel-devicetree.bbclass +++ b/meta/classes-recipe/kernel-devicetree.bbclass | |||
@@ -82,7 +82,7 @@ do_install:append() { | |||
82 | for dtbf in ${KERNEL_DEVICETREE}; do | 82 | for dtbf in ${KERNEL_DEVICETREE}; do |
83 | dtb=`normalize_dtb "$dtbf"` | 83 | dtb=`normalize_dtb "$dtbf"` |
84 | dtb_path=`get_real_dtb_path_in_kernel "$dtb"` | 84 | dtb_path=`get_real_dtb_path_in_kernel "$dtb"` |
85 | if [ ${KERNEL_DTBVENDORED} == "false" ]; then | 85 | if "${@'false' if oe.types.boolean(d.getVar('KERNEL_DTBVENDORED')) else 'true'}"; then |
86 | dtb_ext=${dtb##*.} | 86 | dtb_ext=${dtb##*.} |
87 | dtb_base_name=`basename $dtb .$dtb_ext` | 87 | dtb_base_name=`basename $dtb .$dtb_ext` |
88 | dtb=$dtb_base_name.$dtb_ext | 88 | dtb=$dtb_base_name.$dtb_ext |
@@ -97,7 +97,7 @@ do_deploy:append() { | |||
97 | dtb_ext=${dtb##*.} | 97 | dtb_ext=${dtb##*.} |
98 | dtb_base_name=`basename $dtb .$dtb_ext` | 98 | dtb_base_name=`basename $dtb .$dtb_ext` |
99 | install -d $deployDir | 99 | install -d $deployDir |
100 | if [ ${KERNEL_DTBVENDORED} == "false" ]; then | 100 | if "${@'false' if oe.types.boolean(d.getVar('KERNEL_DTBVENDORED')) else 'true'}"; then |
101 | dtb=$dtb_base_name.$dtb_ext | 101 | dtb=$dtb_base_name.$dtb_ext |
102 | fi | 102 | fi |
103 | install -m 0644 ${D}/${KERNEL_DTBDEST}/$dtb $deployDir/$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext | 103 | install -m 0644 ${D}/${KERNEL_DTBDEST}/$dtb $deployDir/$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext |
diff --git a/meta/classes-recipe/kernel.bbclass b/meta/classes-recipe/kernel.bbclass index 8f022b234d..4bce64cf6a 100644 --- a/meta/classes-recipe/kernel.bbclass +++ b/meta/classes-recipe/kernel.bbclass | |||
@@ -216,7 +216,7 @@ KERNEL_RELEASE ?= "${KERNEL_VERSION}" | |||
216 | KERNEL_OUTPUT_DIR ?= "arch/${ARCH}/boot" | 216 | KERNEL_OUTPUT_DIR ?= "arch/${ARCH}/boot" |
217 | KERNEL_IMAGEDEST ?= "boot" | 217 | KERNEL_IMAGEDEST ?= "boot" |
218 | KERNEL_DTBDEST ?= "${KERNEL_IMAGEDEST}" | 218 | KERNEL_DTBDEST ?= "${KERNEL_IMAGEDEST}" |
219 | KERNEL_DTBVENDORED ?= "false" | 219 | KERNEL_DTBVENDORED ?= "0" |
220 | 220 | ||
221 | # | 221 | # |
222 | # configuration | 222 | # configuration |