extract_firmware: Unsparse images before copying
Some OEMs like motorola ship sparse images which can't be flashed as-is Change-Id: I6f5a7e058e02167c242b0a5053fa4f6cc3a351ea
This commit is contained in:
@@ -1969,6 +1969,10 @@ function extract_firmware() {
|
||||
elif [ -f "$SRC/$DST_FILE" ]; then
|
||||
COPY_FILE="$SRC/$DST_FILE"
|
||||
fi
|
||||
if [[ $(file -b "$COPY_FILE") == Android* ]]; then
|
||||
"$SIMG2IMG" "$COPY_FILE" "$SRC"/"$(basename "$COPY_FILE").raw"
|
||||
COPY_FILE="$SRC"/"$(basename "$COPY_FILE").raw"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -f "$COPY_FILE" ]; then
|
||||
|
||||
Reference in New Issue
Block a user