diff mbox series

[isar-cip-core] classes: make swu image file variable absolute like the others

Message ID 20210111124104.31067-1-henning.schild@siemens.com (mailing list archive)
State Not Applicable
Headers show
Series [isar-cip-core] classes: make swu image file variable absolute like the others | expand

Commit Message

Henning Schild Jan. 11, 2021, 12:41 p.m. UTC
From: Henning Schild <henning.schild@siemens.com>

All the other variables for images already contain the deploydir
in their absolute names. Only the one for swupdate was relative.

Found this in another layer where we have a task copying deploy
files to a deploy location with bitbake.

Signed-off-by: Henning Schild <henning.schild@siemens.com>
---
 classes/swupdate-img.bbclass | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Jan Kiszka Jan. 13, 2021, 10:45 a.m. UTC | #1
On 11.01.21 13:41, Henning Schild wrote:
> From: Henning Schild <henning.schild@siemens.com>
> 
> All the other variables for images already contain the deploydir
> in their absolute names. Only the one for swupdate was relative.
> 
> Found this in another layer where we have a task copying deploy
> files to a deploy location with bitbake.
> 
> Signed-off-by: Henning Schild <henning.schild@siemens.com>
> ---
>  classes/swupdate-img.bbclass | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/classes/swupdate-img.bbclass b/classes/swupdate-img.bbclass
> index a21d6ec..09e92cc 100644
> --- a/classes/swupdate-img.bbclass
> +++ b/classes/swupdate-img.bbclass
> @@ -9,7 +9,7 @@
>  #
>  # SPDX-License-Identifier: MIT
>  
> -SWU_IMAGE_FILE ?= "${PN}-${DISTRO}-${MACHINE}.swu"
> +SWU_IMAGE_FILE ?= "${DEPLOY_DIR_IMAGE}/${PN}-${DISTRO}-${MACHINE}.swu"
>  SWU_DESCRIPTION_FILE ?= "sw-description"
>  SWU_ADDITIONAL_FILES ?= ""
>  SWU_SIGNED ?= ""
> @@ -21,7 +21,7 @@ IMAGER_INSTALL += "${@'openssl' if bb.utils.to_boolean(d.getVar('SWU_SIGNED')) e
>  do_swupdate_image[stamp-extra-info] = "${DISTRO}-${MACHINE}"
>  do_swupdate_image[cleandirs] += "${WORKDIR}/swu"
>  do_swupdate_image() {
> -    rm -f '${DEPLOY_DIR_IMAGE}/${SWU_IMAGE_FILE}'
> +    rm -f '${SWU_IMAGE_FILE}'
>      cp '${WORKDIR}/${SWU_DESCRIPTION_FILE}' '${WORKDIR}/swu/${SWU_DESCRIPTION_FILE}'
>  
>      # Create symlinks for files used in the update image
> @@ -68,7 +68,7 @@ do_swupdate_image() {
>              echo "$file".'${SWU_SIGNATURE_EXT}'
>          fi
>      done | cpio -ovL -H crc \
> -        > '${DEPLOY_DIR_IMAGE}/${SWU_IMAGE_FILE}'
> +        > '${SWU_IMAGE_FILE}'
>      cd -
>  }
>  
> 

Thanks, applied.

Jan
diff mbox series

Patch

diff --git a/classes/swupdate-img.bbclass b/classes/swupdate-img.bbclass
index a21d6ec..09e92cc 100644
--- a/classes/swupdate-img.bbclass
+++ b/classes/swupdate-img.bbclass
@@ -9,7 +9,7 @@ 
 #
 # SPDX-License-Identifier: MIT
 
-SWU_IMAGE_FILE ?= "${PN}-${DISTRO}-${MACHINE}.swu"
+SWU_IMAGE_FILE ?= "${DEPLOY_DIR_IMAGE}/${PN}-${DISTRO}-${MACHINE}.swu"
 SWU_DESCRIPTION_FILE ?= "sw-description"
 SWU_ADDITIONAL_FILES ?= ""
 SWU_SIGNED ?= ""
@@ -21,7 +21,7 @@  IMAGER_INSTALL += "${@'openssl' if bb.utils.to_boolean(d.getVar('SWU_SIGNED')) e
 do_swupdate_image[stamp-extra-info] = "${DISTRO}-${MACHINE}"
 do_swupdate_image[cleandirs] += "${WORKDIR}/swu"
 do_swupdate_image() {
-    rm -f '${DEPLOY_DIR_IMAGE}/${SWU_IMAGE_FILE}'
+    rm -f '${SWU_IMAGE_FILE}'
     cp '${WORKDIR}/${SWU_DESCRIPTION_FILE}' '${WORKDIR}/swu/${SWU_DESCRIPTION_FILE}'
 
     # Create symlinks for files used in the update image
@@ -68,7 +68,7 @@  do_swupdate_image() {
             echo "$file".'${SWU_SIGNATURE_EXT}'
         fi
     done | cpio -ovL -H crc \
-        > '${DEPLOY_DIR_IMAGE}/${SWU_IMAGE_FILE}'
+        > '${SWU_IMAGE_FILE}'
     cd -
 }