59 lines
1.2 KiB
Bash
Executable file
59 lines
1.2 KiB
Bash
Executable file
#!/bin/bash
|
|
|
|
LIBVPX_REPO="https://chromium.googlesource.com/webm/libvpx"
|
|
LIBVPX_COMMIT="02392eecccde436a76aca6c86a6fdf643e98eb38"
|
|
|
|
ffbuild_enabled() {
|
|
return 0
|
|
}
|
|
|
|
ffbuild_dockerstage() {
|
|
to_df "ADD $SELF /stage.sh"
|
|
to_df "RUN run_stage"
|
|
}
|
|
|
|
ffbuild_dockerbuild() {
|
|
git-mini-clone "$LIBVPX_REPO" "$LIBVPX_COMMIT" libvpx
|
|
cd libvpx
|
|
|
|
local myconf=(
|
|
--disable-shared
|
|
--enable-static
|
|
--enable-pic
|
|
--disable-examples
|
|
--disable-tools
|
|
--disable-docs
|
|
--enable-vp9-highbitdepth
|
|
--prefix="$FFBUILD_PREFIX"
|
|
)
|
|
|
|
if [[ $TARGET == win64 ]]; then
|
|
myconf+=(
|
|
--target=x86_64-win64-gcc
|
|
)
|
|
export CROSS="$FFBUILD_CROSS_PREFIX"
|
|
elif [[ $TARGET == win32 ]]; then
|
|
myconf+=(
|
|
--target=x86-win32-gcc
|
|
)
|
|
export CROSS="$FFBUILD_CROSS_PREFIX"
|
|
else
|
|
echo "Unknown target"
|
|
return -1
|
|
fi
|
|
|
|
./configure "${myconf[@]}" || return -1
|
|
make -j$(nproc) || return -1
|
|
make install || return -1
|
|
|
|
cd ..
|
|
rm -rf libvpx
|
|
}
|
|
|
|
ffbuild_configure() {
|
|
echo --enable-libvpx
|
|
}
|
|
|
|
ffbuild_unconfigure() {
|
|
echo --disable-libvpx
|
|
}
|