[FFmpeg-devel] [HOWTO] Building FFmpeg for iPhone
Wed Oct 7 14:27:05 CEST 2009
On Oct 7, 2009, at 8:12 AM, Jason Millard wrote:
>> You should add -arch armv7 to cflags and ldflags for 4a and -arch
>>>> armv6 for 4b (the warning about -force_cpusubtype_ALL indicates
>>>> this will be required in the future.) This sets a specific cpu
>>>> for the mach-o file, which allows you lipo together binaries.
>>> I tried that, and got this error:
>>> cc1: error: unrecognized command line option "-arch"
>>> The warning is harmless, and only shows that Apple's compiler team
>>> a bunch of idiots, but we knew that already.
>> Oops, -arch is only recognized by "gcc" not "arm-apple-darwin9-
>> So you'd need
>> The advantage of specifying it is that you can have a single binary
>> has full NEON opts, but still works on the older devices.
> I've tried to compile using the gcc instead of arm-apple-darwin9-
> --cc=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc --
> --enable-cross-compile --target-os=darwin --arch=armv6 --
> and get
> /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc is
> unable to
> create an executable file. C compiler test failed.
> I tried with "gcc-4.2.1" with the same result. Is there something
> else I
> should be doing?
--arch=arm --extra-cflags='-arch armv6' --extra-ldflags='-arch armv6'
More information about the ffmpeg-devel