[Ffmpeg-devel] can't build cvs with x264 on amd64

sean seandarcy2
Fri Aug 19 16:42:40 CEST 2005

I built x264.a with -fPIC. Tried building ffmpeg with -fPIC, 


gcc -shared -o libavcodec.so bitstream.o utils.o mem.o 
allcodecs.o mpegvideo.o jrevdct.o jfdctfst.o jfdctint.o 
vorbis.o vp3.o vqavideo.o wmadec.o wnv1.o ws-snd1.o xan.o 
xl.o pthread.o  faad.o faac.o xvidff.o x264.o 
libpostproc/postprocess.o mp3lameaudio.o oggvorbis.o 
oggtheora.o  -lm -lx264 -lz -ldl -lpthread -L../libavutil 
-lavutil -lfaac -lxvidcore -lx264 -lmp3lame -lvorbisenc 
-lvorbis -ltheora -logg  -Wl,--warn-common -rdynamic -ldl 
relocation R_X86_64_32 against `a local symbol' can not be 
used when making a shared object; recompile with -fPIC
could not read symbols: Bad value

So I tried building ffmpeg without --enable-shared:

gcc -O3 -g -Wall -Wno-switch  -mtune=athlon64 -fPIC 
-ftree-vectorize -pipe -mfpmath=sse -I. 
-o cmdutils.o cmdutils.c
gcc -Wl,--warn-common -rdynamic -ldl 
-I/usr/X11R6/include/X11 -g  -o ffmpeg_g ffmpeg.o cmdutils.o 
-L./libavformat -lavformat -L./libavcodec -lavcodec 
-L./libavutil -lavutil -lm -lx264 -lz -ldl -lpthread 
-lmp3lame -lvorbisenc -lvorbis -ltheora -logg -lfaac -lxvidcore
In function `disp_line':
: undefined reference to `XDrawLine'
In function `disp_rect':
: undefined reference to `XDrawRectangle'

Should an include for Xlib.h be stuck somewhere?

But I'd really like to build this as a shared lib. Anyone 
done this on X86_64?  Some magic available?


More information about the ffmpeg-devel mailing list