50-libass.sh 758 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. #!/bin/bash
  2. SCRIPT_REPO="https://github.com/libass/libass.git"
  3. SCRIPT_COMMIT="1b699559025185e34d21a24cac477ca360cb917d"
  4. ffbuild_enabled() {
  5. return 0
  6. }
  7. ffbuild_dockerbuild() {
  8. ./autogen.sh
  9. local myconf=(
  10. --prefix="$FFBUILD_PREFIX"
  11. --disable-shared
  12. --enable-static
  13. --with-pic
  14. )
  15. if [[ $TARGET == win* || $TARGET == linux* ]]; then
  16. myconf+=(
  17. --host="$FFBUILD_TOOLCHAIN"
  18. )
  19. else
  20. echo "Unknown target"
  21. return -1
  22. fi
  23. export CFLAGS="$CFLAGS -Dread_file=libass_internal_read_file"
  24. ./configure "${myconf[@]}"
  25. make -j$(nproc)
  26. make install
  27. }
  28. ffbuild_configure() {
  29. echo --enable-libass
  30. }
  31. ffbuild_unconfigure() {
  32. echo --disable-libass
  33. }