Last active
October 10, 2015 20:38
-
-
Save valtoni/3747390 to your computer and use it in GitHub Desktop.
Script to install new ffmpeg in MACOSX (Mountain Lion)
This file contains 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 | |
WORK_DIR=~/temp_ffmpeg | |
LAME_DIR=$WORK_DIR/lame | |
FAAC_DIR=$WORK_DIR/faac-1.28 | |
FAAD2_DIR=$WORK_DIR/faad2-2.7 | |
AUTOCONF_DIR=$WORK_DIR/autoconf-2.69 | |
AUTOMAKE_DIR=$WORK_DIR/automake-1.12.4 | |
YASM_DIR=$WORK_DIR/yasm | |
FFMPEG_DIR=$WORK_DIR/ffmpeg | |
function autogenbuild { | |
DIRB=$1 | |
cd $DIRB | |
./autogen.sh | |
build $DIRB | |
} | |
function build { | |
DIRB=$1 | |
cd $DIRB | |
./configure | |
make | |
sudo make install | |
} | |
echo "Building ffmpeg from svn last version in MAC OSX MOUNTAIN LION" | |
mkdir $WORK_DIR | |
echo "Downloading components..." | |
git clone https://github.com/rbrito/lame.git $LAME_DIR | |
curl -L -o $WORK_DIR/faac-1.28.tar.gz http://downloads.sourceforge.net/project/faac/faac-src/faac-1.28/faac-1.28.tar.gz | |
curl -L -o $WORK_DIR/faad2-2.7.tar.gz http://downloads.sourceforge.net/project/faac/faad2-src/faad2-2.7/faad2-2.7.tar.gz | |
curl -L -o $WORK_DIR/autoconf-2.69.tar.gz ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.69.tar.gz | |
curl -L -o $WORK_DIR/automake-1.12.4.tar.gz ftp://ftp.gnu.org/gnu/automake/automake-1.12.4.tar.gz | |
git clone https://github.com/yasm/yasm.git $YASM_DIR | |
git clone https://github.com/FFmpeg/FFmpeg.git $FFMPEG_DIR | |
echo "Unpacking..." | |
tar zxf $WORK_DIR/faac-1.28.tar.gz -C $WORK_DIR | |
tar zxf $WORK_DIR/faad2-2.7.tar.gz -C $WORK_DIR | |
tar zxf $WORK_DIR/autoconf-2.69.tar.gz -C $WORK_DIR | |
tar zxf $WORK_DIR/automake-1.12.4.tar.gz -C $WORK_DIR | |
echo "Lame build" | |
build $LAME_DIR | |
echo "faac build" | |
build $FAAC_DIR | |
echo "faad2 build" | |
build $FAAD2_DIR | |
echo "autoconf build" | |
build $AUTOCONF_DIR | |
echo "automake build" | |
build $AUTOMAKE_DIR | |
echo "Yasm build" | |
autogenbuild $YASM_DIR | |
echo "Ffmpeg build" | |
build $FFMPEG_DIR |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment