summaryrefslogtreecommitdiffstats
path: root/meta/files
diff options
context:
space:
mode:
Diffstat (limited to 'meta/files')
-rw-r--r--meta/files/toolchain-shar-extract.sh22
1 files changed, 20 insertions, 2 deletions
diff --git a/meta/files/toolchain-shar-extract.sh b/meta/files/toolchain-shar-extract.sh
index 156085b500..ccc4f4e1ac 100644
--- a/meta/files/toolchain-shar-extract.sh
+++ b/meta/files/toolchain-shar-extract.sh
@@ -113,7 +113,16 @@ done
113 113
114payload_offset=$(($(grep -na -m1 "^MARKER:$" $0|cut -d':' -f1) + 1)) 114payload_offset=$(($(grep -na -m1 "^MARKER:$" $0|cut -d':' -f1) + 1))
115if [ "$listcontents" = "1" ] ; then 115if [ "$listcontents" = "1" ] ; then
116 tail -n +$payload_offset $0| tar tvJ || exit 1 116 if [ @SDK_ARCHIVE_TYPE@ = "zip" ]; then
117 tail -n +$payload_offset $0 > sdk.zip
118 if unzip -l sdk.zip;then
119 rm sdk.zip
120 else
121 rm sdk.zip && exit 1
122 fi
123 else
124 tail -n +$payload_offset $0| tar tvJ || exit 1
125 fi
117 exit 126 exit
118fi 127fi
119 128
@@ -232,7 +241,16 @@ if [ ! -x $target_sdk_dir -o ! -w $target_sdk_dir -o ! -r $target_sdk_dir ]; the
232fi 241fi
233 242
234printf "Extracting SDK..." 243printf "Extracting SDK..."
235tail -n +$payload_offset $0| $SUDO_EXEC tar xJ -C $target_sdk_dir --checkpoint=.2500 $EXTRA_TAR_OPTIONS || exit 1 244if [ @SDK_ARCHIVE_TYPE@ = "zip" ]; then
245 tail -n +$payload_offset $0 > sdk.zip
246 if $SUDO_EXEC unzip $EXTRA_TAR_OPTIONS sdk.zip -d $target_sdk_dir;then
247 rm sdk.zip
248 else
249 rm sdk.zip && exit 1
250 fi
251else
252 tail -n +$payload_offset $0| $SUDO_EXEC tar xJ -C $target_sdk_dir --checkpoint=.2500 $EXTRA_TAR_OPTIONS || exit 1
253fi
236echo "done" 254echo "done"
237 255
238printf "Setting it up..." 256printf "Setting it up..."