Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

81 line
3.1KB

  1. SHELL:=/bin/bash
  2. ubuntu1804:
  3. # sometimes got 404 on videolan/x264
  4. #git clone https://code.videolan.org/videolan/x264
  5. #git clone git://source.ffmpeg.org/ffmpeg.git
  6. # for this reason pushed them to my own github
  7. git clone https://github.com/rayburgemeestre/x264
  8. git clone https://github.com/rayburgemeestre/ffmpeg
  9. bash ../ubuntu1804.sh make ffmpeg_impl
  10. make package-ubuntu1804
  11. ubuntu2004:
  12. git clone https://code.videolan.org/videolan/x264
  13. git clone git://source.ffmpeg.org/ffmpeg.git
  14. bash ../ubuntu2004.sh make ffmpeg_impl
  15. make package-ubuntu2004
  16. bash ../ubuntu2004.sh chown $$(id -u):$$(id -g) . -R # fix permissions
  17. ffmpeg_impl:
  18. apt-get update
  19. sudo apt-get install -y yasm
  20. sudo apt-get install -y nasm # apparently x264 switched to this
  21. mkdir x264_out
  22. mkdir ffmpeg_out
  23. pushd x264 && \
  24. git checkout 2451a7282463f68e532f2eee090a70ab139bb3e7
  25. # ^ parent of 71ed44c7312438fac7c5c5301e45522e57127db4, which is where they dropped support for:
  26. # libavcodec/libx264.c:282:9: error: 'x264_bit_depth' undeclared (first use in this function); did you mean 'x264_picture_t'?
  27. # if (x264_bit_depth > 8)
  28. # ^~~~~~~~~~~~~~
  29. pushd x264 && \
  30. ./configure --cxx=$$(which c++) --enable-static --enable-shared --prefix=$$(realpath $$PWD/../x264_out) && \
  31. make -j $$(nproc) && \
  32. make install
  33. pushd x264 && \
  34. ./configure --cxx=$$(which c++) --enable-static --enable-shared && \
  35. make -j $$(nproc) && \
  36. make install
  37. pushd ffmpeg && git checkout n3.1
  38. #git checkout 71052d85c16bd65fa1e3e01d9040f9a3925efd7a # or my muxing code won't work, they've modified the example since fba1592f35501bff0f28d7885f4128dfc7b82777
  39. pushd ffmpeg && \
  40. ./configure --cxx=$$(which c++) --enable-static --enable-shared --enable-libx264 --enable-gpl --disable-swresample --prefix=$$(realpath $$PWD/../ffmpeg_out) && \
  41. make -j $$(nproc) && \
  42. make install
  43. package-ubuntu1804:
  44. rm -rf out
  45. mkdir -p out/opt/cppse/build/x264
  46. mkdir -p out/opt/cppse/build/ffmpeg
  47. cp -prv ./x264_out/* out/opt/cppse/build/x264/
  48. cp -prv ./ffmpeg_out/* out/opt/cppse/build/ffmpeg/
  49. rm -rf cppseffmpeg_*_amd64.deb
  50. docker run -v "$$(pwd):/src/" rayburgemeestre/fpm-ubuntu:18.04 fpm -v 1.1 -s dir -t deb -n cppseffmpeg --license MPL2 --maintainer "Ray Burgemeestre <ray@cppse.nl>" --description "ffmpeg - build dependency" --url "https://gitea.cppse.nl/rayburgemeestre/build-config/src/branch/master/ffmpeg" --deb-generate-changes -C /src/out
  51. package-ubuntu2004:
  52. rm -rf out
  53. mkdir -p out/opt/cppse/build/x264
  54. mkdir -p out/opt/cppse/build/ffmpeg
  55. cp -prv ./x264_out/* out/opt/cppse/build/x264/
  56. cp -prv ./ffmpeg_out/* out/opt/cppse/build/ffmpeg/
  57. rm -rf cppseffmpeg_*_amd64.deb
  58. docker run -v "$$(pwd):/src/" rayburgemeestre/fpm-ubuntu:20.04 fpm -v 1.1 -s dir -t deb -n cppseffmpeg --license MPL2 --maintainer "Ray Burgemeestre <ray@cppse.nl>" --description "ffmpeg - build dependency" --url "https://gitea.cppse.nl/rayburgemeestre/build-config/src/branch/master/ffmpeg" --deb-generate-changes -C /src/out
  59. clean:
  60. rm -rf x264
  61. rm -rf ffmpeg
  62. rm -rf out
  63. rm -rf x264_out
  64. rm -rf ffmpeg_out
  65. shell:
  66. FLAGS="-i --privileged" bash ../ubuntu1804.sh /bin/bash