Installing FFmpeg on Linux and Windows is comparatively easy but complications arise when you are doing that on Mac OS. While there are plenty of methods available for installing it on Mac, in this blog, you’ll know how it install it through an exclusive linux based software called Homebrew. Download and install: Click to download and install the latest version of ffmpegX for MacOSX 10.2-10.14. Mailing list: If you want to receive an email when ffmpegX is updated, sign up to the mailing list by entering your email address here.
1. Download ffmpeg source code
Open the MAC console, switch to the directory where you want to save the source code, and execute
git clone https://git.ffmpeg.org/ffmpeg.git
Command to download source code.Download Ffmpeg Mac Terminal
2. Enter the ffmpeg directory
The source code is downloaded and executed
cd /ffmpeg
Command, switch toffmpegUnder the directory, you will see the following.3. Execute the following commands for compilation and installation
3.1 Configuration of ffmpeg
Ffmpeg Download Mac Os X
![Ffmpeg Ffmpeg](/uploads/1/2/6/5/126504973/384083613.jpg)
stayffmpegThe following commands are executed under the directory to configure ffmpeg before compilation.
./configure –prefix=/usr/local/ffmpeg –enable-gpl –enable-nonfree –enable-libfdk-aac –enable-libx264 –enable-libx265 –enable-filter=delogo –enable-debug –disable-optimizations –enable-libspeex –enable-videotoolbox –enable-shared –enable-pthreads –enable-version3 –enable-hardcoded-tables –cc=clang –host-cflags= –host-ldflags= –disable-x86asm
Configuration will report errors, this time do not panic, generally lack of libraries, check the error information, what libraries do, usebrew install XXXInstallation is enough.
If an error is reported when configuring, see this article
3.2 Compilation
Once the configuration is successful, it’s time to compile ffmpeg.
In the ffmpeg directory, executemakeThe command is compiled.
Warm hint, this step needs to wait a little longer, patiently wait for compilation to complete before proceeding to the next step.
In the ffmpeg directory, executemakeThe command is compiled.
Warm hint, this step needs to wait a little longer, patiently wait for compilation to complete before proceeding to the next step.
3.3 Installation of ffmpeg
Or in the ffmpeg directory, executesudo make installCommand to install ffmpeg.
After installation, switch to/usr/local/ffmpeg/binDirectory, if bin directory hasffmpeg、ffmplay、ffprobeThree catalogues. Congratulations, your ffmpeg installation is successful.
After installation, switch to/usr/local/ffmpeg/binDirectory, if bin directory hasffmpeg、ffmplay、ffprobeThree catalogues. Congratulations, your ffmpeg installation is successful.
![Mac Mac](/uploads/1/2/6/5/126504973/778059220.jpg)
Knock on the blackboard!!! Watch out!
If the directory is missingffmplayThat’s because of lackSDL2Libraries, resulting in no compilation ffmplay, this time we need to install sdl2. Execute under ffmpeg directorybrew install sdl2。 After the installation is completed, it is executed again in turn.3.1、3.2、3.3The order.
If the directory is missingffmplayThat’s because of lackSDL2Libraries, resulting in no compilation ffmplay, this time we need to install sdl2. Execute under ffmpeg directorybrew install sdl2。 After the installation is completed, it is executed again in turn.3.1、3.2、3.3The order.
If/usr/local/ffmpeg/binIn the catalog, you seeffmpeg、ffmplay、ffprobeThree directories, then the installation is really successful, can open your ffmpeg learning path.