123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869 |
- #!/bin/bash
- SCRIPT_REPO="https://code.videolan.org/videolan/libplacebo.git"
- SCRIPT_COMMIT="118d8106640796d3f2ceb55f8634a32a58a47aa2"
- ffbuild_enabled() {
- [[ $ADDINS_STR == *4.4* ]] && return -1
- [[ $ADDINS_STR == *5.0* ]] && return -1
- [[ $ADDINS_STR == *5.1* ]] && return -1
- [[ $ADDINS_STR == *6.0* ]] && return -1
- return 0
- }
- ffbuild_dockerdl() {
- default_dl .
- echo "git submodule update --init --recursive"
- }
- ffbuild_dockerbuild() {
- sed -i 's/DPL_EXPORT/DPL_STATIC/' src/meson.build
- mkdir build && cd build
- local myconf=(
- --prefix="$FFBUILD_PREFIX"
- --buildtype=release
- --default-library=static
- -Dvulkan=enabled
- -Dvk-proc-addr=disabled
- -Dvulkan-registry="$FFBUILD_PREFIX"/share/vulkan/registry/vk.xml
- -Dshaderc=enabled
- -Dglslang=disabled
- -Ddemos=false
- -Dtests=false
- -Dbench=false
- -Dfuzz=false
- )
- if [[ $TARGET == win* ]]; then
- myconf+=(
- -Dd3d11=enabled
- )
- fi
- if [[ $TARGET == win* || $TARGET == linux* ]]; then
- myconf+=(
- --cross-file=/cross.meson
- )
- else
- echo "Unknown target"
- return -1
- fi
- meson "${myconf[@]}" ..
- ninja -j$(nproc)
- ninja install
- echo "Libs.private: -lstdc++" >> "$FFBUILD_PREFIX"/lib/pkgconfig/libplacebo.pc
- }
- ffbuild_configure() {
- echo --enable-libplacebo
- }
- ffbuild_unconfigure() {
- [[ $ADDINS_STR == *4.4* ]] && return 0
- echo --disable-libplacebo
- }
|