[Ffmpeg-devel] Compilation for Windows under Cygwin
Ivan Wong
email
Fri Aug 5 21:11:55 CEST 2005
Hi,
Just want to share my experiences:
I compile under Cygwin likes this:
./configure --cc="gcc -mno-cygwin" --enable-memalign-hack
--enable-shared --enable-mingw32
For my debian box with mingw32's compiler, I cross-compile by:
./configure --cross-prefix=i386-pc-mingw32- --enable-memalign-hack
--enable-shared --enable-mingw32
Change cross-prefix to suit your need, my cross-compiler has name
`i386-pc-mingw32-gcc` so the cross-prefix is `i386-pc-mingw32-`. Make
sure that i386-pc-mingw32-* are pathed.
--enable-mingw32 is important as `uname -s` in both bases report the
wrong targetos. We need to specify explicitly that we are really using
mingw32.
For my own work, I also need to enable libogg, vorbis, faad, faac, xvid.
I managed to link to av(codec|format).dll to dynamic versions of the
metioned libraries. Attached please find the patch for this purpose.
Again, this can be done with all Cygwin, Msys or mingw32/debian.
cygwin:
./configure --cc="gcc -mno-cygwin" --enable-memalign-hack
--enable-shared --disable-static --enable-mingw32
--extra-cflags=-I`pwd`/deps/include --extra-ldflags=-L`pwd`/deps/lib
--enable-gpl --enable-libogg --enable-vorbis --enable-faad --enable-faac
--enable-xvid
mingw32/debian:
./configure --cross-prefix=i386-pc-mingw32- --enable-memalign-hack
--enable-shared --disable-static --enable-mingw32
--extra-cflags=-I`pwd`/deps/include --extra-ldflags=-L`pwd`/deps/lib
--enable-gpl --enable-libogg --enable-vorbis --enable-faad --enable-faac
--enable-xvid
Note that I put the headers and export libraries of libogg, vorbis,
faad, faac, xvid, zlib, etc. in $top_srcdir/deps/include and
$top_srcdir/deps/lib
Cheers,
--
Ivan, Wong Yat Cheung <email at ivanwong.info>
GPG: 1024D/7775FDBB: CE88 DBE0 5AF3 D4AC 91F5 6C0E 2C84 B2AD 7775 FDBB
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: win32.patch
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20050806/464289f1/attachment.txt>
More information about the ffmpeg-devel
mailing list