[Ffmpeg-devel] Cross Compiling to Windows CE

Aurelien Jacobs aurel
Sat Jan 13 00:44:10 CET 2007


On Fri, 12 Jan 2007 21:05:49 +0000
Cool_Zer0 <c00jz3r0 at gmail.com> wrote:

> Luca Barbato wrote:
> > Cool_Zer0 wrote:
> >> I don't have any libm inside that folder... But I have the libm of my 
> >> standard GCC...
> >> I'm using the cross-compiler available on VLC: 
> >> http://download.videolan.org/pub/testing/wince/
> >
> > build one yourself it shouldn't _that_ hard.
> >
> >>
> >> I've been searching on google but I can't find other cross compiler 
> >> for Windows CE... Do you know of any useful link?
> >
> > gcc is perfectly fine, just find the instructions on how to deploy it 
> > or use a distribution providing it...
> >
> >>
> >> By the way.. Do you think that with cross-compiling I can compile 
> >> FFMpeg and use the .lib on Visual C++ projects?
> >
> > as usual, if you use an ide that can understand msvc project files and 
> > uses gcc to compile and link you'll be fine, otherwise you may have to 
> > experience any sort of pain because of the nonstandard C compiler 
> > provided by microsoft.
> >
> > lu
> >
> 
> Looks like I've been able to compile FFMpeg with the correct 
> "arm-wince-cegcc". My configure looks like this:
> # ./configure --cross-compile 
> --cross-prefix=/usr/ppc/arm-wince-cegcc/bin/ --arch=armv4l 
> --enable-memalign-hack --disable-ipv6 --prefix=/usr/local/wince 
> --log=yes --disable-encoders --disable-decoders --disable-parsers 
> --disable-muxers --disable-demuxers --enable-parser=h263 
> --enable-encoder=h263 --enable-decoder=h263 --enable-muxer=h263 
> --enable-demuxer=h263 --disable-ffserver --disable-ffplay 
> --disable-ffmpeg --disable-network
> 
> Not I want to have the libavformat.lib and libavcodec.lib and to do that 
> I add this tags "--enable-shared --disable-static".
> 
> Result:
> (...)
> make[1]: Entering directory `/root/ffmpeg/libavformat'
> /usr/ppc/arm-wince-cegcc/bin/gcc -shared -Wl,-soname,libavformat.so.51 
> -Wl,--warn-common  -Wl,--as-needed 
> -Wl,-rpath-link,"/root/ffmpeg"/libavcodec 
> -Wl,-rpath-link,"/root/ffmpeg"/libavformat 
> -Wl,-rpath-link,"/root/ffmpeg"/libavutil -o libavformat.so.51 utils.o 
> cutils.o os_support.o allformats.o framehook.o avio.o aviobuf.o file.o 
> raw.o -L"/root/ffmpeg"/libavutil -lavutil -lavcodec 

Maybe try to replace "-lavutil -lavcodec" by "-lavcodec -lavutil"
(I don't know if order is important for windows)

> -L"/root/ffmpeg"/libavcodec -lm
> Info: resolving __ctype_ptr by linking to __imp___ctype_ptr (auto-import)
> /root/ffmpeg/libavcodec/libavcodec.a(utils.o): In function `init_crcs':
> /root/ffmpeg/libavcodec/utils.c:1187: undefined reference to `av_crc_init'
> /root/ffmpeg/libavcodec/utils.c:1188: undefined reference to `av_crc_init'
> /root/ffmpeg/libavcodec/utils.c:1189: undefined reference to `av_crc_init'

Here you are linking libavformat to libavcodec, which itself require
libavutil (for the av_crc_init symbol). If the previous tips don't work,
verify that your libavutil really contains the av_crc_init symbol.

Aurel




More information about the ffmpeg-devel mailing list