[FFmpeg-devel] PIC and YASM

Michael Kostylev michael.kostylev
Mon Nov 9 21:43:56 CET 2009


On Mon Nov  9 20:07:17 2009
Reimar D?ffinger wrote:

>>>>> @@ -1919,7 +1917,6 @@
>>>>>          ;;
>>>>>      openbsd)
>>>>>          enable malloc_aligned
>>>>> -        enable pic
>>>> 
>>>> OpenBSD builds fail without that currently.  Does your new __PIC__
>>>> check fix that?
>>> 
>>> I expect
>> 
>> Unfounded.
> 
> Interesting. I do not know 100% what OpenBSD does, but FFmpeg builds
> just with with PIC disabled, the generated program just does not run.

What is also interesting, how simple -pie (without appropriate cflags)
produces a working binary.

> However, I'd like to suggest the change below.
> Thing is, when PIC is enabled we already take the performance hit
> anyway, so I suggest we at least try to also get the security benefit
> by linking the executable programs as PIE.
> What do you think about that? Any known issues with -pie linker flag?

There is a minor issue with OpenBSD/arm:
http://www.openbsd.org/papers/nycbsdcon08-pie/mgp00021.html

Michael



More information about the ffmpeg-devel mailing list