Browse Source

olinux: remove tarbal extract tree if present (and check path, this command is relative to target)

Sebastien Badia 10 years ago
parent
commit
ff83121f02
1 changed files with 1 additions and 0 deletions
  1. 1 0
      olinux/create_sunxi_boot_files.sh

+ 1 - 0
olinux/create_sunxi_boot_files.sh

@@ -74,6 +74,7 @@ fetch (){
   name=$(echo $project |  sed 's/.git$//')
   if [ ${TARBALL} ] ; then
     cd ${TARGET}
+    [ -d ${name} ] && rm -rf "${name:?}/"*
     archive=$(basename $tarball_url)
     format=$(basename "${archive##*.}")
     case $format in