FFmpeg-Builds/scripts.d/50-libvpx.sh

52 lines
1 KiB
Bash
Raw Normal View History

2020-09-04 16:45:25 +00:00
#!/bin/bash
LIBVPX_REPO="https://chromium.googlesource.com/webm/libvpx"
2021-04-03 23:09:54 +00:00
LIBVPX_COMMIT="8b3e575a45792fe490b5bc08c3fe08f01553756b"
2020-09-04 16:45:25 +00:00
ffbuild_enabled() {
return 0
}
ffbuild_dockerbuild() {
2020-09-05 20:34:23 +00:00
git-mini-clone "$LIBVPX_REPO" "$LIBVPX_COMMIT" libvpx
2020-09-04 16:45:25 +00:00
cd libvpx
local myconf=(
--disable-shared
--enable-static
--enable-pic
--disable-examples
--disable-tools
--disable-docs
2020-10-27 14:14:07 +00:00
--enable-vp9-highbitdepth
2020-09-04 16:45:25 +00:00
--prefix="$FFBUILD_PREFIX"
)
2020-09-27 20:10:05 +00:00
if [[ $TARGET == win64 ]]; then
2020-09-04 16:45:25 +00:00
myconf+=(
--target=x86_64-win64-gcc
)
export CROSS="$FFBUILD_CROSS_PREFIX"
2020-09-27 20:10:05 +00:00
elif [[ $TARGET == win32 ]]; then
myconf+=(
--target=x86-win32-gcc
)
export CROSS="$FFBUILD_CROSS_PREFIX"
elif [[ $TARGET != linux* ]]; then
2020-09-04 16:45:25 +00:00
echo "Unknown target"
return -1
fi
2021-04-04 21:20:31 +00:00
./configure "${myconf[@]}"
make -j$(nproc)
make install
2020-09-04 16:45:25 +00:00
}
ffbuild_configure() {
echo --enable-libvpx
}
ffbuild_unconfigure() {
echo --disable-libvpx
}