diff mbox series

[isar-cip-core,Resend,2/4] scripts/deploy-cip-core.sh: Fix to correct filename with security extension

Message ID 20210510014011.66494-2-nobuhiro1.iwamatsu@toshiba.co.jp (mailing list archive)
State Handled Elsewhere
Headers show
Series [isar-cip-core,Resend,1/4] scripts/deploy-cip-core.sh: Fix uploading tar.gz image | expand

Commit Message

Nobuhiro Iwamatsu May 10, 2021, 1:40 a.m. UTC
Since security extension uses the bb file, not the extension using local.conf,
the generated filename is different.
This sets the correct filename for security extensions.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
---
 scripts/deploy-cip-core.sh | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/scripts/deploy-cip-core.sh b/scripts/deploy-cip-core.sh
index 3593d51..0b8bbe6 100755
--- a/scripts/deploy-cip-core.sh
+++ b/scripts/deploy-cip-core.sh
@@ -19,13 +19,19 @@  TARGET=$2
 EXTENSION=$3
 DTB=$4
 
-BASE_PATH=build/tmp/deploy/images/$TARGET/cip-core-image-cip-core-$RELEASE-$TARGET
+BASE_FILENAME=cip-core-image-cip-core-$RELEASE-$TARGET
 if [ "${EXTENSION}" != "base" ] ; then
-	BASE_PATH=build/tmp/deploy/images/$TARGET/cip-core-image-cip-core-$RELEASE-$TARGET-$EXTENSION
+	if [ "${EXTENSION}" = "security" ] ; then
+		BASE_FILENAME=cip-core-image-$EXTENSION-cip-core-$RELEASE-$TARGET
+	else
+		BASE_FILENAME=cip-core-image-cip-core-$RELEASE-$TARGET-$EXTENSION
+	fi
 fi
 
+BASE_PATH=build/tmp/deploy/images/$TARGET/$BASE_FILENAME
+
 if [ -f $BASE_PATH.wic.img ] ; then
-	echo "Compressing cip-core-image-cip-core-$RELEASE-$TARGET.wic.img..."
+	echo "Compressing $BASE_FILENAME.wic.img..."
 	xz -9 -k $BASE_PATH.wic.img
 
 	echo "Uploading artifacts..."