GNOME Bugzilla – Bug 308415
gst-ffmpeg cvs doesn't build in
Last modified: 2005-08-05 11:13:14 UTC
Distribution/Version: 6.0 On FreeBSD with gcc 3.4.4 gst-ffmpeg cvs doesn't build. if /bin/sh ../../libtool --mode=compile cc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../libavcodec -I/usr/local/include -O2 -fno-strict-aliasing -pipe -fno-force-addr -MT postprocess.lo -MD -MP -MF ".deps/postprocess.Tpo" -c -o postprocess.lo postprocess.c; \ then mv -f ".deps/postprocess.Tpo" ".deps/postprocess.Plo"; else rm -f ".deps/postprocess.Tpo"; exit 1; fi cc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../libavcodec -I/usr/local/include -O2 -fno-strict-aliasing -pipe -fno-force-addr -MT postprocess.lo -MD -MP -MF .deps/postprocess.Tpo -c postprocess.c -fPIC -DPIC -o .libs/postprocess.o postprocess_template.c: In function `postProcess_MMX': postprocess_template.c:2901: warning: use of memory input without lvalue in asm operand 4 is deprecated postprocess_template.c:2901: warning: use of memory input without lvalue in asm operand 4 is deprecated postprocess_template.c:3198: error: can't find a register in class `GENERAL_REGS' while reloading `asm' postprocess_template.c:3283: error: can't find a register in class `GENERAL_REGS' while reloading `asm' postprocess_template.c:3198: error: can't find a register in class `GENERAL_REGS' while reloading `asm' postprocess_template.c:3283: error: can't find a register in class `GENERAL_REGS' while reloading `asm' gmake[8]: *** [postprocess.lo] Error 1
This requires a new snapshot, the current one's libpostproc is not gcc4-compat yet.
ubuntu hoary, same error. luogni@bucefalo:~/Sorgenti/devel/gst-ffmpeg$ gcc --version gcc (GCC) 3.3.5 (Debian 1:3.3.5-8ubuntu2) in #gstreamer: <alley_cat> sKaBoy: try compiling with -O3 and/or -fomit-frame-pointer <sKaBoy> make CFLAGS="-O3 -fomit-frame-pointer" works, thanks
-fomit-frame-pointer lets it build here with gcc 3.4.4 again.
*** Bug 309321 has been marked as a duplicate of this bug. ***
Re comment #1, the compiler is not gcc4 (and in fact gcc4 works fine for the snapshot in THREADED, don't know about HEAD).
Once gst-ffmpeg is updated to a newer snapshot it should work, current ffmpeg cvs has some small changes to the asm in that file and compiles it with -fomit-frame-pointer, both of which are needed to make it work with gcc 4.0.x.
I'm working on a new snapshot, but ffmpeg changed internally so that eahc codec is individually protected by a macro (#ifdef CONFIG_DECODER_MPEG4, etc.) and it's taking a while to get all that correct...
fixed.
It still won't compile. Please see the error message below... dsputil_mmx.c: In function 'dsputil_init_mmx': dsputil_mmx.c:2597: warning: assignment from incompatible pointer type dsputil_mmx.c:2598: warning: assignment from incompatible pointer type dsputil_mmx.c: At top level: dsputil_mmx_rnd.h:59: warning: 'put_no_rnd_pixels8_l2_mmx' defined but not used dsputil_mmx_rnd.h:155: warning: 'put_no_rnd_pixels16_l2_mmx' defined but not used dsputil_mmx_rnd.h:300: warning: 'avg_no_rnd_pixels4_mmx' defined but not used dsputil_mmx_rnd.h:59: warning: 'put_pixels8_l2_mmx' defined but not used dsputil_mmx_rnd.h:155: warning: 'put_pixels16_l2_mmx' defined but not used h264dsp_mmx.c: In function 'h264_h_loop_filter_luma_mmx2': dsputil_mmx.c:618: error: can't find a register in class 'GENERAL_REGS' while reloading 'asm' dsputil_mmx.c:618: error: can't find a register in class 'GENERAL_REGS' while reloading 'asm' make[8]: *** [libmmxsse_la-dsputil_mmx.lo] Error 1 make[8]: Leaving directory `/gnome/cvs/gst-ffmpeg/gst-libs/ext/ffmpeg/libavcodec/i386' make[7]: *** [all-recursive] Error 1 make[7]: Leaving directory `/gnome/cvs/gst-ffmpeg/gst-libs/ext/ffmpeg/libavcodec' make[6]: *** [all-recursive] Error 1 make[6]: Leaving directory `/gnome/cvs/gst-ffmpeg/gst-libs/ext/ffmpeg' make[5]: *** [all] Error 2 make[5]: Leaving directory `/gnome/cvs/gst-ffmpeg/gst-libs/ext/ffmpeg' make[4]: *** [all-local] Error 2 make[4]: Leaving directory `/gnome/cvs/gst-ffmpeg/gst-libs/ext' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/gnome/cvs/gst-ffmpeg/gst-libs/ext' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/gnome/cvs/gst-ffmpeg/gst-libs' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/gnome/cvs/gst-ffmpeg'
I need the compilation line, too.
Here is the compilation lines... make[3]: Entering directory `/gnome/cvs/gst-ffmpeg/gst-libs/ext/ffmpeg/libavcodec/i386' if /bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../libavcodec -DHAVE_AV_CONFIG_H=1 -fomit-frame-pointer -Wall -Wno-switch -msse -g -O2 -MT libmmxsse_la-dsputil_mmx.lo -MD -MP -MF ".deps/libmmxsse_la-dsputil_mmx.Tpo" -c -o libmmxsse_la-dsputil_mmx.lo `test -f 'dsputil_mmx.c' || echo './'`dsputil_mmx.c; \ then mv -f ".deps/libmmxsse_la-dsputil_mmx.Tpo" ".deps/libmmxsse_la-dsputil_mmx.Plo"; else rm -f ".deps/libmmxsse_la-dsputil_mmx.Tpo"; exit 1; fi gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../libavcodec -DHAVE_AV_CONFIG_H=1 -fomit-frame-pointer -Wall -Wno-switch -msse -g -O2 -MT libmmxsse_la-dsputil_mmx.lo -MD -MP -MF .deps/libmmxsse_la-dsputil_mmx.Tpo -c dsputil_mmx.c -fPIC -DPIC -o .libs/libmmxsse_la-dsputil_mmx.o ...
And if you remove the -fPIC?
Yes, after I manually removed "-fPIC" from the configure script the code compiled.
Hi Dennis, the ffmpeg people claim this is a gcc bug. Which gcc? Are updates available?
I am running Fedora Core 4, so this is gcc 4.0.
Version 4.0.1 of gcc for FC4 was made available tonight. Unfortunately, ffmpeg won't compile with it either.
Added a workaround.