30-libdvdcss.sh 979 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #!/bin/bash
  2. SCRIPT_REPO="https://code.videolan.org/videolan/libdvdcss.git"
  3. SCRIPT_COMMIT="d0b6a291c24eda3727ad5c7a14956fc1fc82446d"
  4. ffbuild_enabled() {
  5. [[ $VARIANT == lgpl* ]] && return -1
  6. [[ $ADDINS_STR == *4.4* ]] && return -1
  7. [[ $ADDINS_STR == *5.0* ]] && return -1
  8. [[ $ADDINS_STR == *5.1* ]] && return -1
  9. [[ $ADDINS_STR == *6.0* ]] && return -1
  10. [[ $ADDINS_STR == *6.1* ]] && return -1
  11. return 0
  12. }
  13. ffbuild_dockerbuild() {
  14. autoreconf -i
  15. local myconf=(
  16. --prefix="$FFBUILD_PREFIX"
  17. --disable-shared
  18. --enable-static
  19. --with-pic
  20. --disable-doc
  21. )
  22. if [[ $TARGET == win* || $TARGET == linux* ]]; then
  23. myconf+=(
  24. --host="$FFBUILD_TOOLCHAIN"
  25. )
  26. else
  27. echo "Unknown target"
  28. return -1
  29. fi
  30. export CFLAGS="$CFLAGS -Dprint_error=dvdcss_print_error -Dprint_debug=dvdcss_print_debug"
  31. ./configure "${myconf[@]}"
  32. make -j$(nproc)
  33. make install
  34. }