[FFmpeg-devel] Fix Altivec detection on Linux.
Wed Mar 19 15:12:54 CET 2008
On Wed, 2008-03-19 at 15:03 +0100, Luca Barbato wrote:
> > I see we also build everything with -maltivec anyway, which with GCC now
> > doing autovectorisation means that we're likely to be using Altivec
> > anywhere, and this check is mostly pointless.
> Since we do not like runtime cpu detection it is indeed pointless and
> put there just to make happy the "usual suspects". The -maltivec stuff
> should be triggered by default but you should be able to tune the cflags
> to something useful (e.g G3 tuning) while still be able to build the
> altivec stuff (they get -maltivec -mabi=altivec only in this case).
I want to build for a distribution, so I want it to work for users with
or with Altivec.
> > We should stop doing that. If GCC is managing to autovectorise any C
> > code and it actually makes a significant difference, then we should
> > think about building those components twice -- once with -maltivec and
> > once without -- and putting the Altivec version in /lib/altivec where
> > the dynamic linker will find it on appropriate systems.
> This part seems interesting, is there any standard/guideline about this?
It's the same thing which lets you put libraries in /lib/i686/ which
won't work on i586. Try this...
LD_LIBRARY_PATH=/lib:/usr/lib LD_DEBUG=libs /bin/true
Not sure about proper documentation, but there are a few hints about it
More information about the ffmpeg-devel