Last active
April 10, 2019 17:18
-
-
Save sergiks/fa03930b149f82a6dceb6f60980d3961 to your computer and use it in GitHub Desktop.
Compile ffmpeg and ffprobe for AWS Lambda
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 | |
############################################ | |
# | |
# Compile ffmpeg and ffprobe for AWS Lambda | |
# | |
# Run this on a fresh AWS EC2 instance | |
# running same AMI as AWS Lambda: | |
# https://docs.aws.amazon.com/lambda/latest/dg/current-supported-versions.html | |
# AMI: amzn-ami-hvm-2017.03.1.20170812-x86_64-gp2 | |
# https://console.aws.amazon.com/ec2/v2/home#Images:visibility=public-images;search=amzn-ami-hvm-2017.03.1.20170812-x86_64-gp2 | |
# | |
############################################ | |
## Skip update as it upgrades to 2018.03 version, | |
## but AWS Lambda lists older 2017.03 | |
# sudo yum update -y | |
sudo yum groupinstall -y "Development Tools" "Development Libraries" | |
git clone https://github.com/markus-perl/ffmpeg-build-script.git | |
cd ffmpeg-build-script/ | |
## disable aom codec - i fails for some reason | |
sed -i 's/--enable-libaom/--disable-libaom/' build-ffmpeg | |
## Compilation takes ~90 minutes on AWS EC2 t2.micro instance | |
sudo nohup ./build-ffmpeg --build & |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Main compilation script is markus-perl/ffmpeg-build-script
It only supports builds for
Mac OSX 10.14 64Bit XCode 10.1
andDebian 9.4
so here I introduced a little tweak disablinglibaom
which was failing.