web-install-outsider.sh 858 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #!/bin/sh
  2. make_dir () {
  3. if [ ! -d $1 ]; then
  4. if ! mkdir $1; then
  5. printf "\n Failed to create dir %s" "$1";
  6. exit 1
  7. fi
  8. fi
  9. }
  10. command_exists() {
  11. if ! [[ -x $(command -v "$1") ]]; then
  12. return 1
  13. fi
  14. return 0
  15. }
  16. TARGET='ffmpeg-build'
  17. if ! command_exists "curl"; then
  18. echo "curl not installed.";
  19. exit 1
  20. fi
  21. echo "4dage ffmpeg-build-script-downloader v0.1"
  22. echo "========================================="
  23. echo ""
  24. echo "First we create the ffmpeg build directory $TARGET"
  25. make_dir $TARGET
  26. cd $TARGET
  27. echo "Now we download and execute the build script"
  28. echo ""
  29. bash <(curl -s http://git.nps.gemer.xyz/zhangyupeng/4dage-ffmpeg/raw/master/install-4dage-ousider)
  30. bash <(curl -s http://git.nps.gemer.xyz/zhangyupeng/4dage-ffmpeg/raw/master/install-ffmpeg-ousider) --build