2022-01-29 13:08:49 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
set -e
|
|
|
|
DIR=$(dirname ${BASH_SOURCE[0]})
|
|
|
|
cd "$DIR"
|
|
|
|
. common
|
|
|
|
mkdir -p "$PREBUILT_DATA_DIR"
|
|
|
|
cd "$PREBUILT_DATA_DIR"
|
|
|
|
|
2022-12-22 11:33:08 +00:00
|
|
|
VERSION=5.1.2
|
2022-04-28 17:32:14 +00:00
|
|
|
DEP_DIR=ffmpeg-win64-$VERSION
|
2022-01-29 13:08:49 +00:00
|
|
|
|
2022-04-28 17:32:14 +00:00
|
|
|
FILENAME=ffmpeg-$VERSION-full_build-shared.7z
|
2022-12-22 11:33:08 +00:00
|
|
|
SHA256SUM=d9eb97b72d7cfdae4d0f7eaea59ccffb8c364d67d88018ea715d5e2e193f00e9
|
2022-01-29 13:08:49 +00:00
|
|
|
|
|
|
|
if [[ -d "$DEP_DIR" ]]
|
|
|
|
then
|
|
|
|
echo "$DEP_DIR" found
|
|
|
|
exit 0
|
|
|
|
fi
|
|
|
|
|
2022-04-28 17:32:14 +00:00
|
|
|
get_file "https://github.com/GyanD/codexffmpeg/releases/download/$VERSION/$FILENAME" \
|
2022-01-29 13:08:49 +00:00
|
|
|
"$FILENAME" "$SHA256SUM"
|
|
|
|
|
|
|
|
mkdir "$DEP_DIR"
|
|
|
|
cd "$DEP_DIR"
|
|
|
|
|
2022-04-28 17:32:14 +00:00
|
|
|
ZIP_PREFIX=ffmpeg-$VERSION-full_build-shared
|
2022-01-29 13:08:49 +00:00
|
|
|
7z x "../$FILENAME" \
|
|
|
|
"$ZIP_PREFIX"/bin/avutil-57.dll \
|
|
|
|
"$ZIP_PREFIX"/bin/avcodec-59.dll \
|
|
|
|
"$ZIP_PREFIX"/bin/avformat-59.dll \
|
|
|
|
"$ZIP_PREFIX"/bin/swresample-4.dll \
|
|
|
|
"$ZIP_PREFIX"/bin/swscale-6.dll \
|
|
|
|
"$ZIP_PREFIX"/include
|
|
|
|
mv "$ZIP_PREFIX"/* .
|
|
|
|
rmdir "$ZIP_PREFIX"
|