[Ffmpeg-devel] cross compilation fails from x86_64 to mingw32
Wed Aug 16 23:40:50 CEST 2006
On Wed, Aug 16, 2006 at 11:02:50PM +0200, Aurelien Jacobs wrote:
> On Sat, 12 Aug 2006 14:51:29 +0200
> Gianluigi Tiesi <mplayer at netfarm.it> wrote:
> > I'm cross compiling mingw32 ffmpeg on a x86_64 host.
> > There is a check in the configure
> > that outputs:
> > TARGET_ARCH_X86_64=yes
> > #define ARCH_X86_64 1
> > depending on the host cpu, obiviuosly it will fail in i386 asm where
> > asm code is ifdefed between x86 and x86_64,
> > I've looked at configure and it seams that this check is unconditional
> > i.e. is taken from the output of uname -m and not asking the compiler
> > I suggest to extrapolate it from gcc -dumpmachine,
> > and yes I known there is a --cpu option, but I think the approach is
> > wrong.
> I already faced this situation and I totally agree.
> Here is a patch which implement this.
> It moves the cpu "normalization" after command line parsing so as
> to be able to use $cc to detect cpu.
> Is it ok to commit ?
> --- configure (revision 6005)
> +++ configure (working copy)
> @@ -905,6 +853,59 @@
> +[ -z "$cpu" ] && cpu=`$cc -dumpmachine | sed s/-.*//`
Hmmm, I'm not sure what's the best way to do this. Mans, any better
Also, maybe you'd better put this next to the MMX stuff so we have all
processor-related tests together.
More information about the ffmpeg-devel