-
-
Save clayton/6196167 to your computer and use it in GitHub Desktop.
# Installation | |
brew install ffmpeg --with-vpx --with-vorbis --with-libvorbis --with-vpx --with-vorbis --with-theora --with-libogg --with-libvorbis --with-gpl --with-version3 --with-nonfree --with-postproc --with-libaacplus --with-libass --with-libcelt --with-libfaac --with-libfdk-aac --with-libfreetype --with-libmp3lame --with-libopencore-amrnb --with-libopencore-amrwb --with-libopenjpeg --with-openssl --with-libopus --with-libschroedinger --with-libspeex --with-libtheora --with-libvo-aacenc --with-libvorbis --with-libvpx --with-libx264 --with-libxvid | |
# Easy Peasy | |
ffmpeg -i video.mp4 video.webm |
As of this post, the latest version of ffmpeg is 4.1.
I was getting errors about options being invalid. I tried some here, and the cool one liners, but none worked. I just did brew options ffmpeg
, copied the results, and cleaned it up.
Here is the result for anyone who needs it and in the same boat:
brew install ffmpeg --with-aom \
--with-chromaprint \
--with-fdk-aac \
--with-fontconfig \
--with-freetype \
--with-frei0r \
--with-game-music-emu \
--with-libass \
--with-libbluray \
--with-libbs2b \
--with-libcaca \
--with-libgsm \
--with-libmodplug \
--with-librsvg \
--with-libsoxr \
--with-libssh \
--with-libvidstab \
--with-libvmaf \
--with-opencore-amr \
--with-openh264 \
--with-openjpeg \
--with-openssl \
--with-rtmpdump \
--with-rubberband \
--with-speex \
--with-srt \
--with-tesseract \
--with-two-lame \
--with-wavpack \
--with-webp \
--with-zeromq \
--with-zimg
Thanks, @WadeShuler. This worked for me. It did not work when issued as a reinstall, however. I didn't bother to investigate why, I most likely had an older version lying around conflicting with 4.1 as this specific system has been through many os updates. If you run into similar issues a clean install of the package should fix it.
Looks like with Homebrew 2.0.3/ffmpeg 4.1.1 ffmpeg options are no longer available on the default tap.
I have followed guide on https://trac.ffmpeg.org/wiki/CompilationGuide/macOS Additional options to compile ffmpeg with additional options.:
brew tap varenc/ffmpeg
brew tap-pin varenc/ffmpeg
brew install ffmpeg $(brew options ffmpeg --compact)
Looks like with Homebrew 2.0.3/ffmpeg 4.1.1 ffmpeg options are no longer available on the default tap.
I have followed guide on https://trac.ffmpeg.org/wiki/CompilationGuide/macOS Additional options to compile ffmpeg with additional options.:
brew tap varenc/ffmpeg brew tap-pin varenc/ffmpeg brew install ffmpeg $(brew options ffmpeg --compact)
Help please - Error: invalid option: --with-libvidstab
.
I've done brew install libvidstab
and reinstalled ffmpeg, no good. Still same error.
Does brew install varenc/ffmpeg/ffmpeg $(brew options ffmpeg --compact)
work now?
^ "sakalauskas" approach from on Mar 5 seems to have worked for me on Mojave mac.
:( not for me.
==> ./configure --prefix=/usr/local/Cellar/ffmpeg/4.1.3-with-options --enable-shared --enable-hardcoded-tables --cc=clang --host-cflags=-I/Library/Java/JavaVirtualMachines/openjdk-11.0.1.jdk/Contents/Home/include -I/Library
Last 15 lines from /Users/eddyk/Library/Logs/Homebrew/ffmpeg/01.configure:
--extra-ldflags=-L/usr/local/include
--enable-version3
--enable-libopencore-amrnb
--enable-libopencore-amrwb
--enable-libopenjpeg
--disable-decoder=jpeg2000
--extra-cflags=-I/usr/local/Cellar/openjpeg/2.3.1/include/openjpeg-2.3
ERROR: DeckLinkAPI.h not found
on mojave 10.14.5
Looks like with Homebrew 2.0.3/ffmpeg 4.1.1 ffmpeg options are no longer available on the default tap.
I have followed guide on https://trac.ffmpeg.org/wiki/CompilationGuide/macOS Additional options to compile ffmpeg with additional options.:
brew tap varenc/ffmpeg brew tap-pin varenc/ffmpeg brew install ffmpeg $(brew options ffmpeg --compact)
Thankyou, this one solved my problem, if you got an error probably its from dependency that not yet installed,
in my case, i'm missing decklink sdk (ERROR: DeckLinkAPI.h not found) so i go to install decklink sdk brew install amiaopensource/amiaos/decklinksdk
and everything worked.
https://github.com/varenc/homebrew-ffmpeg
⚠️ Note: This tap is currently not actively maintained. For an up-to-date tap, see homebrew-ffmpeg.
So, I installed using homebrew-ffmpeg, with the instructions there. I wanted to install all of the options, but decklink
had an issue. I don't even know what decklink
is, so I just copy/pasted the options output by brew options ffmpeg --compact
and removed decklink
.
https://github.com/homebrew-ffmpeg/homebrew-ffmpeg#installation-and-usage
brew tap homebrew-ffmpeg/ffmpeg
brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-chromaprint /
--with-fdk-aac /
--with-game-music-emu /
--with-libbluray /
--with-libbs2b /
--with-libcaca /
--with-libgsm /
--with-libmodplug /
--with-librsvg /
--with-libsoxr /
--with-libssh /
--with-libvidstab /
--with-libvmaf /
--with-libxml2 /
--with-opencore-amr /
--with-openh264 /
--with-openjpeg /
--with-openssl /
--with-rtmpdump /
--with-rubberband /
--with-speex /
--with-srt /
--with-tesseract /
--with-two-lame /
--with-wavpack /
--with-webp /
--with-xvid /
--with-zeromq /
--with-zimg
EDIT: Oh, it looks like @ixna solved the decklink problem above by installing the deps, so you could do that first and the one liner should work. 🤷♂️
Doesn't seem to work now... Does this work?
brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-chromaprint --with-decklink --with-fdk-aac --with-game-music-emu --with-libbluray --with-libbs2b --with-libcaca --with-libgsm --with-libmodplug --with-librsvg --with-libsoxr --with-libssh --with-libvidstab --with-libvmaf --with-libxml2 --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rtmpdump --with-rubberband --with-speex --with-srt --with-tesseract --with-two-lame --with-wavpack --with-webp --with-xvid --with-zeromq --with-zimg```
I got the following to work (comments from prior months did not work):
brew tap homebrew-ffmpeg/ffmpeg && brew install homebrew-ffmpeg/ffmpeg/ffmpeg && ffmpeg —help
benedictchen’s command doesn’t work for me. I first got an error about a circular dependency that I fixed by temporarily commenting-out the line with ffmpeg
in brew edit chromaprint
; then I got an error about DeckLinkAPI.h
that I fixed with brew install amiaopensource/amiaos/decklinksdk
. Now ffmpeg
is installed, but every time I run it I get this error:
$ ffmpeg --version
dyld: Library not loaded: @rpath/libclang_rt.ubsan_osx_dynamic.dylib
Referenced from: /usr/local/opt/game-music-emu/lib/libgme.0.dylib
Reason: image not found
Abort trap: 6
To be install ffmpeg as completely as possible without throwing errors, I eventually came to this:
brew install tesseract-lang && brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-fdk-aac --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rubberband --with-webp --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-game-music-emu --with-libbluray --with-libbs2b --with-libcaca --with-libgsm --with-libmodplug --with-openssl@1.1 --with-rtmpdump --with-speex --with-two-lame --with-wavpack --with-xvid
That is missing only two extensions: --with-chromaprint --with-decklink
I get the same error as @bfontaine.
@brookjordan's command did the trick
To be install ffmpeg as completely as possible without throwing errors, I eventually came to this:
brew install tesseract-lang && brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-fdk-aac --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rubberband --with-webp --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-game-music-emu --with-libbluray --with-libbs2b --with-libcaca --with-libgsm --with-libmodplug --with-openssl@1.1 --with-rtmpdump --with-speex --with-two-lame --with-wavpack --with-xvid
That is missing only two extensions:
--with-chromaprint --with-decklink
@brookjordan's command did the trick
To be install ffmpeg as completely as possible without throwing errors, I eventually came to this:
brew install tesseract-lang && brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-fdk-aac --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rubberband --with-webp --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-game-music-emu --with-libbluray --with-libbs2b --with-libcaca --with-libgsm --with-libmodplug --with-openssl@1.1 --with-rtmpdump --with-speex --with-two-lame --with-wavpack --with-xvid
That is missing only two extensions:
--with-chromaprint --with-decklink
Getting the same error as @bfontaine and @75th. I tried to remove --with-chromaprint and --with-decklink and it still
musangs-MacBook-Pro:~ musang$ ffmpeg
dyld: Library not loaded: @rpath/libclang_rt.ubsan_osx_dynamic.dylib
Referenced from: /usr/local/opt/game-music-emu/lib/libgme.0.dylib
Reason: image not found
Abort trap: 6
musangs-MacBook-Pro:~ musang$
I needed ffmpeg for merging videos of youtube-dl
.
The below-mentioned command did the required installation.
brew install homebrew-ffmpeg/ffmpeg/ffmpeg
I needed ffmpeg for merging videos of
youtube-dl
.
The below-mentioned command did the required installation.
brew install homebrew-ffmpeg/ffmpeg/ffmpeg
Work for me
brew install homebrew-ffmpeg/ffmpeg/ffmpeg
Work for me now on macOS Mojave Version 10.14.5
OS: macOS 10.15.6
# Remove old ffmpeg
brew uninstall ffmpeg
# Install third party repository (it's v4.3.1 currently)
# If you need any extra decoder for the mp4 file, use --with-* flag
# Ref: https://trac.ffmpeg.org/wiki/CompilationGuide/macOS#ffmpegthroughHomebrew
# https://github.com/homebrew-ffmpeg/homebrew-ffmpeg#installing-with-options
brew install homebrew-ffmpeg/ffmpeg/ffmpeg
# Check if there are VP8, VP9 encoders
ffmpeg -encoders
# ...
# V..... libvpx libvpx VP8 (codec vp8)
# V..... libvpx-vp9 libvpx VP9 (codec vp9)
# ...
# Convert with VP9
ffmpeg -i input.mp4 -c:v libvpx-vp9 output.webm
# Convert with VP8
ffmpeg -i input.mp4 -c:v libvpx output.webm
when I entered brew install ffmpeg under 10.15.7, it worked for me
brew install ffmpeg
worked for me
brew install ffmpeg
works just fine
On a fresh MacOS Monterey install, a simple brew install ffmpeg
got me all the following:
ffmpeg version 5.0.1 Copyright (c) 2000-2022 the FFmpeg developers
built with Apple clang version 13.1.6 (clang-1316.0.21.2)
configuration: --prefix=/usr/local/Cellar/ffmpeg/5.0.1 --enable-shared --enable-pthreads --enable-version3 --cc=clang --host-cflags= --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libdav1d --enable-libmp3lame --enable-libopus --enable-librav1e --enable-librist --enable-librubberband --enable-libsnappy --enable-libsrt --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libspeex --enable-libsoxr --enable-libzmq --enable-libzimg --disable-libjack --disable-indev=jack --enable-videotoolbox
libavutil 57. 17.100 / 57. 17.100
libavcodec 59. 18.100 / 59. 18.100
libavformat 59. 16.100 / 59. 16.100
libavdevice 59. 4.100 / 59. 4.100
libavfilter 8. 24.100 / 8. 24.100
libswscale 6. 4.100 / 6. 4.100
libswresample 4. 3.100 / 4. 3.100
libpostproc 56. 3.100 / 56. 3.100
I am getting
invalid option: --with-libass
I'm interested in libass. How to install it?
I'm on Mac.
@AtomicNess123 When I installed ffmpeg recently via homebrew it came with libass already. Try just installing with brew install ffmpeg and then run ffmpeg by itself to see if: --enable-libass is int he output.
Thanks! I have the last version installed with brew: ffmpeg 5.1.2_1 is already installed and up-to-date.
ffmpeg version 4.2.2 Copyright (c) 2000-2019 the FFmpeg developers
built with clang version 4.0.1 (tags/RELEASE_401/final)
configuration: --prefix=/opt/concourse/worker/volumes/live/d5b9ea1c-8223-4ff6-7416-83e6b4cd6874/volume/ffmpeg_1587154914508/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehol --cc=x86_64-apple-darwin13.4.0-clang --disable-doc --enable-avresample --enable-gmp --enable-hardcoded-tables --enable-libfreetype --enable-libvpx --enable-pthreads --enable-libopus --enable-postproc --enable-pic --enable-pthreads --enable-shared --enable-static --enable-version3 --enable-zlib --enable-libmp3lame --disable-nonfree --enable-gpl --enable-gnutls --disable-openssl --enable-libopenh264 --enable-libx264
It doesn't seem libass is in the output.
Revised version based on @florentroques's comment on Jul 12, 2018:
$ brew install ffmpeg $(brew options ffmpeg | grep -v -e '\s' | grep -e '--with-\|--HEAD' | tr '\n' ' ')