Browse Source

board/mender/x86_64/post-image-efi.sh: use bash for genimage.sh

mender_x86_64_efi_defconfig started failing to build since 2024.08 in
our Gitlab-ci since the board/mender/x86_64/post-image-efi.sh is
calling support/scripts/genimage.sh with the host default shell.

There is no problem if the default shell is bash but our docker
image uses dash as default shell. Since support/scripts/genimage.sh
is actually a bash script it's not going to work if bashisms are used:

  support/scripts/genimage.sh: 57: Syntax error: redirection unexpected

Indeed bashisms have been added recently in
support/scripts/genimage.sh by the commit introducing bmap image
support [1].

Remove "sh" before support/scripts/genimage.sh and rely on
"/usr/bin/env bash" to find the bash interpreter.

Fixes:
https://gitlab.com/buildroot.org/buildroot/-/jobs/8233226891

[1] 6889056f1eb4293de67c28b1ff6ee34be05d2ee4

Signed-off-by: Romain Naour <romain.naour@smile.fr>
Signed-off-by: Julien Olivain <ju.o@free.fr>
(cherry picked from commit c146555faa3fe563e9848be562d129d08f561d7f)
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Romain Naour 9 months ago
parent
commit
9a3670d7d8
1 changed files with 1 additions and 1 deletions
  1. 1 1
      board/mender/x86_64/post-image-efi.sh

+ 1 - 1
board/mender/x86_64/post-image-efi.sh

@@ -54,7 +54,7 @@ generate_mender_image() {
 }
 }
 
 
 generate_image() {
 generate_image() {
-    sh support/scripts/genimage.sh -c "${BOARD_DIR}/genimage-efi.cfg"
+    support/scripts/genimage.sh -c "${BOARD_DIR}/genimage-efi.cfg"
 }
 }
 
 
 # Main function.
 # Main function.