You must have Xcode installed with Unix Tools. Xcode 3 is available for free via Apple Developer Center. However, Xcode 4 is available through the App Store (free for Lion users).
# Create a temporary directory for sources.
SOURCES=$(mktemp -d /tmp/XXXXXXXXXX)
cd $SOURCES
# Download the necessary sources.
curl -#LO http://downloads.sourceforge.net/project/faac/faac-src/faac-1.28/faac-1.28.tar.gz
curl -#LO http://downloads.sourceforge.net/project/lame/lame/3.99/lame-3.99.tar.gz
curl -#LO http://downloads.xiph.org/releases/ogg/libogg-1.3.0.tar.gz
curl -#LO http://pkg-config.freedesktop.org/releases/pkg-config-0.25.tar.gz
curl -#LO http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.2.tar.gz
curl -#LO http://downloads.xiph.org/releases/theora/libtheora-1.1.1.tar.bz2
# curl -#LO http://downloads.sourceforge.net/project/opencore-amr/vo-amrwbenc/vo-amrwbenc-0.1.1.tar.gz
curl -#LO http://www.tortall.net/projects/yasm/releases/yasm-1.1.0.tar.gz
curl -#LO http://webm.googlecode.com/files/libvpx-v0.9.7-p1.tar.bz2
curl -#LO ftp://ftp.videolan.org/pub/x264/snapshots/last_x264.tar.bz2
curl -#LO http://downloads.xvid.org/downloads/xvidcore-1.3.2.tar.gz
# curl -#LG -d "p=ffmpeg.git;a=snapshot;h=HEAD;sf=tgz" -o ffmpeg.tar.gz http://git.videolan.org/
curl -#LO http://ffmpeg.org/releases/ffmpeg-0.8.5.tar.bz2
# Unpack files
for file in `ls ${SOURCES}/*.tar.*`; do
tar -xzf $file
rm $file
done
cd faac-*/
CFLAGS="-D__unix__" ./configure && make -j 4 && sudo make install; cd ..
cd lame-*/
./configure && make -j 4 && sudo make install; cd ..
cd libogg-*/
./configure && make -j 4 && sudo make install; cd ..
cd pkg-config-*/
./configure && make -j 4 && sudo make install; cd ..
cd libvorbis-*/
./configure --disable-oggtest --build=x86_64 && make -j 4 && sudo make install; cd ..
cd libtheora-*/
./configure --disable-oggtest --disable-vorbistest --disable-examples --disable-asm
make -j 4 && sudo make install; cd ..
# cd vo-amrwbenc-*/
# ./configure && make -j 4 && sudo make install; cd ..
cd yasm-*/
./configure && make -j 4 && sudo make install; cd ..
cd libvpx-*/
./configure --enable-vp8 --enable-pic && make -j 4 && sudo make install; cd ..
cd x264-*
CFLAGS="-I. -fno-common -read_only_relocs suppress" ./configure --enable-pic --enable-shared && make -j 4 && sudo make install; cd ..
cd xvidcore/build/generic
./configure --disable-assembly && make -j 4 && sudo make install; cd ../../..
# For Lion, we have to change which compiler to use (--cc=clang).
# If you're building on Snow Leopard, you can omit this flag so it defaults to gcc.
cd ffmpeg-*/
CFLAGS="-DHAVE_LRINTF" ./configure --enable-nonfree --enable-gpl --enable-version3 --enable-postproc --enable-swscale --enable-avfilter --enable-libmp3lame --enable-libvorbis --enable-libtheora --enable-libfaac --enable-libxvid --enable-libx264 --enable-libvpx --enable-hardcoded-tables --enable-shared --enable-pthreads --disable-indevs --cc=clang && make -j 4 && sudo make install
# --enable-libvo-amrwbenc
# FFMpeg creates MP4s that have the metadata at the end of the file.
# This tool moves it to the beginning.
cd tools
gcc -D_LARGEFILE_SOURCE qt-faststart.c -o qt-faststart
sudo mv qt-faststart /usr/local/bin
下载
分享到:
相关推荐
Time for action – installing Android SDK and NDK on Mac OS X Setting up Linux Time for action – preparing Ubuntu Linux for Android development Installing Android development kits on Linux Time ...
2.4.1. General Notes on Installing MySQL on Mac OS X 2.4.2. Installing MySQL on Mac OS X Using Native Packages 2.4.3. Installing the MySQL Startup Item 2.4.4. Installing and Using the MySQL Preference...
Advanced C and C++ Compiling
康威的人生游戏 ... compiling under MAC OS X). - ffmpeg is required. It is used in the script that converts the output text file to video. - For MAC OS X users (tested only in Mavericks)
Mac OS X with Xcode: * Read docs/README-macosx.md Mac OS X from the command line: * Run './configure; make; make install' Linux and other UNIX systems: * Run './configure; make; make install' ...
android反编译过程需要的一些工具 mac下的一些工具 包括apktool dex2jar jd-jui
Compiling with Continuations ANDREW W. APPEL CAMBRIDGE UNIVERSITY PRESS 1992
Aho and Ullman - The Theory of Parsing, Translation, and Compiling - Vol. 1 (1972).djvu Aho and Ullman - The Theory of Parsing, Translation, and Compiling - Vol. 2 (1973).djvu
Advanced C and C++ Compiling.pdf
This document mainly provides android compiling instructions on Ubuntu for Quectel SC20 module. It includes details such as the android compiling environment, how to compile the entire android ...
VC调试出现“Compiling... ,Error spawning cl.exe”错误的解决办法
超级经典的C++编译器解析,全部pdf格式,超清晰,内容详细,教程经典!
C++ Compiler for compiling c++ program
Mac OS X Installation 17 Package Installation 17 Compiling the Source 18 The Python Prompt 18 Customizing the Interactive Prompt 19 iPython: An Advanced Prompt 20 Installing setuptools 21 ...
Compiling the Linux kernel
vs6.0安装及运行 和解决 Compiling... error spawning cl.exe 的问题
Raspberry Pi is Linux, but it's a unique flavor of Linux, specifically for the ARM-based Pi. Raspberry Pi Software Reference guides you through the boot process, including ...Appendix E: Mac OS X Tips
TOSSIM is a discrete event simulator for TinyOS sensor networks. Instead of compiling a TinyOS application for a mote, users can compile it into the TOSSIM framework, which runs on a PC.
Compiling and Installing