[FFmpeg-devel] adding --cpu=native option to ffmpeg configure script

Måns Rullgård mans
Sun Aug 2 17:33:18 CEST 2009


emil Karlson <jekarlson at gmail.com> writes:

> Greetings
>
> Basically the motivation and some sort of draft solution (only for gentoo
> ebuild though) is described here.
> http://bugs.gentoo.org/show_bug.cgi?id=273421
>
> ie. ffmpeg configure --cpu=native option might be able to optionally choose
> the cpu type on the local computer.
>
> Sample solution:
> cpu=`echo "int main() {}" | gcc -march=native -xc -S -Q -v - |& egrep -m 1
> -o "\-march=.*" | cut -f 1 -d \ | cut -f 2 -d \=`
>
> It's a bit ugly but shouldn't cause any regressions, if you limit this code
> to option --cpu=native.

I'm not against such functionality per se, but it's a bit more
complicated than this.  I'll see what I can do.

-- 
M?ns Rullg?rd
mans at mansr.com



More information about the ffmpeg-devel mailing list