Compilation of FFmpeg under Windows

Source: Internet
Author: User
Tags diff ultraedit

The resources required to compile the ffmpeg-20150428 version are in http://download.csdn.net/detail/phenixzhong/8647531, and each resource is the current latest version.

Compile steps:

1.Installing MinGW and Msys
Execute download file: Mingw-get-inst-20111118.exe,
In the 3rd step select "Download Latest repository Catalogues"
Select Installation path: D:\MinGW (i install it to D-drive)
In the "Select Components" step, select:
√c Compiler (default and certain selection)
√c++ Compiler
√msys Basic System (Select this will install Msys,msys and no additional installation is required)
√mingw Developer ToolKit
Wait for the installation to complete! (Need to wait a certain amount of time, because the installation process needs to download files, imagine, the faster the speed, installation faster)
After the installation is complete, you can see the Msys folder in the D:\MinGW directory, and Msys is already installed.
2. Configure Msys.bat Batch File
In order to facilitate vs200x and VS2010 call FFmpeg Dynamic Library, can be configured to let the FFmpeg compile when the Windows downgrade DLL corresponding to the LIB, of course, if you do not have this need, then you can omit the following processing, directly into step 3.
Go to: D:\MinGW\msys\1.0\ folder, use UltraEdit to open the Msys.bat file, add the following line to the most front of the file:
Call "D:\Program Files\Microsoft Visual Studio 10.0\vc\bin\vcvars32.bat"
The following effects are added:
Call "D:\Program Files\Microsoft Visual Studio 10.0\vc\bin\vcvars32.bat"
@echo off
REM Copyright (C): 2001, 2002, 2003, 2004, 2005 Earnie Boyd
REMmailto:[email protected]net
REM This file was part of Minimal SYStem
REMhttp://www.mingw.org/msys.shtml
         rem
         rem File:      MSYS.BAT
         rem Revision:      2.4
          REM Revision date:  December 8th, 2005
          rem ember to set the ' Start in: ' Field of the shortcut.
         rem A value similar to C:\msys\1.0 \ bin is, "Start in:" Field needs
          REM to represent.
where "D:\Program Files\Microsoft Visual Studio 10.0" installs the vs200x or VS2010 directory on your machine, my computer is VS2010 and installed on the D drive. Files can be saved after modification.
3. System integration
Use UltraEdit to modify the Fstab file under C:\MinGW\msys\1.0\etc, if there is no fstab, copy the fstab.sample and rename it: Fstab, and then modify its contents as: C:/mingw/mingw, This is the installation path for MinGW.
4, Configuration Yasm
In order to reduce the trouble of configuring environment variables, we directly modify the Yasm-1.1.0-win32.exe file name to: Yasm.exe, and put it in the system directory: C:\WINDOWS\system32.

5, the compilation of various resources

The basic steps are executed sequentially./configure, make, make, install.

One of the things to note is:

A. You need to comment out the # define OFF_T __int64 statement in line 34th of FAAD2-2.7\FRONTEND\MAIN.C.

B, faac-1.28 need to hit the patch, call the following command will patch Faac-1.28.diff (this file is included in the beginning URL of this article) to hit

Patch-p1 < Faac-1.28.diff

C, before compiling Faad and FAAC need to be lowered in the corresponding directory./bootstrap command.

d, compile XviD to enter the directory is Xvidcore\build\generic, other resources as long as access to the appropriate directory, do not enter the resources of the sub-directory.

E, before compiling amr-nb and AMR-WB need to copy wget tools and unzip.exe to D:\MinGW\bin directory, these two are used to download and decompression 3gp source.

F, before compiling ffmpeg, use the ./configure--help command to view the compilation options for FFmpeg.

Compilation of FFmpeg under Windows

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.