[FFmpeg-devel] ASM support for MACOSX 10.5: really?
vmrsss
vmrsss
Tue Mar 25 19:44:27 CET 2008
On 25 Mar 2008, at 14:53, ?smail D?nmez wrote:
> First of all try with gcc not gcc-4.2, static build works fine with
> gcc which is 4.0.1, if you want gcc 4.2 you'll have to do a 64bit
> build due to flac error you encountered. And to do 64bit build on
> MacOSX you need a patch that I posted to this list many times, a
> little search will find it.
Thanks a lot Ismail! This helped. Indeed, using gcc the static build
goes through smoothly. With --enable-shared however, I still have
can't compile cavdsp_mmx and flacdsp_mmx:
> gcc -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -
> D_ISOC9X_SOURCE -I"/usr/local/src/ffmpeg" -I"/usr/local/src/ffmpeg" -
> I"/usr/local/src/ffmpeg"/libavcodec -I"/usr/local/src/ffmpeg"/
> libavdevice -I"/usr/local/src/ffmpeg"/libavfilter -I"/usr/local/src/
> ffmpeg"/libavformat -I"/usr/local/src/ffmpeg"/libavutil -I"/usr/
> local/src/ffmpeg"/libpostproc -I"/usr/local/src/ffmpeg"/libswscale -
> mtune=nocona -mmmx -msse -msse2 -msse3 -mfpmath=sse -I/sw/include -
> pipe -force_cpusubtype_ALL -Wno-sign-compare -fomit-frame-pointer -
> Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-
> optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -
> Wcast-qual -Wwrite-strings -O3 -fno-math-errno -c -o i386/
> cavsdsp_mmx.o i386/cavsdsp_mmx.c
> i386/cavsdsp_mmx.c: In function 'ff_put_cavs_qpel8_mc01_3dnow':
> i386/cavsdsp_mmx.c:447: error: can't find a register in class
> 'GENERAL_REGS' while reloading 'asm'
> make[1]: *** [i386/cavsdsp_mmx.o] Error 1
> make: *** [lib] Error 2
>
and
> gcc -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -
> D_ISOC9X_SOURCE -I"/usr/local/src/ffmpeg" -I"/usr/local/src/ffmpeg" -
> I"/usr/local/src/ffmpeg"/libavcodec -I"/usr/local/src/ffmpeg"/
> libavdevice -I"/usr/local/src/ffmpeg"/libavfilter -I"/usr/local/src/
> ffmpeg"/libavformat -I"/usr/local/src/ffmpeg"/libavutil -I"/usr/
> local/src/ffmpeg"/libpostproc -I"/usr/local/src/ffmpeg"/libswscale -
> mtune=nocona -mmmx -msse -msse2 -msse3 -mfpmath=sse -I/sw/include -
> pipe -force_cpusubtype_ALL -Wno-sign-compare -fomit-frame-pointer -
> Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-
> optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -
> Wcast-qual -Wwrite-strings -O3 -fno-math-errno -c -o i386/
> flacdsp_mmx.o i386/flacdsp_mmx.c
> i386/flacdsp_mmx.c: In function 'ff_flac_compute_autocorr_sse2':
> i386/flacdsp_mmx.c:86: error: can't find a register in class
> 'GENERAL_REGS' while reloading 'asm'
> i386/flacdsp_mmx.c:115: error: can't find a register in class
> 'GENERAL_REGS' while reloading 'asm'
> make[1]: *** [i386/flacdsp_mmx.o] Error 1
> make: *** [lib] Error 2
Does this happen to you too? Any ideas? Notice that if I throw in the
object files saved from the static build, the build completes, I get
the dylibs and ffmpeg linked against them, and it all seems to work
well.
The attractive thing about gcc-4.2 is that it supports -mtune=core2.
With gcc I use -mtune=nocona, don't know if it really makes a
difference. Do you?
Re 64bits: yes, I've got your patch, thanks. Building for 64bit
appears to be a big job though, because I have to recompile a lot of
libraries (from liba52 to libSDL) to link against it. Do you think a
64bit build it is worth the pain?
Thanks again
More information about the ffmpeg-devel
mailing list