How to compile FFMPEG in OS X lion to generate executable files

Source: Internet
Author: User

First, download a version from the FFMPEG official website and select a version under the "FFMPEG releases" column:

Http://ffmpeg.org/download.html

Then, decompress the package directly. Open the terminal of OS X and run the CD command to enter the project directory.

 

If your OS X uses the latest version of xcode 4.3.x or later, all compilation tools are displayed in sandbox status, that is, they are not registered to the system environment, therefore, you cannot directly compile data using the command line. Enter

Https://developer.apple.com/devcenter/mac/index.action

That is, the Mac developer homepage. Log on with a developer account (even if you haven't paid 99 $ to become IDP or MDP), find "additional downloads" and click "view all downloads ". Finally, select the latest version of "command line tools for xcode" to download.

After the download is complete, install it directly.

 

Then you can use the command line for compilation. Since Apple has now abandoned the old GCC and used more advanced llvm clang, we can use clang for compilation directly. Run the -- clang -- version command first.

To view the version information of the clang compiler and determine its validity.

Then, enter the command --./Configure -- cc = clang -- disable-ASM

Here, the -- CC option is used to select the compiler to use clang, while -- disable-ASM is used to disable all assemblies that involve assembly files, because Apple's llvm's built-in assembler may be somewhat different from the default GCC style.

After the call is successful, enter the command --Make

Finally, enter the command --Sudo make install

Enter the boarding password.

Finally, an FFMPEG executable file is generated in the current project directory.

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.