Welcome to the wiki talking about FFmpeg on Windows.

How to setup the toolchains for compiling FFmpeg under Windows?

  1. Download MinGW packages (see below)
  2. GCC 4.2.1 set (commended) or GCC 4.5.2 set
  3. Extract them into one same folder in order, for example C:\MinGW
  4. Download MSYS packages (see below)
  5. Extract them into one same folder in order, for example C:\MSYS
  6. Download Libraries (optional, see below)
  7. Extrat them into the MinGW folder, for example C:\MinGW
  8. Create a file named “fstab” in C:\MSYS\etc, with the necessary content “C:/MinGW /mingw”
  9. Create a shortcut of C:\MSYS\msys.bat for convenience

Now by clicking the shortcut of C:\MSYS\msys.bat, you could enter the MSYS environment.

In fact, you could download the DOS batch files for downloading and installing MinGW + MSYS toolchains automatically.

Necessary toolchains for compiling FFmpeg under Windows

Downloading URL http://sourceforge.net/projects/mingw/files/

MinGW packages list

  • binutils: binutils-2.21.1-1-mingw32-bin.tar.lzma
  • runtime: mingwrt-3.20-mingw32-dev.tar.gz, mingwrt-3.20-mingw32-dll.tar.gz
  • win32api: w32api-3.17-2-mingw32-dev.tar.lzma
  • bzip2: bzip2-1.0.6-1-mingw32-bin.tar.lzma, libbz2-1.0.6-1-mingw32-dll-2.tar.lzma
  • GCC 4.2.1:
    • gcc-core-4.2.1-sjlj-2.tar.gz
    • gcc-g++-4.2.1-sjlj-2.tar.gz
  • GCC 4.5.2:
    • gcc-core-4.5.2-1-mingw32-bin.tar.lzma
    • gcc-c++-4.5.2-1-mingw32-bin.tar.lzma
    • libgmp-5.0.1-1-mingw32-dll-10.tar.lzma
    • libmpc-0.8.1-1-mingw32-dll-2.tar.lzma
    • libmpfr-2.4.1-1-mingw32-dll-1.tar.lzma
    • libgcc-4.5.2-1-mingw32-dll-1.tar.lzma

MSYS packages list

  • MSYS Core: msysCORE-1.0.11-bin.tar.gz
  • MSYS update: msysCORE-1.0.17-1-msys-1.0.17-bin.tar.lzma
  • make: make-3.81-3-msys-1.0.13-bin.tar.lzma
  • coreutils: coreutils-5.97-3-msys-1.0.13-ext.tar.lzma
  • libintl: libintl-0.17-2-msys-dll-8.tar.lzma
  • libiconv: libiconv-1.13.1-2-msys-1.0.13-dll-2.tar.lzma
  • libtermcap: libtermcap-0.20050421_1-2-msys-1.0.13-dll-0.tar.lzma
  • vim (optional): vim-7.3-2-msys-1.0.13-bin.tar.lzma

Libraries list (optional)

  • libz: libz-1.2.5-1-mingw32-dev.tar.lzma
  • bzip2: bzip2-1.0.6-1-mingw32-dev.tar.lzma
Print/export