Last active
December 15, 2015 11:19
-
-
Save vencax/5252571 to your computer and use it in GitHub Desktop.
ffmpeg & libs installation from git repositories
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # | |
| # inpired by https://gist.github.com/faleev/3435377 | |
| # | |
| HEADLESS=1 | |
| echo "Remove system stuff if installed to avoid conflicts" | |
| sudo apt-get remove ffmpeg x264 libav-tools libvpx-dev libx264-dev | |
| echo "install all neccessary dev packages" | |
| sudo apt-get update | |
| PACKAGES="build-essential checkinstall git libfaac-dev libgpac-dev \ | |
| libmp3lame-dev libopencore-amrnb-dev libopencore-amrwb-dev librtmp-dev libtheora-dev \ | |
| libvorbis-dev pkg-config texi2html yasm zlib1g-dev" | |
| # PACKAGES+="TODO:which ones are non-headless???" | |
| sudo apt-get -y install $(PACKAGES) | |
| # neccessary libraries | |
| x264_SRC=https://gist.github.com/vencax/5252335/raw/c9619270955f2fb0eb73f7c7d87cd4a6dda62b8f/x264_from_gitsource.sh | |
| curl $(x264_SRC) | bash -x -s $1 | |
| fdk-aac_SRC=https://gist.github.com/vencax/5252448/raw/a94c73a0ab067e6d12de04de8c7f0ac0a3195837/fdk-aac_from_gitsource.sh | |
| curl $(fdk-aac_SRC) | bash -x -s $1 | |
| vpx_SRC=https://gist.github.com/vencax/5252456/raw/83f22300343dedc784b267939e58a8dac77c7a9f/libvpx_from_gitsource.sh | |
| curl $(vpx_SRC) | bash -x -s $1 | |
| ass_SRC=https://gist.github.com/vencax/5252545/raw/38ccb2bc2a76e09558611863a2d90d61070ff9c1/libass_from_gitsource.sh | |
| curl $(ass_SRC) | bash -x -s $1 | |
| # actual ffmpeg | |
| cd $1 | |
| git clone --depth 1 git://source.ffmpeg.org/ffmpeg | |
| cd ffmpeg | |
| OPTS="--enable-gpl --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb \ | |
| --enable-libopencore-amrwb --enable-librtmp --enable-libtheora --enable-libvorbis \ | |
| --enable-libvpx --enable-libx264 --enable-nonfree --enable-version3 --enable-libass" | |
| # OPTS+=--enable-x11grab | |
| ./configure $(OPTS) | |
| make | |
| sudo checkinstall --pkgname=ffmpeg --pkgversion="5:$(date +%Y%m%d%H%M)-git" --backup=no \ | |
| --deldoc=yes --fstrans=no --default | |
| hash x264 ffmpeg ffplay ffprobe |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment