media-autobuild_suite
media-autobuild_suite
Before opening an issue, check if it’s an issue directly from executing the suite. This isn’t Doom9, reddit, stackoverflow or any other forum for general questions about the things being compiled. This script builds them, that’s all.
This source code is also mirrored in GitLab.
Most git sources in the suite use GitHub, so if it’s down, it’s probably useless to run the suite at that time.
Download
Click here to download latest version
For information about the compiler environment see the wiki, there you also have a example of how to compile your own tools.
Included Tools And Libraries
-
FFmpeg (shared or static) with these libraries (all optional, but compiled by default unless said otherwise):
-
Light build:
- amd amf encoders (built-in)
- cuda (built-in)
- cuda-llvm (built-in)
- cuvid (built-in)
- ffnvcodec (git)
- libaom (git)
- libdav1d (git)
-
libfdk-aac (git)
- needs non-free license if not LGPL
<li> libmp3lame (mingw-w64) </li> <li> libopus (mingw-w64) </li> <li> libvorbis (mingw-w64) </li> <li> libvpx (git) </li> <li> libx264 (git) </li> <li> libx265 (git) </li> <li> nvdec (built-in) </li> <li> nvenc (built-in) </li> <li> schannel with gmp (mingw-w64) <ul dir="auto"> <li> enabled by default if openssl, libtls, mbedtls or gnutls aren’t enabled </li> <li> gmp can be switched by gcrypt (mingw-w64) with –enable-gcrypt </li> </ul> </li> <li> sdl2 (2.0.10) (needed for ffplay) <ul dir="auto"> <li> enabled by default, use –disable-sdl2 if unneeded </li> </ul> </li> </ul> </li> <li> Zeranoe-emulating build (in addition to Light) <ul dir="auto"> <li> avisynthplus (needs avisynth dll installed) </li> <li> fontconfig (latest release) </li> <li> only one of these TLS libs (including schannel) can be enabled at once: <ul dir="auto"> <li> openssl (mingw-w64) <ul dir="auto"> <li> preferred to gnutls and to libtls if all three are in options </li> <li> needs non-GPL license </li> </ul> </li> <li> libtls (from libressl) (latest release) <ul dir="auto"> <li> needs non-GPL license </li> </ul> </li> <li> mbedtls (mingw-w64) <ul dir="auto"> <li> preferred to gnutls if GPLv3 license is chosen </li> </ul> </li> <li> gnutls (latest release) </li> </ul> </li> <li> libass (git) <ul dir="auto"> <li> by default with DirectWrite backend </li> <li> if –enable-fontconfig, fontconfig backend included </li> <li> with harfbuzz (latest release) </li> </ul> </li> <li> libbluray (git) <ul dir="auto"> <li> BD-J support requires installation of Java JDK </li> <li> BD-J support after compilation probably only requires JRE (untested) </li> </ul> </li> <li> libfreetype (latest release) </li> <li> libgsm (mingw-w64) </li> <li> libmfx (git) </li> <li> libmodplug (mingw-w64) </li> <li> libopencore-amr(nb/wb) (mingw-w64) </li> <li> libopenjpeg2 (mingw-w64) </li> <li> libopenmpt (git tag) </li> <li> librav1e (git) </li> <li> libsnappy (mingw-w64) </li> <li> libsoxr (git) </li> <li> libspeex (mingw-w64) </li> <li> libsrt (git) </li> <li> libsvtav1 (git) </li> <li> libtheora (mingw-w64) </li> <li> libtwolame (mingw-w64) </li> <li> libvidstab (git snapshot) </li> <li> libvmaf (git) </li> <li> libvo-amrwbenc (0.1.3) </li> <li> libwebp (git) </li> <li> libxml2 (mingw-w64) </li> <li> libxvid (1.3.7) </li> <li> libzimg (git) </li> </ul> </li> <li> Full build (in addition to Zeranoe) <ul dir="auto"> <li> chromaprint (mingw-w64) </li> <li> cuda filters (needs CUDA SDK installed) <ul dir="auto"> <li> needs non-free license </li> </ul> </li> <li> decklink (12.3) <ul dir="auto"> <li> needs non-free license </li> </ul> </li> <li> frei0r (git) </li> <li> ladspa (mingw-w64) </li> <li> libaribb24 (git) </li> <li> libbs2b (3.1.0) </li> <li> libcaca (mingw-w64) </li> <li> libcdio (mingw-w64) </li> <li> libcodec2 (git) </li> <li> libdavs2 (git) </li> <li> libflite (git) </li> <li> libfribidi (latest release) </li> <li> libglslang (git) </li> <li> libgme (git snapshot) </li> <li> libilbc (git snapshot) </li> <li> libjxl (git) </li> <li> libkvazaar (git) </li> <li> libmysofa (git) <ul dir="auto"> <li> needed for sofalizer filter </li> </ul> </li> <li> libnpp (needs CUDA SDK installed) <ul dir="auto"> <li> needs non-free license </li> </ul> </li> <li> libopenh264 (official binaries) </li> <li> librist (git) </li> <li> librtmp (git) </li> <li> librubberband (git snapshot) </li> <li> libssh (broken) </li> <li> libsvthevc (git) (using non-upstream patch) </li> <li> libsvtvp9 (git) (using non-upstream patch) </li> <li> libtesseract (git) </li> <li> libuavs3d (git) </li> <li> libxavs (git) </li> <li> libxavs2 (git) </li> <li> libzmq (mingw-w64) </li> <li> libzvbi (0.2.35) </li> <li> openal (git) </li> <li> opencl (from system) </li> <li> opengl (from system) </li> <li> vapoursynth (R57) </li> <li> vulkan (git) </li> </ul> </li> </ul>
-
other tools
- aom (git)
- bmx (git)
- curl (latest release) with WinSSL/LibreSSL/OpenSSL/mbedTLS/GnuTLS backend
- cyanrip (git)
- dav1d (git)
- dssim (git)
- exhale (git)
- faac (1.30)
- fdk-aac (git)
- ffmbc (git) (unsupported)
- flac (git)
- haisrt tools (git)
- jo (git)
- jpeg-xl tools (git)
- jq (git)
- kvazaar (git)
- lame (3.100)
- libaacs (git) (shared)
-
libavif (git) with following encoders/decoders:
- rav1e (enc only)
- aom (enc/dec)
- dav1d (dec only)
<li> libbdplus (git) (shared) </li> <li> mediainfo cli (git) </li> <li> mp4box (git) </li> <li> mplayer (svn) (unsupported) </li> <li> mpv (git) including in addition to ffmpeg libs: <ul dir="auto"> <li> Base build (ffmpegChoice=2 or 3) <ul dir="auto"> <li> ANGLE Headers (git) <ul dir="auto"> <li> requires ANGLE shared libraries from somewhere else (i.e. Chrome, Firefox) for gpu-context=angle support </li> </ul> </li> <li> lcms2 (mingw-w64) </li> <li> libass (git) </li> <li> libbluray (git) <ul dir="auto"> <li> BD-J support requires installation of Java JDK </li> <li> BD-J support after compilation probably only requires JRE (untested) </li> </ul> </li> <li> luajit (mingw-w64) </li> <li> mujs (git) </li> <li> rubberband (git snapshot) </li> <li> uchardet (mingw-w64) </li> <li> vulkan, shaderc, spirv-cross, libplacebo (git) </li> <li> vapoursynth (R52) </li> </ul> </li> <li> Full build (ffmpegChoice=4) <ul dir="auto"> <li> dvdnav (git) </li> <li> libarchive (mingw-w64) </li> <li> shared libmpv </li> <li> openal (git) </li> </ul> </li> </ul> </li> <li> opus-tools (git) </li> <li> rav1e (git) </li> <li> ripgrep (git) </li> <li> rtmpdump (git) </li> <li> sox (14.4.2) </li> <li> speex (git) </li> <li> svt-hevc (git) </li> <li> svt-av1 (git) </li> <li> tesseract (git) </li> <li> uvg266 (git) </li> <li> vvenc & vvdec (git) </li> <li> vorbis-tools (git snapshot) </li> <li> vpx (VP8 and VP9 8, 10 and 12 bit) (git) </li> <li> vvc tools (git) </li> <li> webp tools (git) </li> <li> x264 (8 and 10 bit, with l-smash [mp4 output], lavf and ffms2) (git) </li> <li> x265 (8, 10 and 12 bit) (git) </li> <li> xvc (git) (unsupported) </li> <li> xvid (1.3.7) </li> </ul>
-
Windows 64-bits (tested with Win10 64-bits)
- 32-bit hosts are no longer supported.
- NTFS drive
- 13GB+ disk space for a full 32 and 64-bit build, 8GB+ for 64-bit
- 4GB+ RAM
-
At least Powershell 4, Powershell core is not supported at this time
- Powershell 5.1 can be downloaded here
This tool is inspired by the very nice, linux cross-compiling tool from Roger Pack (rdp):
https://github.com/rdp/ffmpeg-windows-build-helpers
It is based on msys2 and tested under Windows 7, 8.1. and 10.
http://sourceforge.net/projects/msys2/
I use some jscript parts from nu774:
https://github.com/nu774/fdkaac_autobuild
Thanks to all of them!
This Windows Batchscript setups a Mingw-w64/GCC compiler environment for building ffmpeg and other media tools under Windows.
After building the environment it retrieves and compiles all tools. All tools get static compiled, no external .dlls needed (with some optional exceptions)
How to use it:-
Download the file, and extract it to your target folder or
git clone
the project. Compilers and tools will get installed there. Please make sure you use a folder without space characters. A good place might be: c:mabs - Double click the media-autobuild_suite.bat file
- Select if you want to compile for Windows 32-bit, 64-bit or both
- Select if you want to compile non-free tools like “fdk aac”
- Select the numbers of CPU (cores) you want to use
- Wait a little bit, and hopefully after a while you’ll find all your “*.exe” tools under local32bin-(audio|global|video) or local64bin-(audio|global|video)
The Script writes a ini-file, so you only need to make these choices the first time what you want to build.
The script doesn’t build any registry key or system variables, when you don’t need it any more you can delete the folder and your system will be clean.
Building everything from scratch takes about ~3 hours depending on what is enabled.
Check forcing-recompilations to check how you can force a rebuild of all libs/binaries.
To save a bit of space you can delete, after compiling, all source folders (except the folders with a “-git” or “-svn” on end) in /build. There’s an option in the .bat for the script to remove these folders automatically.
Have fun!If there’s some error during compilation follow these steps:
- Make sure you’re using the latest version of this suite by downloading the latest version and replacing all files with the new ones;
- If you know which part it’s crashing on, delete that project’s folder in /build and run the script again (ex: if x264 is failing, try deleting x264-git folder in /build);
-
If it still doesn’t work, create an issue and paste the URL to
logs.zip
that the script gives or attach the file yourself to the issue page. - If the problem isn’t reproducible by the contributors of the suite, it’s probably a problem on your side. Delete /msys64, /local32 and /local64 if they exist. /build is usually safe to keep and saves time;
- If the problem is reproducible, it could be…
-
Light build: