From 227dcbcad8f99dc5765fffa7f4ac7182b89409a1 Mon Sep 17 00:00:00 2001 From: Leon Schuermann Date: Thu, 14 Nov 2024 15:53:26 -0500 Subject: [PATCH] lib/fetch-{libc++,newlib}: never overwrite files during unzip --- lib/fetch-libc++.sh | 3 ++- lib/fetch-newlib.sh | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/fetch-libc++.sh b/lib/fetch-libc++.sh index b2bdc0fbf..b07b59e9a 100755 --- a/lib/fetch-libc++.sh +++ b/lib/fetch-libc++.sh @@ -49,7 +49,8 @@ done if [[ $FOUND -ne 0 ]]; then echo "Unpacking $ZIP_FILE..." - unzip -q $ZIP_FILE + # -n: never overwrite existing files, -q: quiet mode + unzip -n -q $ZIP_FILE echo "Done upacking $ZIP_FILE..." else echo "ERROR: Unable to find tock-libc++" diff --git a/lib/fetch-newlib.sh b/lib/fetch-newlib.sh index 1c26f4c08..cbbd3feba 100755 --- a/lib/fetch-newlib.sh +++ b/lib/fetch-newlib.sh @@ -47,7 +47,8 @@ done if [[ $FOUND -ne 0 ]]; then echo "Unpacking $ZIP_FILE..." - unzip -q $ZIP_FILE + # -n: never overwrite existing files, -q: quiet mode + unzip -n -q $ZIP_FILE echo "Done upacking $ZIP_FILE..." else echo "ERROR: Unable to find tock-newlib"