-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
earliest777
committed
Dec 29, 2021
1 parent
6279bb0
commit 358e485
Showing
1 changed file
with
54 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
#!/bin/bash | ||
case $(uname -s) in | ||
Linux*) machine=Linux;; | ||
Darwin*) machine=Mac;; | ||
CYGWIN*) machine=Cygwin;; | ||
MINGW*) machine=MinGw;; | ||
*) machine="UNKNOWN" | ||
esac | ||
|
||
MAC_DOWNLOAD_URL="https://www.bok.net/Bento4/binaries/Bento4-SDK-1-6-0-639.universal-apple-macosx.zip" | ||
LINUX_DOWNLOAD_URL="https://www.bok.net/Bento4/binaries/Bento4-SDK-1-6-0-639.x86_64-unknown-linux.zip" | ||
WIN_DOWNLOAD_URL="https://www.bok.net/Bento4/binaries/Bento4-SDK-1-6-0-639.x86_64-microsoft-win32.zip" | ||
|
||
if [ "$machine" = "UNKNOWN" ]; then | ||
echo "Unkown OS Detected" | ||
exit 1 | ||
fi | ||
|
||
echo "Cloning in ${PWD}/tools" | ||
rm -rf tools | ||
mkdir tools | ||
cd tools | ||
|
||
if [ "$machine" = "Mac" ]; then | ||
echo "Mac detected 💻"; | ||
curl -fsSL $MAC_DOWNLOAD_URL -o Bento4-SDK.zip; | ||
echo "Extracting Zip ... 📁" | ||
unzip -q -o Bento4-SDK.zip; | ||
echo "Final Cleanup 🗑️" | ||
mv Bento4-SDK-*/ Bento4-SDK/; | ||
rm -rf Bento4-SDK.zip | ||
echo "Installed Bento4 SDK in ${PWD}/Bento4-SDK"; | ||
|
||
elif [ "$machine" = "Linux" ]; then | ||
echo "Linux detected 💻" | ||
curl -fsSL $LINUX_DOWNLOAD_URL -o Bento4-SDK.zip; | ||
echo "Extracting Zip ... 📁" | ||
unzip -q -o Bento4-SDK.zip; | ||
echo "Final Cleanup 🗑️" | ||
mv Bento4-SDK-*/ Bento4-SDK/; | ||
rm -rf Bento4-SDK.zip | ||
echo "Installed Bento4 SDK in ${PWD}/Bento4-SDK"; | ||
|
||
else | ||
echo "Windows detected 💻" | ||
curl -fsSL $WIN_DOWNLOAD_URL -o Bento4-SDK.zip; | ||
echo "Extracting Zip ... 📁" | ||
unzip -q -o Bento4-SDK.zip; | ||
echo "Final Cleanup 🗑️" | ||
mv Bento4-SDK-*/ Bento4-SDK/; | ||
rm -rf Bento4-SDK.zip | ||
echo "Installed Bento4 SDK in ${PWD}/Bento4-SDK"; | ||
|
||
fi |